PublicKey

abstract class PublicKey

An abstract representation of a public key.

Provides a common interface for verifying any signature.

Inheritors

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
abstract fun toBcs(): ByteArray

Get the BCS bytes

Link copied to clipboard
abstract fun toByteArray(): ByteArray

Get the raw public key bytes

Link copied to clipboard
open override fun toString(): String

Get the public key as a hex string with a 0x prefix e.g. 0x123456...

Link copied to clipboard
abstract fun verifySignature(message: HexInput, signature: Signature): Boolean

Verifies that the private key associated with this public key signed the message with the given signature.