Class Asset
Class representing an asset instance. An asset instance is an non fungible token address in addition to an instance serial number.
Implements
Inherited Members
Namespace: Hashgraph
Assembly: Hashgraph.dll
Syntax
public sealed class Asset : IEquatable<Asset>
Remarks
This class consists of both an Address representing the address of the underlying non fungible token definition and a serial number representing this instance of the asset token. This class is immutable once created.
Constructors
| Improve this Doc View SourceAsset(Address, Int64)
Public Constructor, an
Asset
is immutable after creation.
Declaration
public Asset(Address address, long serialNum)
Parameters
Type | Name | Description |
---|---|---|
Address | address | Main Network Node Address |
Int64 | serialNum | Serial number representing the unique instance of the asset. |
Asset(Int64, Int64, Int64, Int64)
Public Constructor, an
Asset
is immutable after creation.
Declaration
public Asset(long shardNum, long realmNum, long accountNum, long serialNum)
Parameters
Type | Name | Description |
---|---|---|
Int64 | shardNum | Main Network Node Shard Number |
Int64 | realmNum | Main Network Node Realm Number |
Int64 | accountNum | Main Network Node Account Number |
Int64 | serialNum | Serial number representing the unique instance of the asset. |
Properties
| Improve this Doc View SourceAccountNum
Network Account Number for Asset (NFT) Type
Declaration
public long AccountNum { get; }
Property Value
Type | Description |
---|---|
Int64 |
None
A special designation of an asset that can't be created. It represents the absence of a valid address and serial number.
Declaration
public static Asset None { get; }
Property Value
Type | Description |
---|---|
Asset |
RealmNum
Network Realm Number for Asset (NFT) Type
Declaration
public long RealmNum { get; }
Property Value
Type | Description |
---|---|
Int64 |
SerialNum
Serial number representing the unique instance of the asset.
Declaration
public long SerialNum { get; }
Property Value
Type | Description |
---|---|
Int64 |
ShardNum
Network Shard Number for Asset (NFT) Type
Declaration
public long ShardNum { get; }
Property Value
Type | Description |
---|---|
Int64 |
Operators
| Improve this Doc View SourceImplicit(Asset to Address)
Implicit operator for converting an Asset to an Address
Declaration
public static implicit operator Address(Asset asset)
Parameters
Type | Name | Description |
---|---|---|
Asset | asset |
Returns
Type | Description |
---|---|
Address |