Pular para o conte√ļdo principal
Version: Next

Interfaces

What is Interfaces?‚Äč

Provides interfaces for the main Dev Protocol contracts in Solidity.

Source
npmhttps://www.npmjs.com/package/@devprotocol/protocol
GitHubhttps://github.com/dev-protocol/protocol

Usage‚Äč

You can install it with npm or yarn and import it within your project.

Install from npm.

npm i @devprotocol/protocol

Or, use yarn.

yarn add @devprotocol/protocol

Example‚Äč

import {IAddressConfig} from "@devprotocol/protocol/contracts/interface/IAddressConfig.sol";
import {IPropertyGroup} from "@devprotocol/protocol/contracts/interface/IPropertyGroup.sol";

contract Demo {
function validatePropertyAddress(address _property) external view returns(bool) {
IAddressConfig addressConfig = IAddressConfig(0x1D415aa39D647834786EB9B5a333A50e9935b796);
IPropertyGroup propertyGroup = IPropertyGroup(addressConfig.propertyGroup());
retrurn propertyGroup.isGroup(_property);
}
}