forked from aptos-labs/aptos-core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[move-stdlib] use general-purpose GUID's for event handle ID's
- Move general-purpose GUID module from the experimental code to the stdlib - Add unit tests for GUID - Use a GUID as the unique ID for an event handle instead of an event-specific id. - Eliminate all references to `Event::publish_generator`, which is no longer needed. `GUID::create` lazily publishes a `Generator` under the signer's address if it needs to. The event/GUID correspondence has some potentially useful applications for objects with globally unique ID's. For example: say you have NFT's and want to support an efficient API for looking up an NFT by its ID. You can allow each NFT to carry an event stream whose GUID is used as the unique ID for the NFT. Transfers of the NFT emit events to this stream. This lets you query the event stream to find both the current account that holds the NFT (it's the last event emitted to the stream) and the ownership history of the NFT (each event in the stream represents a transfer). Closes: aptos-labs#9395
- Loading branch information
1 parent
8b68295
commit ddc08b8
Showing
63 changed files
with
1,614 additions
and
546 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
-102 Bytes
(99%)
.../diem-framework/DPN/releases/artifacts/current/error_description/error_description.errmap
Binary file not shown.
Binary file modified
BIN
-52 Bytes
(99%)
language/diem-framework/DPN/releases/artifacts/current/modules/DiemAccount.mv
Binary file not shown.
Binary file modified
BIN
-223 Bytes
(69%)
language/diem-framework/DPN/releases/artifacts/current/modules/Event.mv
Binary file not shown.
Binary file added
BIN
+610 Bytes
language/diem-framework/DPN/releases/artifacts/current/modules/GUID.mv
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.