Documentation
¶
Index ¶
Constants ¶
View Source
const MaxCapacity = 4e5
View Source
const Type = fat.TypeFAT1
Variables ¶
View Source
var ErrorCapacity = fmt.Errorf("NFTokenID max capacity (%v) exceeded", maxCapacity)
Functions ¶
This section is empty.
Types ¶
type AddressNFTokensMap ¶
AddressTokenMap relates the RCDHash of an address to its NFTokenIDs.
func (AddressNFTokensMap) AllNFTokens ¶
func (m AddressNFTokensMap) AllNFTokens() (NFTokens, error)
func (AddressNFTokensMap) MarshalJSON ¶
func (m AddressNFTokensMap) MarshalJSON() ([]byte, error)
func (AddressNFTokensMap) Owner ¶
func (m AddressNFTokensMap) Owner(tknID NFTokenID) factom.FAAddress
func (AddressNFTokensMap) Sum ¶
func (m AddressNFTokensMap) Sum() uint64
func (*AddressNFTokensMap) UnmarshalJSON ¶
func (m *AddressNFTokensMap) UnmarshalJSON(data []byte) error
type NFTokenIDMetadataMap ¶
type NFTokenIDMetadataMap map[NFTokenID]json.RawMessage
func (NFTokenIDMetadataMap) MarshalJSON ¶
func (m NFTokenIDMetadataMap) MarshalJSON() ([]byte, error)
func (*NFTokenIDMetadataMap) UnmarshalJSON ¶
func (m *NFTokenIDMetadataMap) UnmarshalJSON(data []byte) error
type NFTokens ¶
type NFTokens map[NFTokenID]struct{}
NFTokens are a set of unique NFTokenIDs. A map[NFTokenID]struct{} is used to guarantee uniqueness of NFTokenIDs.
func (NFTokens) ContainsAll ¶
func (NFTokens) MarshalJSON ¶
func (*NFTokens) UnmarshalJSON ¶
func (*NFTokens) UnmarshalText ¶
type Transaction ¶
type Transaction struct { Inputs AddressNFTokensMap `json:"inputs"` Outputs AddressNFTokensMap `json:"outputs"` TokenMetadata NFTokenIDMetadataMap `json:"tokenmetadata,omitempty"` Metadata json.RawMessage `json:"metadata,omitempty"` Entry factom.Entry `json:"-"` }
Transaction represents a fat1 transaction, which can be a normal account transaction or a coinbase transaction depending on the Inputs and the RCD/signature pair.
func NewTransaction ¶
func (Transaction) IsCoinbase ¶
func (t Transaction) IsCoinbase() bool
func (Transaction) String ¶
func (t Transaction) String() string
func (*Transaction) UnmarshalJSON ¶
func (t *Transaction) UnmarshalJSON(data []byte) error
Click to show internal directories.
Click to hide internal directories.