VerificationKeyUpgradeData
Class: VerificationKeyUpgradeData
Properties overview
- address: PublicKey = PublicKey; ↗
- newVerificationKeyHash: Field = Field; ↗
- previousVerificationKeyHash: Field = Field; ↗
- tokenId: Field = Field; ↗
Methods overview
- hash() ↗
Defined in: packages/upgradable/src/upgradable.ts:27
Represents the data required to upgrade a contract's verification key.
It includes the contract's address, token ID, previous verification key hash,
and the new verification key hash. This class also provides a hash()
method
to generate a unique identifier for the upgrade data.
Extends
- {
address
:PublicKey
;
newVerificationKeyHash
:Field
;
previousVerificationKeyHash
:Field
;
tokenId
:Field
;
}
Constructors
new VerificationKeyUpgradeData()
new VerificationKeyUpgradeData(value: {
address: PublicKey;
newVerificationKeyHash: Field;
previousVerificationKeyHash: Field;
tokenId: Field;
}): VerificationKeyUpgradeData
Defined in: node_modules/o1js/dist/node/lib/provable/types/struct.d.ts:103
Parameters
value
address
PublicKey
= PublicKey
The address of the contract to be upgraded.
newVerificationKeyHash
Field
= Field
The hash of the new verification key.
previousVerificationKeyHash
Field
= Field
The hash of the previous verification key.
tokenId
Field
= Field
The token ID associated with the contract.
Returns
Inherited from
Struct({
/ The address of the contract to be upgraded. /
address: PublicKey,
/ The token ID associated with the contract. /
tokenId: Field,
/ The hash of the previous verification key. /
previousVerificationKeyHash: Field,
/ The hash of the new verification key. /
newVerificationKeyHash: Field,
}).constructor
Properties
address
address: PublicKey = PublicKey;
Defined in: packages/upgradable/src/upgradable.ts:29
The address of the contract to be upgraded.
Inherited from
Struct({
/ The address of the contract to be upgraded. /
address: PublicKey,
/ The token ID associated with the contract. /
tokenId: Field,
/ The hash of the previous verification key. /
previousVerificationKeyHash: Field,
/ The hash of the new verification key. /
newVerificationKeyHash: Field,
}).address
newVerificationKeyHash
newVerificationKeyHash: Field = Field;
Defined in: packages/upgradable/src/upgradable.ts:35
The hash of the new verification key.
Inherited from
Struct({
/ The address of the contract to be upgraded. /
address: PublicKey,
/ The token ID associated with the contract. /
tokenId: Field,
/ The hash of the previous verification key. /
previousVerificationKeyHash: Field,
/ The hash of the new verification key. /
newVerificationKeyHash: Field,
}).newVerificationKeyHash
previousVerificationKeyHash
previousVerificationKeyHash: Field = Field;
Defined in: packages/upgradable/src/upgradable.ts:33
The hash of the previous verification key.
Inherited from
Struct({
/ The address of the contract to be upgraded. /
address: PublicKey,
/ The token ID associated with the contract. /
tokenId: Field,
/ The hash of the previous verification key. /
previousVerificationKeyHash: Field,
/ The hash of the new verification key. /
newVerificationKeyHash: Field,
}).previousVerificationKeyHash
tokenId
tokenId: Field = Field;
Defined in: packages/upgradable/src/upgradable.ts:31
The token ID associated with the contract.
Inherited from
Struct({
/ The address of the contract to be upgraded. /
address: PublicKey,
/ The token ID associated with the contract. /
tokenId: Field,
/ The hash of the previous verification key. /
previousVerificationKeyHash: Field,
/ The hash of the new verification key. /
newVerificationKeyHash: Field,
}).tokenId
Methods
hash()
hash(): Field
Defined in: packages/upgradable/src/upgradable.ts:41
Generates a unique hash for the upgrade data using the Poseidon hash function.
Returns
Field
The hash representing the upgrade data.
Updated 10 days ago