-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor x/collection,token proto #3
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -74,11 +74,11 @@ enum AttributeKey { | |
ATTRIBUTE_KEY_NEW_ROOT_TOKEN_ID = 19 [(gogoproto.enumvalue_customname) = "AttributeKeyNewRoot"]; | ||
} | ||
|
||
// EventSent is emitted when tokens are transferred. | ||
// EventSend is emitted when tokens are transferred. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventSent { | ||
// contract id associated with the contract. | ||
message EventSend { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the send. | ||
string operator = 2; | ||
|
@@ -90,51 +90,51 @@ message EventSent { | |
repeated Coin amount = 5 [(gogoproto.nullable) = false]; | ||
} | ||
|
||
// EventAuthorizedOperator is emitted when a holder authorizes an operator to manipulate its tokens. | ||
// EventAuthorizeOperator is emitted when a holder authorizes an operator to manipulate its tokens. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventAuthorizedOperator { | ||
// contract id associated with the contract. | ||
message EventAuthorizeOperator { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address of a holder which authorized the `operator` address as an operator. | ||
string holder = 2; | ||
// address which became an operator of `holder`. | ||
string operator = 3; | ||
} | ||
|
||
// EventRevokedOperator is emitted when an authorization is revoked. | ||
// EventRevokeOperator is emitted when an authorization is revoked. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventRevokedOperator { | ||
// contract id associated with the contract. | ||
message EventRevokeOperator { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address of a holder which revoked the `operator` address as an operator. | ||
string holder = 2; | ||
// address which was revoked as an operator of `holder`. | ||
string operator = 3; | ||
} | ||
|
||
// EventCreatedContract is emitted when a new contract is created. | ||
// EventCreateContract is emitted when a new contract is created. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventCreatedContract { | ||
message EventCreateContract { | ||
// address which created the contract. | ||
string creator = 1; | ||
// contract id associated with the contract. | ||
// id associated with the contract. | ||
string contract_id = 2; | ||
// name of the contract. | ||
string name = 3; | ||
// metadata of the contract. | ||
string meta = 4; | ||
// uri for the contract image stored off chain. | ||
string base_img_uri = 5; | ||
string uri = 5; | ||
} | ||
|
||
// EventCreatedFTClass is emitted when a new fungible token class is created. | ||
// EventCreateFTClass is emitted when a new fungible token class is created. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventCreatedFTClass { | ||
// contract id associated with the contract. | ||
message EventCreateFTClass { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the create. | ||
string operator = 2; | ||
|
@@ -150,11 +150,11 @@ message EventCreatedFTClass { | |
bool mintable = 7; | ||
} | ||
|
||
// EventCreatedNFTClass is emitted when a new non-fungible token class is created. | ||
// EventCreateNFTClass is emitted when a new non-fungible token class is created. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventCreatedNFTClass { | ||
// contract id associated with the contract. | ||
message EventCreateNFTClass { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the create. | ||
string operator = 2; | ||
|
@@ -166,13 +166,13 @@ message EventCreatedNFTClass { | |
string meta = 5; | ||
} | ||
|
||
// EventGranted is emitted when a granter grants its permission to a grantee. | ||
// EventGrant is emitted when a granter grants its permission to a grantee. | ||
// | ||
// Info: `granter` would be empty if the permission is granted by an issuance. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventGranted { | ||
// contract id associated with the contract. | ||
message EventGrant { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address of the granter which grants the permission. | ||
string granter = 2; | ||
|
@@ -182,23 +182,23 @@ message EventGranted { | |
Permission permission = 4; | ||
} | ||
|
||
// EventRenounced is emitted when a grantee renounced its permission. | ||
// EventRenounce is emitted when a grantee renounced its permission. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventRenounced { | ||
// contract id associated with the contract. | ||
message EventRenounce { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address of the grantee which abandons its grant. | ||
string grantee = 2; | ||
// permission on the contract. | ||
Permission permission = 3; | ||
} | ||
|
||
// EventMintedFT is emitted when fungible tokens are minted. | ||
// EventMintFT is emitted when fungible tokens are minted. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventMintedFT { | ||
// contract id associated with the contract. | ||
message EventMintFT { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the mint. | ||
string operator = 2; | ||
|
@@ -208,11 +208,11 @@ message EventMintedFT { | |
repeated Coin amount = 4 [(gogoproto.nullable) = false]; | ||
} | ||
|
||
// EventMintedNFT is emitted when non-fungible tokens are minted. | ||
// EventMintNFT is emitted when non-fungible tokens are minted. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventMintedNFT { | ||
// contract id associated with the contract. | ||
message EventMintNFT { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the mint. | ||
string operator = 2; | ||
|
@@ -222,11 +222,11 @@ message EventMintedNFT { | |
repeated NFT tokens = 4 [(gogoproto.nullable) = false]; | ||
} | ||
|
||
// EventBurned is emitted when tokens are burnt. | ||
// EventBurn is emitted when tokens are burnt. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventBurned { | ||
// contract id associated with the contract. | ||
message EventBurn { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the burn. | ||
string operator = 2; | ||
|
@@ -236,53 +236,56 @@ message EventBurned { | |
repeated Coin amount = 4 [(gogoproto.nullable) = false]; | ||
} | ||
|
||
// EventModifiedContract is emitted when the information of a contract is modified. | ||
// EventModifyContract is emitted when the information of a contract is modified. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventModifiedContract { | ||
// contract id associated with the contract. | ||
message EventModifyContract { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the modify. | ||
string operator = 2; | ||
// changes of the attributes applied. | ||
// refer to the comments on MsgModify for the possible keys. | ||
repeated Attribute changes = 3 [(gogoproto.nullable) = false]; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How about explaining possible keys of
|
||
} | ||
|
||
// EventModifiedTokenClass is emitted when the information of a token class is modified. | ||
// EventModifyTokenClass is emitted when the information of a token class is modified. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventModifiedTokenClass { | ||
// contract id associated with the contract. | ||
message EventModifyTokenClass { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the modify. | ||
string operator = 2; | ||
// class id associated with the token class. | ||
string class_id = 3; | ||
// changes of the attributes applied. | ||
// refer to the comments on MsgModify for the possible keys. | ||
repeated Attribute changes = 4 [(gogoproto.nullable) = false]; | ||
// type name of the token class. | ||
string type_name = 5; | ||
} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ditto, how about explaining possible keys of
|
||
|
||
// EventModifiedNFT is emitted when the information of a non-fungible token is modified. | ||
// EventModifyNFT is emitted when the information of a non-fungible token is modified. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventModifiedNFT { | ||
// contract id associated with the contract. | ||
message EventModifyNFT { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the modify. | ||
string operator = 2; | ||
// token id associated with the non-fungible token. | ||
string token_id = 3; | ||
// changes of the attributes applied. | ||
// refer to the comments on MsgModify for the possible keys. | ||
repeated Attribute changes = 4 [(gogoproto.nullable) = false]; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ditto, how about explaining possible keys of
|
||
} | ||
|
||
// EventAttached is emitted when a token is attached to another. | ||
// EventAttach is emitted when a token is attached to another. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventAttached { | ||
// contract id associated with the contract. | ||
message EventAttach { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the attach. | ||
string operator = 2; | ||
|
@@ -294,11 +297,11 @@ message EventAttached { | |
string target = 5; | ||
} | ||
|
||
// EventDetached is emitted when a token is detached from its parent. | ||
// EventDetach is emitted when a token is detached from its parent. | ||
// | ||
// Since: 0.46.0 (finschia) | ||
message EventDetached { | ||
// contract id associated with the contract. | ||
message EventDetach { | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// address which triggered the detach. | ||
string operator = 2; | ||
|
@@ -314,7 +317,7 @@ message EventDetached { | |
// | ||
// Since: 0.46.0 (finschia) | ||
message EventOwnerChanged { | ||
// contract id associated with the contract. | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// token id associated with the token. | ||
string token_id = 2; | ||
|
@@ -328,7 +331,7 @@ message EventOwnerChanged { | |
// | ||
// Since: 0.46.0 (finschia) | ||
message EventRootChanged { | ||
// contract id associated with the contract. | ||
// id associated with the contract. | ||
string contract_id = 1; | ||
// token id associated with the token. | ||
string token_id = 2; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does
enum AttributeKey
affect legacy events?If not, I guess the following definition should be modified into
ATTRIBUTE_KEY_URI
andAttributeKeyURI
. (PossiblyAttributeKeyUri
is better?)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does. So we would better not touch it.