Documentation
¶
Index ¶
- Constants
- Variables
- func ErrAssetAlreadyFinal(assetID string) sdk.Error
- func ErrAssetNotFound(assetID string) sdk.Error
- func ErrInvalidAssetQuantity(assetID string) sdk.Error
- func ErrInvalidAssetRoot(assetID string) sdk.Error
- func ErrInvalidField(field string) sdk.Error
- func ErrInvalidRevokeReporter(addr sdk.AccAddress) sdk.Error
- func ErrInvalidTransaction(msg string) sdk.Error
- func ErrMissingField(field string) sdk.Error
- func ErrProposalNotFound(recipient sdk.AccAddress) sdk.Error
- func GetAccountAssetKey(addr sdk.AccAddress, assetID string) []byte
- func GetAccountAssetsKey(addr sdk.AccAddress) []byte
- func GetAssetChildrenKey(parent, children string) []byte
- func GetAssetChildrensKey(parent string) []byte
- func GetAssetKey(assetID string) []byte
- func GetInventoryByAccountKey(addr sdk.AccAddress) []byte
- func GetInventoryKey(addr sdk.AccAddress, assetID string) []byte
- func GetProposalAccountKey(addr sdk.AccAddress, assetID string) []byte
- func GetProposalKey(assetID string, recipient sdk.AccAddress) []byte
- func GetProposalsAccountKey(addr sdk.AccAddress) []byte
- func GetProposalsKey(assetID string) []byte
- func GetReporterAssetKey(addr sdk.AccAddress, assetID string) []byte
- func GetReporterAssetsKey(addr sdk.AccAddress) []byte
- func NewHandler(k Keeper) sdk.Handler
- func NewPubKey(pk string) (res ed25519.PubKeyEd25519)
- func PropertyTypeToString(t PropertyType) string
- func RegisterWire(cdc *wire.Codec)
- func TestAddr(addr string, bech string) sdk.AccAddress
- func ValidatorByPowerIndexExists(ctx sdk.Context, keeper Keeper, power []byte) bool
- type Asset
- func (a Asset) CheckUpdateAttributeAuthorization(address sdk.AccAddress, prop Property) bool
- func (a Asset) GetReporter(address sdk.AccAddress) (*Reporter, int)
- func (a Asset) GetRoot() string
- func (a Asset) IsOwner(addr sdk.AccAddress) bool
- func (a Asset) ValidateAddChildren(sender sdk.AccAddress, quantity sdk.Int) sdk.Error
- func (a Asset) ValidateAddMaterial(sender sdk.AccAddress) sdk.Error
- func (a Asset) ValidateAddQuantity(sender sdk.AccAddress) sdk.Error
- func (a Asset) ValidateFinalize(sender sdk.AccAddress) sdk.Error
- func (a Asset) ValidateSubtractQuantity(sender sdk.AccAddress, quantity sdk.Int) sdk.Error
- func (a Asset) ValidateUpdateProperties(sender sdk.AccAddress, properties Properties) sdk.Error
- func (a Asset) ValidateUpdateProperty(sender sdk.AccAddress, name string) sdk.Error
- type Description
- type Keeper
- func (k Keeper) AddMaterials(ctx sdk.Context, msg MsgAddMaterials) (sdk.Tags, sdk.Error)
- func (k Keeper) AddProposal(ctx sdk.Context, msg MsgCreateProposal) (sdk.Tags, sdk.Error)
- func (k Keeper) AddQuantity(ctx sdk.Context, msg MsgAddQuantity) (sdk.Tags, sdk.Error)
- func (k Keeper) AnswerProposal(ctx sdk.Context, msg MsgAnswerProposal) (sdk.Tags, sdk.Error)
- func (k Keeper) CreateAsset(ctx sdk.Context, msg MsgCreateAsset) (sdk.Tags, sdk.Error)
- func (k Keeper) DeleteProposal(ctx sdk.Context, assetID string, recipient sdk.AccAddress)
- func (k Keeper) Finalize(ctx sdk.Context, msg MsgFinalize) (sdk.Tags, sdk.Error)
- func (k Keeper) GetAsset(ctx sdk.Context, assetID string) (asset Asset, found bool)
- func (k Keeper) GetProposal(ctx sdk.Context, assetID string, recipient sdk.AccAddress) (proposal Proposal, found bool)
- func (k Keeper) RevokeReporter(ctx sdk.Context, msg MsgRevokeReporter) (sdk.Tags, sdk.Error)
- func (k Keeper) SetAsset(ctx sdk.Context, asset Asset)
- func (k Keeper) SetProposal(ctx sdk.Context, assetID string, proposal Proposal)
- func (k Keeper) SubtractQuantity(ctx sdk.Context, msg MsgSubtractQuantity) (sdk.Tags, sdk.Error)
- func (k Keeper) UpdateProperties(ctx sdk.Context, msg MsgUpdateProperties) (sdk.Tags, sdk.Error)
- type Location
- type MsgAddMaterials
- type MsgAddQuantity
- type MsgAnswerProposal
- type MsgCreateAsset
- type MsgCreateProposal
- type MsgFinalize
- type MsgRevokeReporter
- type MsgSubtractQuantity
- type MsgUpdateProperties
- type Properties
- type Property
- type PropertyType
- type Proposal
- type ProposalRole
- type ProposalStatus
- type Proposals
- type Reporter
- type Reporters
Constants ¶
const ( CodeUnknownAsset sdk.CodeType = 500 CodeInvalidTransaction sdk.CodeType = 501 CodeInvalidInput sdk.CodeType = 502 CodeInvalidOutput sdk.CodeType = 503 CodeInvalidAssets sdk.CodeType = 504 CodeMissingField sdk.CodeType = 505 CodeInvalidField sdk.CodeType = 506 CodeInvalidRevokeReporter sdk.CodeType = 507 CodeInvalidAssetQuantity sdk.CodeType = 508 CodeAssetAlreadyFinal sdk.CodeType = 509 CodeProposalNotFound sdk.CodeType = 510 DefaultCodespace sdk.CodespaceType = 10 )
ABCI Response Codes Base SDK reserves 500 - 599.
const ( TagAsset = "asset_id" TagSender = "sender" TagRecipient = "recipient" )
Variables ¶
var ( // Keys for store prefixes AssetKey = []byte{0x00} // prefix for each key to an asset AccountAssetKey = []byte{0x01} // prefix for each key to an account ProposalsKey = []byte{0x02} // prefix for each key to an account a proposal AssetChildrenKey = []byte{0x03} // prefix for each key to an asset parent a an asset child AccountProposalsKey = []byte{0x04} // prefix for each key to an account a proposal ReportersKey = []byte{0x05} PropertiesKey = []byte{0x06} InventoryKey = []byte{0x07} ReporterAssetsKey = []byte{0x08} ProposalsAccountKey = []byte{0x09} )
nolint
Functions ¶
func ErrAssetAlreadyFinal ¶ added in v0.2.1
func ErrAssetNotFound ¶ added in v0.1.0
func ErrInvalidAssetQuantity ¶ added in v0.2.1
ErrInvalidAssetQuantity ...
func ErrInvalidAssetRoot ¶ added in v0.2.1
func ErrInvalidField ¶ added in v0.1.0
ErrInvalidField ...
func ErrInvalidRevokeReporter ¶ added in v0.2.2
func ErrInvalidRevokeReporter(addr sdk.AccAddress) sdk.Error
ErrInvalidRevokeReporter is used when the reporter of a revoke reporter message is not in the asset's reporter list
func ErrInvalidTransaction ¶ added in v0.2.1
InvalidTransaction ...
func ErrProposalNotFound ¶ added in v0.20.0
func ErrProposalNotFound(recipient sdk.AccAddress) sdk.Error
func GetAccountAssetKey ¶ added in v0.2.2
func GetAccountAssetKey(addr sdk.AccAddress, assetID string) []byte
GetAccountAssetKey get the key for an account for an asset
func GetAccountAssetsKey ¶ added in v0.2.2
func GetAccountAssetsKey(addr sdk.AccAddress) []byte
GetAccountAssetsKey get the key for an account for all assets
func GetAssetChildrenKey ¶ added in v0.20.0
GetAssetChilrenKey get the key for an asset for an asset
func GetAssetChildrensKey ¶ added in v0.20.0
func GetAssetKey ¶
GetAssetKey get the key for the record with address
func GetInventoryByAccountKey ¶ added in v0.21.0
func GetInventoryByAccountKey(addr sdk.AccAddress) []byte
GetInventoryKey ...
func GetInventoryKey ¶ added in v0.21.0
func GetInventoryKey(addr sdk.AccAddress, assetID string) []byte
GetInventoryKey ...
func GetProposalAccountKey ¶ added in v0.21.0
func GetProposalAccountKey(addr sdk.AccAddress, assetID string) []byte
GetProposalAccountKey ...
func GetProposalKey ¶ added in v0.20.0
func GetProposalKey(assetID string, recipient sdk.AccAddress) []byte
func GetProposalsAccountKey ¶ added in v0.21.0
func GetProposalsAccountKey(addr sdk.AccAddress) []byte
GetProposalsAccount ...
func GetProposalsKey ¶ added in v0.20.0
func GetReporterAssetKey ¶ added in v0.21.0
func GetReporterAssetKey(addr sdk.AccAddress, assetID string) []byte
GetInventoryKey ...
func GetReporterAssetsKey ¶ added in v0.21.0
func GetReporterAssetsKey(addr sdk.AccAddress) []byte
GetInventoryKey ...
func NewPubKey ¶ added in v0.20.0
func NewPubKey(pk string) (res ed25519.PubKeyEd25519)
func PropertyTypeToString ¶ added in v0.22.0
func PropertyTypeToString(t PropertyType) string
func RegisterWire ¶ added in v0.0.2
Register concrete types on wire codec
Types ¶
type Asset ¶
type Asset struct { ID string `json:"id"` Name string `json:"name"` Owner sdk.AccAddress `json:"owner"` Reporters Reporters `json:"reporters"` Description Description `json:"description"` Parent string `json:"parent"` // the id of the asset parent Root string `json:"root"` // the id of the asset root Final bool `json:"final"` Properties Properties `json:"properties"` Materials sdk.Coins `json:"materials"` Quantity sdk.Int `json:"quantity"` Unit string `json:"unit"` Created int64 `json:"created"` Height int64 `json:"height"` }
Asset asset infomation
func (Asset) CheckUpdateAttributeAuthorization ¶ added in v0.1.0
func (a Asset) CheckUpdateAttributeAuthorization(address sdk.AccAddress, prop Property) bool
CheckUpdateAttributeAuthorization returns whether the address is authorized to update the attribute
func (Asset) GetReporter ¶ added in v0.2.2
func (a Asset) GetReporter(address sdk.AccAddress) (*Reporter, int)
CheckUpdateAttributeAuthorization returns whether the address is authorized to update the attribute
func (Asset) IsOwner ¶
func (a Asset) IsOwner(addr sdk.AccAddress) bool
IsOwner check is owner of the asset
func (Asset) ValidateAddChildren ¶ added in v0.20.0
func (Asset) ValidateAddMaterial ¶ added in v0.20.0
func (a Asset) ValidateAddMaterial(sender sdk.AccAddress) sdk.Error
func (Asset) ValidateAddQuantity ¶ added in v0.20.0
func (a Asset) ValidateAddQuantity(sender sdk.AccAddress) sdk.Error
ValidateAddQuantity return error if invalid
func (Asset) ValidateFinalize ¶ added in v0.20.0
func (a Asset) ValidateFinalize(sender sdk.AccAddress) sdk.Error
func (Asset) ValidateSubtractQuantity ¶ added in v0.20.0
func (Asset) ValidateUpdateProperties ¶ added in v0.20.0
func (a Asset) ValidateUpdateProperties(sender sdk.AccAddress, properties Properties) sdk.Error
func (Asset) ValidateUpdateProperty ¶ added in v0.20.0
type Description ¶ added in v0.22.0
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
Keeper ...
func (Keeper) AddMaterials ¶ added in v0.2.1
AddMaterials add materials to the asset
func (Keeper) AddProposal ¶ added in v0.20.0
func (Keeper) AddQuantity ¶
AddQuantity ...
func (Keeper) AnswerProposal ¶ added in v0.1.0
func (Keeper) CreateAsset ¶ added in v0.2.1
Register register new asset
func (Keeper) DeleteProposal ¶ added in v0.20.0
func (Keeper) GetProposal ¶ added in v0.20.0
func (Keeper) RevokeReporter ¶ added in v0.2.2
RevokeReporter delete reporter
func (Keeper) SetProposal ¶ added in v0.20.0
func (Keeper) SubtractQuantity ¶
SubtractQuantity subtract quantity of the asset
func (Keeper) UpdateProperties ¶ added in v0.2.2
UpdateAttribute ...
type MsgAddMaterials ¶ added in v0.1.0
type MsgAddMaterials struct { AssetID string `json:"asset_id"` Sender sdk.AccAddress `json:"sender"` Amount sdk.Coins `json:"amount"` }
MsgAddMaterials ...
func (MsgAddMaterials) Get ¶ added in v0.1.0
func (msg MsgAddMaterials) Get(key interface{}) (value interface{})
func (MsgAddMaterials) GetSignBytes ¶ added in v0.1.0
func (msg MsgAddMaterials) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgAddMaterials) GetSigners ¶ added in v0.1.0
func (msg MsgAddMaterials) GetSigners() []sdk.AccAddress
func (MsgAddMaterials) Type ¶ added in v0.1.0
func (msg MsgAddMaterials) Type() string
func (MsgAddMaterials) ValidateBasic ¶ added in v0.1.0
func (msg MsgAddMaterials) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgAddQuantity ¶ added in v0.2.2
type MsgAddQuantity struct { Sender sdk.AccAddress `json:"sender"` AssetID string `json:"asset_id"` Quantity sdk.Int `json:"quantity"` }
MsgAddQuantity ... ---------------------------------------------------------------
func (MsgAddQuantity) Get ¶ added in v0.2.2
func (msg MsgAddQuantity) Get(key interface{}) (value interface{})
func (MsgAddQuantity) GetSignBytes ¶ added in v0.2.2
func (msg MsgAddQuantity) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgAddQuantity) GetSigners ¶ added in v0.2.2
func (msg MsgAddQuantity) GetSigners() []sdk.AccAddress
func (MsgAddQuantity) Type ¶ added in v0.2.2
func (msg MsgAddQuantity) Type() string
func (MsgAddQuantity) ValidateBasic ¶ added in v0.2.2
func (msg MsgAddQuantity) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgAnswerProposal ¶ added in v0.20.0
type MsgAnswerProposal struct { AssetID string `json:"asset_id"` Sender sdk.AccAddress `json:"sender"` Recipient sdk.AccAddress `json:"recipient"` Response ProposalStatus `json:"response"` }
MsgAnswerProposal ...
func (MsgAnswerProposal) Get ¶ added in v0.20.0
func (msg MsgAnswerProposal) Get(key interface{}) (value interface{})
func (MsgAnswerProposal) GetSignBytes ¶ added in v0.20.0
func (msg MsgAnswerProposal) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgAnswerProposal) GetSigners ¶ added in v0.20.0
func (msg MsgAnswerProposal) GetSigners() []sdk.AccAddress
func (MsgAnswerProposal) Type ¶ added in v0.20.0
func (msg MsgAnswerProposal) Type() string
func (MsgAnswerProposal) ValidateBasic ¶ added in v0.20.0
func (msg MsgAnswerProposal) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgCreateAsset ¶ added in v0.2.1
type MsgCreateAsset struct { Sender sdk.AccAddress `json:"sender"` AssetID string `json:"asset_id"` Name string `json:"name"` Quantity sdk.Int `json:"quantity"` Parent string `json:"parent"` // the id of the parent asset Unit string `json:"unit"` Properties Properties `json:"properties"` }
MsgCreateAsset A really msg record create type, these fields are can be entirely arbitrary and custom to your message
func NewMsgCreateAsset ¶ added in v0.2.1
func NewMsgCreateAsset(sender sdk.AccAddress, id, name string, quantity sdk.Int, parent string) MsgCreateAsset
NewMsgCreateAsset new record create msg
func (MsgCreateAsset) Get ¶ added in v0.2.1
func (msg MsgCreateAsset) Get(key interface{}) (value interface{})
func (MsgCreateAsset) GetSignBytes ¶ added in v0.2.1
func (msg MsgCreateAsset) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgCreateAsset) GetSigners ¶ added in v0.2.1
func (msg MsgCreateAsset) GetSigners() []sdk.AccAddress
func (MsgCreateAsset) ValidateBasic ¶ added in v0.2.1
func (msg MsgCreateAsset) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgCreateProposal ¶ added in v0.20.0
type MsgCreateProposal struct { AssetID string `json:"asset_id"` Sender sdk.AccAddress `json:"sender"` Recipient sdk.AccAddress `json:"recipient"` Properties []string `json:"properties"` Role ProposalRole `json:"role"` }
CreateProposalMsg ...
func (MsgCreateProposal) Get ¶ added in v0.20.0
func (msg MsgCreateProposal) Get(key interface{}) (value interface{})
func (MsgCreateProposal) GetSignBytes ¶ added in v0.20.0
func (msg MsgCreateProposal) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgCreateProposal) GetSigners ¶ added in v0.20.0
func (msg MsgCreateProposal) GetSigners() []sdk.AccAddress
func (MsgCreateProposal) Type ¶ added in v0.20.0
func (msg MsgCreateProposal) Type() string
func (MsgCreateProposal) ValidateBasic ¶ added in v0.20.0
func (msg MsgCreateProposal) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgFinalize ¶ added in v0.2.1
type MsgFinalize struct { Sender sdk.AccAddress `json:"sender"` AssetID string `json:"asset_id"` }
MsgSend ...
func (MsgFinalize) Get ¶ added in v0.2.1
func (msg MsgFinalize) Get(key interface{}) (value interface{})
func (MsgFinalize) GetSignBytes ¶ added in v0.2.1
func (msg MsgFinalize) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgFinalize) GetSigners ¶ added in v0.2.1
func (msg MsgFinalize) GetSigners() []sdk.AccAddress
func (MsgFinalize) Type ¶ added in v0.2.1
func (msg MsgFinalize) Type() string
func (MsgFinalize) ValidateBasic ¶ added in v0.2.1
func (msg MsgFinalize) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgRevokeReporter ¶ added in v0.2.2
type MsgRevokeReporter struct { Sender sdk.AccAddress `json:"sender"` Reporter sdk.AccAddress `json:"reporter"` AssetID string `json:"asset_id"` }
MsgRevokeReporter ...
func (MsgRevokeReporter) Get ¶ added in v0.2.2
func (msg MsgRevokeReporter) Get(key interface{}) (value interface{})
func (MsgRevokeReporter) GetSignBytes ¶ added in v0.2.2
func (msg MsgRevokeReporter) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgRevokeReporter) GetSigners ¶ added in v0.2.2
func (msg MsgRevokeReporter) GetSigners() []sdk.AccAddress
func (MsgRevokeReporter) Type ¶ added in v0.2.2
func (msg MsgRevokeReporter) Type() string
func (MsgRevokeReporter) ValidateBasic ¶ added in v0.2.2
func (msg MsgRevokeReporter) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgSubtractQuantity ¶ added in v0.2.2
type MsgSubtractQuantity struct { Sender sdk.AccAddress `json:"sender"` AssetID string `json:"asset_id"` Quantity sdk.Int `json:"quantity"` }
MsgSubtractQuantity ... ---------------------------------------------------------------
func (MsgSubtractQuantity) Get ¶ added in v0.2.2
func (msg MsgSubtractQuantity) Get(key interface{}) (value interface{})
func (MsgSubtractQuantity) GetSignBytes ¶ added in v0.2.2
func (msg MsgSubtractQuantity) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgSubtractQuantity) GetSigners ¶ added in v0.2.2
func (msg MsgSubtractQuantity) GetSigners() []sdk.AccAddress
func (MsgSubtractQuantity) Type ¶ added in v0.2.2
func (msg MsgSubtractQuantity) Type() string
func (MsgSubtractQuantity) ValidateBasic ¶ added in v0.2.2
func (msg MsgSubtractQuantity) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type MsgUpdateProperties ¶ added in v0.2.2
type MsgUpdateProperties struct { Sender sdk.AccAddress `json:"sender"` AssetID string `json:"asset_id"` Properties Properties `json:"properties"` }
MsgUpdateProperties ... ---------------------------------------------------------------
func (MsgUpdateProperties) Get ¶ added in v0.2.2
func (msg MsgUpdateProperties) Get(key interface{}) (value interface{})
func (MsgUpdateProperties) GetSignBytes ¶ added in v0.2.2
func (msg MsgUpdateProperties) GetSignBytes() []byte
GetSignBytes Get the bytes for the message signer to sign on
func (MsgUpdateProperties) GetSigners ¶ added in v0.2.2
func (msg MsgUpdateProperties) GetSigners() []sdk.AccAddress
func (MsgUpdateProperties) Type ¶ added in v0.2.2
func (msg MsgUpdateProperties) Type() string
func (MsgUpdateProperties) ValidateBasic ¶ added in v0.2.2
func (msg MsgUpdateProperties) ValidateBasic() sdk.Error
ValidateBasic Validate Basic is used to quickly disqualify obviously invalid messages quickly
type Properties ¶ added in v0.2.2
type Properties []Property
list all properties
func (Properties) Adds ¶ added in v0.2.2
func (propertiesA Properties) Adds(othersB ...Property) Properties
func (Properties) Less ¶ added in v0.2.2
func (properties Properties) Less(i, j int) bool
func (Properties) Sort ¶ added in v0.2.2
func (properties Properties) Sort() Properties
Sort is a helper function to sort the set of materials inplace
func (Properties) Swap ¶ added in v0.2.2
func (properties Properties) Swap(i, j int)
type Property ¶ added in v0.2.1
type Property struct { Name string `json:"name"` Type PropertyType `json:"type"` BytesValue []byte `json:"bytes_value,omitempty"` StringValue string `json:"string_value,omitempty"` BooleanValue bool `json:"boolean_value,omitempty"` NumberValue int64 `json:"number_value,omitempty"` EnumValue []string `json:"enum_value,omitempty"` Location Location `json:"location_value,omitempty"` }
Property property of the asset
type PropertyType ¶ added in v0.2.2
type PropertyType int
PropertyType define the type of the property
const ( PropertyTypeBytes PropertyType = iota + 1 PropertyTypeString PropertyTypeBoolean PropertyTypeNumber PropertyTypeEnum PropertyTypeLocation )
All avaliable type ò the attribute
type Proposal ¶
type Proposal struct { Role ProposalRole `json:"role"` // The role assigned to the recipient Status ProposalStatus `json:"status"` // The response of the recipient Properties []string `json:"properties"` // The asset's attributes name that the recipient is authorized to update Issuer sdk.AccAddress `json:"issuer"` // The proposal issuer Recipient sdk.AccAddress `json:"recipient"` // The recipient of the proposal }
Proposal is an invitation to manage an asset
func (Proposal) ValidateAnswer ¶ added in v0.20.0
func (p Proposal) ValidateAnswer(msg MsgAnswerProposal) sdk.Error
type ProposalRole ¶ added in v0.1.0
type ProposalRole int
ProposalRole defines the authority of the proposal's recipient
const ( // RoleReporter is authorized to update the asset's attributes // whose name is included in the proposal's properties field RoleReporter ProposalRole = iota + 1 // RoleOwner has the same authorization as RoleReporter // but also authorized to make proposal to other recipient RoleOwner )
type ProposalStatus ¶ added in v0.1.0
type ProposalStatus int
ProposalStatus define the status of the proposal
const ( StatusPending ProposalStatus = iota // The recipient has not answered StatusAccepted // The recipient accepted the proposal StatusCancel // The issuer cancel the proposal StatusRejected // the recipient reject the proposal )
All available status of the proposal