Class: BLSPublicKey
@nimiq/core / BLSPublicKey
Defined in: @nimiq/core/types/wasm/web.d.ts:774
The public part of the BLS keypair. This is specified in the staking contract to verify votes from Validators.
Constructors
Constructor
new BLSPublicKey(
bytes):BLSPublicKey
Defined in: @nimiq/core/types/wasm/web.d.ts:792
Creates a new public key from a byte array.
Parameters
bytes
Uint8Array
Returns
BLSPublicKey
Methods
[dispose]()
[dispose]():
void
Defined in: @nimiq/core/types/wasm/web.d.ts:776
Returns
void
free()
free():
void
Defined in: @nimiq/core/types/wasm/web.d.ts:775
Returns
void
serialize()
serialize():
Uint8Array
Defined in: @nimiq/core/types/wasm/web.d.ts:796
Serializes the public key to a byte array.
Returns
Uint8Array
toHex()
toHex():
string
Defined in: @nimiq/core/types/wasm/web.d.ts:800
Formats the public key into a hex string.
Returns
string
derive()
staticderive(secret_key):BLSPublicKey
Defined in: @nimiq/core/types/wasm/web.d.ts:780
Derives a public key from an existing private key.
Parameters
secret_key
Returns
BLSPublicKey
deserialize()
staticdeserialize(bytes):BLSPublicKey
Defined in: @nimiq/core/types/wasm/web.d.ts:784
Deserializes a public key from a byte array.
Parameters
bytes
Uint8Array
Returns
BLSPublicKey
fromHex()
staticfromHex(hex):BLSPublicKey
Defined in: @nimiq/core/types/wasm/web.d.ts:788
Parses a public key from its hex representation.
Parameters
hex
string
Returns
BLSPublicKey