Clio develop
The XRP Ledger API server.
Loading...
Searching...
No Matches
data::NFT Struct Reference

Represents a NFToken. More...

#include <Types.hpp>

Public Member Functions

 NFT (ripple::uint256 const &tokenID, std::uint32_t ledgerSequence, ripple::AccountID const &owner, Blob uri, bool isBurned)
 Construct a new NFT object.
 
 NFT (ripple::uint256 const &tokenID, std::uint32_t ledgerSequence, ripple::AccountID const &owner, bool isBurned)
 Construct a new NFT object.
 
bool operator== (NFT const &other) const
 Check if the NFT is the same as another.
 

Public Attributes

ripple::uint256 tokenID
 
std::uint32_t ledgerSequence {}
 
ripple::AccountID owner
 
Blob uri
 
bool isBurned {}
 

Detailed Description

Represents a NFToken.

Constructor & Destructor Documentation

◆ NFT() [1/2]

data::NFT::NFT ( ripple::uint256 const & tokenID,
std::uint32_t ledgerSequence,
ripple::AccountID const & owner,
Blob uri,
bool isBurned )
inline

Construct a new NFT object.

Parameters
tokenIDThe token ID
ledgerSequenceThe ledger sequence
ownerThe owner
uriThe URI
isBurnedWhether the token is burned

◆ NFT() [2/2]

data::NFT::NFT ( ripple::uint256 const & tokenID,
std::uint32_t ledgerSequence,
ripple::AccountID const & owner,
bool isBurned )
inline

Construct a new NFT object.

Parameters
tokenIDThe token ID
ledgerSequenceThe ledger sequence
ownerThe owner
isBurnedWhether the token is burned

Member Function Documentation

◆ operator==()

bool data::NFT::operator== ( NFT const & other) const
inline

Check if the NFT is the same as another.

Clearly two tokens are the same if they have the same ID, but this struct stores the state of a given token at a given ledger sequence, so we also need to compare with ledgerSequence.

Parameters
otherThe other NFT
Returns
true if they are the same; false otherwise

The documentation for this struct was generated from the following file: