
Contract purpose
The purpose of the contract is to keep a list of assets and their owners. Also the contract has a history of the asset and the past changes of it. The change values are: 0: owner change; 1: new asset; 2: disabled; 3: enabled; 4: put off.
Parameters:
ownerAddress: the owner address
Exposed methods
addAsset adds a new asset; the specified owner must added in a previous move
parameter name | type | details |
---|---|---|
asset | address | the asset address |
assetOwner | address | the asset owner |
addOwner adds a new owner that can have an asset disableAsset disable the asset with address
parameter name | type | details |
---|---|---|
asset | address | the asset address |
disableOwner disable the owner with address
parameter name | type | details |
---|---|---|
disabledOwner | address | the owner address to disable |
enableAsset enable the asset with address
parameter name | type | details |
---|---|---|
asset | address | the asset address |
modifyAssetOwner modifies the specified asset with the provided new owner address
parameter name | type | details |
---|---|---|
asset | address | the asset address |
newOwner | address | the new asset owner |
history gets the history changes for the provided asset address
parameter name | type | details |
---|---|---|
asset | address | the history for asset address |
owner gets the contract owner owners get if the provided address is an owner
parameter name | type | details |
---|---|---|
address | address | the owner address |
Example:
Initial:ownerAddress: 0xca35b7d915458ef540ade6068dfe2f44e8fa733c
Add asset:
asset: 0xdd870fa1b7c4700f2bd7f44238821c26f7392148
assetOwner: 0xca35b7d915458ef540ade6068dfe2f44e8fa733c