Skip to main content

IDataPointRegistry

What is a Data Point Registry?

Data Point Registry defines a space of compatible DataPoints. Behaves as an Access Management smart contract responsible for creating, managing, and controlling access to Data Points. Multiple Data Point Registries can coexist under the Nexera Standard, and they allocates new Data Points to specified owners and manages administrative roles, ensuring that only authorized individuals have control over the Data Points. When a user allocates a Data Point, they can grant permissions to the desired Data Manager (DM) for asset management. If a change in DM implementation is required, the user can use the registry to assign permissions to a new DM and revoke access from the previous one if necessary.

Data Point Registry

Fig 1. Data Point Registry interaction with DataPoints.

Methods

1. isAdmin()

function isAdmin(DataPoint dp, address account) external view returns (bool);
DescriptionParametersReturnsModifiers
Verifies if an address has an Admin role for a Data Pointdp: Data Point identifier
account: Account to verify
Boolean indicating if the account is an adminexternal
view

2. allocate()

function allocate(address owner) external payable returns (DataPoint);
DescriptionParametersReturnsModifiers
Allocates a Data Point to an ownerowner: Owner of the new Data PointAllocated Data Pointexternal
payable

Note: Owner SHOULD be granted Admin role during allocation.

3. transferOwnership()

function transferOwnership(DataPoint dp, address newOwner) external;
DescriptionParametersReturnsModifiers
Transfers ownership of a Data Point to a new ownerdp: Data Point identifier
newOwner: New owner
Noneexternal

4. grantAdminRole()

function grantAdminRole(DataPoint dp, address account) external returns (bool);
DescriptionParametersReturnsModifiers
Grant permission to grant/revoke other roles on the Data Point inside a Data Index Implementationdp: Data Point identifier
account: New admin
Boolean indicating if the role was grantedexternal

5. revokeAdminRole()

function revokeAdminRole(DataPoint dp, address account) external returns (bool);
DescriptionParametersReturnsModifiers
Revoke permission to grant/revoke other roles on the Data Point inside a Data Index Implementationdp: Data Point identifier
account: Old admin
Boolean indicating if the role was revokedexternal

Note: If an owner revokes Admin role from himself, he can add it again.

Events

1. DataPointAllocated

event DataPointAllocated(DataPoint indexed dp, address owner);
DescriptionParameters
Emitted when a Data Point is allocateddp: Data Point identifier (indexed)
owner: Address of the owner of the new Data Point

2. DataPointOwnershipTransferred

event DataPointOwnershipTransferred(DataPoint indexed dp, address previousOwner, address newOwner);
DescriptionParameters
Emitted when ownership of a Data Point is transferreddp: Data Point identifier (indexed)
previousOwner: Address of the previous owner
newOwner: Address of the new owner

3. DataPointAdminGranted

event DataPointAdminGranted(DataPoint indexed dp, address account);
DescriptionParameters
Emitted when Admin role is granteddp: Data Point identifier (indexed)
account: Address of the account granted the Admin role

4. DataPointAdminRevoked

event DataPointAdminRevoked(DataPoint indexed dp, address account);
DescriptionParameters
Emitted when Admin role is revokeddp: Data Point identifier (indexed)
account: Address of the account revoked from the Admin role

Errors

1. CounterOverflow

error CounterOverflow();
DescriptionParameters
Thrown when the Data Point allocation counter overflowsNone

2. NativeCoinDepositIsNotAccepted

error NativeCoinDepositIsNotAccepted();
DescriptionParameters
Thrown when native coin is sent during Data Point allocationNone

3. InvalidDataPointOwner

error InvalidDataPointOwner(DataPoint dp, address owner);
DescriptionParameters
Thrown when caller is not the owner of the Data Pointdp: Data Point identifier
owner: Address of the invalid owner
note

For more on Data Point allocation and the Registry's role, visit the Data Point Registry Contract Section.