KO
|
EN
gitlite — search
Search
#python
#java
#python3
#arduino
#golang
#machine-learning
#rust
#html
#flask
#javascript
#seismology
#nodejs
smartticket
★ 13
Open GitHub ↗
No description available.
Download README (.md)
Explore Similar Repositories
laravel-blog-5.6.5
:
THIS REPO HAS BEEN ARCHIEVED AND REPLACED WITH A BETTER ONE!
hiveway-fix
:
A chrome extension to fix Hiveway
wwiki
:
用于搭建个人 Wiki 文档库的 Ghost 主题
AileronSimulation
:
Structural analysis of the aileron of a Boeing 737
SparseGPR
:
Implementation of Standard Gaussian Process Regression(GPR) and Sparse GPR in Matlab.
// repository documentation
Was this content helpful?
★ 0
(0 ratings)
Select Rating:
★
★
★
★
★
Submit Feedback
Recent Feedback
×
Download README
Do you want to download the
README.md
file for
smartticket
?
Download (.md)
# Events Smart Contract Standard v.0.0.2 ## Specifications ### Public Variables #### string public version Smart Contract Standard version. #### string public metadata IPFS merkle root hash. #### mapping (address => uint) public owners Array with tokens owners balance. #### mapping (bytes32 => address) public allocatedTickets Array with list of allocated tickets tokens. #### mapping (bytes32 => address) public redeemedTickets Array with list of redeemed tickets tokens. ### Methods #### function allocate(address _to, bytes32 _ticket) external returns(bool status) Allocate `_ticket` token `_to` address and MUST fire the `TicketAllocated` event. The function SHOULD throw if the `_ticket` was already allocated or redeemed. #### function transfer(address _to, bytes32 _ticket) external returns(bool status) Transfer `_ticket` token `_from` method caller address `_to` another address and MUST fire the `TicketTransferred` event. The function SHOULD throw if the `_from` account does not own `_ticket` token. #### function transferFrom(address _from, address _to, bytes32 _ticket) external returns(bool status) Transfer `_ticket` token `_from` address `_to` another address and MUST fire the `TicketTransferred` event. The function SHOULD throw if the `_from` account does not own `_ticket` token. #### function redeem(address _from, bytes32 _ticket) external returns(bool status) Redeem `_ticket` token `_from` address and MUST fire the `TicketRedeemed` event. Function SHOULD throw if `_from` address not own `_ticket` token, or token already used. #### function refund(address _to, bytes32 _ticket) external returns(bool status) Refund `_ticket` token `_to` address and MUST fire `TicketRefunded` event. #### function function updateMetadata(string _ipfs) external returns(bool) Set new `_ipfs` hash with updated metadata. ### Events #### TicketAllocated(address _to, bytes32 _ticket, address _manager) Triggered when `_ticket` token are allocated. #### TicketRedeemed(address _from, bytes32 _ticket, address _manager) Triggered when `_ticket` token are redeemed. #### TicketTransferred(address _from, address _to, bytes32 _ticket, address _manager) Triggered when `_ticket` tokens are transferred. #### TicketRefunded(address _to, bytes32 _ticket, address _manager) Triggered when `_ticket` token are refunded. #### MetadataUpdated(string _metadata) Triggered when `metadata` hash is updated. ### IPFS Metadata Structure #### Event Metadata Example: https://ipfs.io/ipfs/Qmc4QEgAFeM7jiqZA8AfSZjG2bXuj7ScP1pqgNU6Ff8A9y/ #### Ticket Metadata Example: https://ipfs.io/ipfs/Qmcvwt7DJdgephhpcr8iqwMkcy4Nj5Uz1sGPb5x2vHt4jW/ ## Implementation Expansion of this standard for event tickets market can be found at [crypto.tickets](https://github.com/cryptoticket/#) GitHub ## Copyright Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).