CollectionData
Class: CollectionData
Properties overview
- isPaused: Bool = Bool; ↗
- mintingIsLimited: Bool = Bool; ↗
- requireTransferApproval: Bool = Bool; ↗
- royaltyFee: UInt32 = UInt32; ↗
- transferFee: UInt64 = UInt64; ↗
Methods overview
Defined in: packages/nft/src/interfaces/types.ts:454
Represents the data associated with an NFT collection, including configuration parameters and permission flags.
Extends
- {
isPaused
:Bool
;
mintingIsLimited
:Bool
;
requireTransferApproval
:Bool
;
royaltyFee
:UInt32
;
transferFee
:UInt64
;
}
Constructors
new CollectionData()
new CollectionData(value: {
isPaused: Bool;
mintingIsLimited: Bool;
requireTransferApproval: Bool;
royaltyFee: UInt32;
transferFee: UInt64;
}): CollectionData
Defined in: node_modules/o1js/dist/node/lib/provable/types/struct.d.ts:103
Parameters
value
isPaused
Bool
= Bool
Indicates whether the collection is currently paused.
mintingIsLimited
Bool
= Bool
If true, the minting is stopped and cannot be resumed.
requireTransferApproval
Bool
= Bool
If true, transferring NFTs requires approval from the admin contract.
royaltyFee
UInt32
= UInt32
The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%).
transferFee
UInt64
= UInt64
The transfer fee amount.
Returns
Inherited from
Struct({
/ The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%). /
royaltyFee: UInt32, // 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%
/ The transfer fee amount. /
transferFee: UInt64,
/ If true, transferring NFTs requires approval from the admin contract. /
requireTransferApproval: Bool,
/ If true, the minting is stopped and cannot be resumed. /
mintingIsLimited: Bool,
/ Indicates whether the collection is currently paused. /
isPaused: Bool,
}).constructor
Properties
isPaused
isPaused: Bool = Bool;
Defined in: packages/nft/src/interfaces/types.ts:464
Indicates whether the collection is currently paused.
Inherited from
Struct({
/ The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%). /
royaltyFee: UInt32, // 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%
/ The transfer fee amount. /
transferFee: UInt64,
/ If true, transferring NFTs requires approval from the admin contract. /
requireTransferApproval: Bool,
/ If true, the minting is stopped and cannot be resumed. /
mintingIsLimited: Bool,
/ Indicates whether the collection is currently paused. /
isPaused: Bool,
}).isPaused
mintingIsLimited
mintingIsLimited: Bool = Bool;
Defined in: packages/nft/src/interfaces/types.ts:462
If true, the minting is stopped and cannot be resumed.
Inherited from
Struct({
/ The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%). /
royaltyFee: UInt32, // 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%
/ The transfer fee amount. /
transferFee: UInt64,
/ If true, transferring NFTs requires approval from the admin contract. /
requireTransferApproval: Bool,
/ If true, the minting is stopped and cannot be resumed. /
mintingIsLimited: Bool,
/ Indicates whether the collection is currently paused. /
isPaused: Bool,
}).mintingIsLimited
requireTransferApproval
requireTransferApproval: Bool = Bool;
Defined in: packages/nft/src/interfaces/types.ts:460
If true, transferring NFTs requires approval from the admin contract.
Inherited from
Struct({
/ The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%). /
royaltyFee: UInt32, // 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%
/ The transfer fee amount. /
transferFee: UInt64,
/ If true, transferring NFTs requires approval from the admin contract. /
requireTransferApproval: Bool,
/ If true, the minting is stopped and cannot be resumed. /
mintingIsLimited: Bool,
/ Indicates whether the collection is currently paused. /
isPaused: Bool,
}).requireTransferApproval
royaltyFee
royaltyFee: UInt32 = UInt32;
Defined in: packages/nft/src/interfaces/types.ts:456
The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%).
Inherited from
Struct({
/ The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%). /
royaltyFee: UInt32, // 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%
/ The transfer fee amount. /
transferFee: UInt64,
/ If true, transferring NFTs requires approval from the admin contract. /
requireTransferApproval: Bool,
/ If true, the minting is stopped and cannot be resumed. /
mintingIsLimited: Bool,
/ Indicates whether the collection is currently paused. /
isPaused: Bool,
}).royaltyFee
transferFee
transferFee: UInt64 = UInt64;
Defined in: packages/nft/src/interfaces/types.ts:458
The transfer fee amount.
Inherited from
Struct({
/ The royalty fee percentage (e.g., 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%). /
royaltyFee: UInt32, // 1000 = 1%, 100 = 0.1%, 10000 = 10%, 100000 = 100%
/ The transfer fee amount. /
transferFee: UInt64,
/ If true, transferring NFTs requires approval from the admin contract. /
requireTransferApproval: Bool,
/ If true, the minting is stopped and cannot be resumed. /
mintingIsLimited: Bool,
/ Indicates whether the collection is currently paused. /
isPaused: Bool,
}).transferFee
Methods
pack()
pack(): Field
Defined in: packages/nft/src/interfaces/types.ts:498
Packs the CollectionData into a CollectionDataPacked representation for efficient storage.
Returns
Field
The packed CollectionDataPacked instance.
isPaused()
static isPaused(packed: Field): Bool
Defined in: packages/nft/src/interfaces/types.ts:531
Parameters
packed
Field
Returns
Bool
mintingIsLimited()
static mintingIsLimited(packed: Field): Bool
Defined in: packages/nft/src/interfaces/types.ts:539
Parameters
packed
Field
Returns
Bool
new()
static new(params: {
isPaused: boolean;
mintingIsLimited: boolean;
requireTransferApproval: boolean;
royaltyFee: number;
transferFee: number;
}): CollectionData
Defined in: packages/nft/src/interfaces/types.ts:471
Creates a new CollectionData instance with specified parameters.
Parameters
params
The parameters to create the CollectionData.
isPaused
boolean
mintingIsLimited
boolean
requireTransferApproval
boolean
royaltyFee
number
transferFee
number
Returns
A new CollectionData instance.
requireTransferApproval()
static requireTransferApproval(packed: Field): Bool
Defined in: packages/nft/src/interfaces/types.ts:535
Parameters
packed
Field
Returns
Bool
unpack()
static unpack(packed: Field): CollectionData
Defined in: packages/nft/src/interfaces/types.ts:513
Unpacks a CollectionDataPacked instance into a CollectionData instance.
Parameters
packed
Field
The packed CollectionDataPacked instance.
Returns
A new CollectionData instance.
Updated 10 days ago