Class NftTransfer
Represents a NFT transfer.
Implements
Inherited Members
Namespace: Hiero
Assembly: Hiero.dll
Syntax
public sealed record NftTransfer : IEquatable<NftTransfer>
Constructors
| Edit this page View SourceNftTransfer(Nft, EntityId, EntityId, bool, HookCall?, HookCall?)
Public Constructor, an
NftTransfer
is immutable after creation.
Declaration
public NftTransfer(Nft nft, EntityId fromAddress, EntityId toAddress, bool delegated = false, HookCall? senderAllowanceHook = null, HookCall? receiverAllowanceHook = null)
Parameters
| Type | Name | Description |
|---|---|---|
| Nft | nft | The address and serial number of the nft to transfer. |
| EntityId | fromAddress | The address of the crypto account having the NFT. |
| EntityId | toAddress | The address of the crypto account receiving the NFT. |
| bool | delegated | Indicates the parties involved in the transaction are acting as delegates through a granted allowance. |
| HookCall | senderAllowanceHook | Optional allowance hook call for the sender. |
| HookCall | receiverAllowanceHook | Optional allowance hook call for the receiver. |
Properties
| Edit this page View SourceDelegated
Indicates the transfer was authorized through the allowance mechanism and the sending account may not have signed this transaction.
Declaration
public bool Delegated { get; }
Property Value
| Type | Description |
|---|---|
| bool |
From
The account sending the NFT.
Declaration
public EntityId From { get; }
Property Value
| Type | Description |
|---|---|
| EntityId |
Nft
The Token ID and Serial Number of the nft to transfer.
Declaration
public Nft Nft { get; }
Property Value
| Type | Description |
|---|---|
| Nft |
ReceiverAllowanceHook
Optional allowance hook call for the receiver of this NFT transfer. The hook's CallMode determines whether it is invoked before the transfer only, or both before and after.
Declaration
public HookCall? ReceiverAllowanceHook { get; }
Property Value
| Type | Description |
|---|---|
| HookCall |
SenderAllowanceHook
Optional allowance hook call for the sender of this NFT transfer. The hook's CallMode determines whether it is invoked before the transfer only, or both before and after.
Declaration
public HookCall? SenderAllowanceHook { get; }
Property Value
| Type | Description |
|---|---|
| HookCall |
To
The account receiving the NFT.
Declaration
public EntityId To { get; }
Property Value
| Type | Description |
|---|---|
| EntityId |