TonNft class abstract
An NFT on the TON blockchain.
- Available extensions
- Annotations
-
- @freezed
Constructors
-
TonNft({@JsonKey.new(name: 'address') required String address, @JsonKey.new(name: 'index') required String index, @JsonKey.new(name: 'name') required String name, @JsonKey.new(name: 'description') required String description, @JsonKey.new(name: 'collection_address') String? collectionAddress, @JsonKey.new(name: 'attributes') List<
TonNftAttribute> ? attributes, @JsonKey.new(name: 'gift') UniqueGift? gift}) -
Creates a TonNft.
constfactory
-
TonNft.fromJson(Map<
String, dynamic> json) -
Creates a TonNft from JSON.
factory
Properties
- address → String
-
Address of the NFT.
no setterinherited
-
attributes
→ List<
TonNftAttribute> ? -
Attributes of the NFT, if provided.
no setterinherited
- collectionAddress → String?
-
Address of the collection, if known.
no setterinherited
-
copyWith
→ $TonNftCopyWith<
TonNft> -
Create a copy of TonNft
with the given fields replaced by the non-null parameter values.
no setterinherited
- description → String
-
Description of the NFT.
no setterinherited
- gift → UniqueGift?
-
Unique gift corresponding to the NFT, if any.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- index → String
-
Index within its collection, as a decimal string.
no setterinherited
- name → String
-
Name of the NFT.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
map<
TResult extends Object?> (TResult $default(_TonNft value)) → TResult -
Available on TonNft, provided by the TonNftPatterns extension
Aswitch-like method, using callbacks. -
mapOrNull<
TResult extends Object?> (TResult? $default(_TonNft value)?) → TResult? -
Available on TonNft, provided by the TonNftPatterns extension
A variant ofmapthat fallback to returningnull. -
maybeMap<
TResult extends Object?> (TResult $default(_TonNft value)?, {required TResult orElse()}) → TResult -
Available on TonNft, provided by the TonNftPatterns extension
A variant ofmapthat fallback to returningorElse. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serializes this TonNft to a JSON map.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited