Versions in this module Expand all Collapse all v2 v2.1.2 Aug 19, 2024 v2.1.1 Aug 19, 2024 Changes in this version + const AddressBytesLen + const BLSEncryptedPrivateKeyBytesLen + const BLSPrivateKeyBytesLen + const BLSPublicKeyBytesLen + const BLSSignatureBytesLen + const ChainIdBytesLen + const ContractHashBytesLen + const CycleNonceBytesLen + const Ed25519EncryptedSeedBytesLen + const Ed25519PublicKeyBytesLen + const Ed25519SeedBytesLen + const GenericSignatureBytesLen + const HashBytesLen + const P256EncryptedPrivateKeyBytesLen + const P256PrivateKeyBytesLen + const P256PublicKeyBytesLen + const PKHBytesLen + const ProofOfWorkNonceBytesLen + const Secp256k1EncryptedPrivateKeyBytesLen + const Secp256k1PrivateKeyBytesLen + const Secp256k1PublicKeyBytesLen + const SecretBytesLen + const SeedNonceBytesLen + const SlotHeaderBytesLen + var ErrInvalidDecryptedLen = errors.New("gomav: invalid decrypted key length") + var ErrInvalidKeyLen = errors.New("gomav: invalid key length") + var ErrPrivateKeyDecrypt = errors.New("gomav: unable to decrypt the private key") + type AnySignature []byte + func (sig AnySignature) MarshalJSON() ([]byte, error) + func (sig AnySignature) MarshalText() ([]byte, error) + func (sig AnySignature) Signature() (Signature, error) + func (sig AnySignature) String() string + type BLSEncryptedPrivateKey [BLSEncryptedPrivateKeyBytesLen]byte + func (pk *BLSEncryptedPrivateKey) Decrypt(passCb func() ([]byte, error)) (PrivateKey, error) + func (self *BLSEncryptedPrivateKey) ToBase58() []byte + func (self *BLSEncryptedPrivateKey) UnmarshalText(src []byte) error + func (self BLSEncryptedPrivateKey) MarshalText() ([]byte, error) + func (self BLSEncryptedPrivateKey) String() string + type BLSPrivateKey [BLSPrivateKeyBytesLen]byte + func NewBLSPrivateKey(scalar []byte) (*BLSPrivateKey, error) + func (pk *BLSPrivateKey) Decrypt(func() ([]byte, error)) (PrivateKey, error) + func (priv *BLSPrivateKey) PrivateKey() + func (self *BLSPrivateKey) ToBase58() []byte + func (self *BLSPrivateKey) UnmarshalText(src []byte) error + func (self BLSPrivateKey) MarshalText() ([]byte, error) + func (self BLSPrivateKey) String() string + type BLSPublicKey [BLSPublicKeyBytesLen]byte + func NewBLSPublicKey(compressedPoint []byte) (*BLSPublicKey, error) + func (pk *BLSPublicKey) Hash() PublicKeyHash + func (pk *BLSPublicKey) PublicKey() + func (self *BLSPublicKey) ToBase58() []byte + func (self *BLSPublicKey) UnmarshalText(src []byte) error + func (self BLSPublicKey) MarshalText() ([]byte, error) + func (self BLSPublicKey) String() string + type BLSPublicKeyHash [AddressBytesLen]byte + func (pkh *BLSPublicKeyHash) Eq(other PublicKeyHash) bool + func (pkh *BLSPublicKeyHash) PublicKeyHash() []byte + func (pkh *BLSPublicKeyHash) ToComparable() (out EncodedPublicKeyHash) + func (self *BLSPublicKeyHash) ToBase58() []byte + func (self *BLSPublicKeyHash) UnmarshalText(src []byte) error + func (self BLSPublicKeyHash) MarshalText() ([]byte, error) + func (self BLSPublicKeyHash) String() string + type BLSSignature [BLSSignatureBytesLen]byte + func NewBLSSignature(compressedPoint []byte) *BLSSignature + func (self *BLSSignature) ToBase58() []byte + func (self *BLSSignature) UnmarshalText(src []byte) error + func (self BLSSignature) MarshalText() ([]byte, error) + func (self BLSSignature) String() string + func (sig *BLSSignature) Signature() + func (sig *BLSSignature) Split() (prefix *[32]byte, suffix *GenericSignature) + type Base58Encoder interface + String func() string + ToBase58 func() []byte + type BigInt []byte + func BigZero() BigInt + func NewBigInt(value *big.Int) BigInt + func NewBigInt64(val int64) BigInt + func ParseBigInt(str string, base int) (BigInt, error) + func (b *BigInt) DecodeMV(data []byte, ctx *encoding.Context) (rest []byte, err error) + func (b BigInt) Int() *big.Int + func (b BigInt) MarshalText() (text []byte, err error) + func (b BigInt) Sign() int + func (b BigInt) String() string + type BigUint []byte + func BigUZero() BigUint + func NewBigUint(value *big.Int) (BigUint, error) + func NewBigUint64(val uint64) BigUint + func ParseBigUint(str string, base int) (BigUint, error) + func (b *BigUint) DecodeMV(data []byte, ctx *encoding.Context) (rest []byte, err error) + func (b BigUint) Int() *big.Int + func (b BigUint) IsZero() bool + func (b BigUint) MarshalText() (text []byte, err error) + func (b BigUint) String() string + type BlindedPublicKeyHash [AddressBytesLen]byte + func (self *BlindedPublicKeyHash) ToBase58() []byte + func (self *BlindedPublicKeyHash) UnmarshalText(src []byte) error + func (self BlindedPublicKeyHash) MarshalText() ([]byte, error) + func (self BlindedPublicKeyHash) String() string + type BlockHash [HashBytesLen]byte + func (self *BlockHash) ToBase58() []byte + func (self *BlockHash) UnmarshalText(src []byte) error + func (self BlockHash) MarshalText() ([]byte, error) + func (self BlockHash) String() string + type BlockPayloadHash [HashBytesLen]byte + func (self *BlockPayloadHash) ToBase58() []byte + func (self *BlockPayloadHash) UnmarshalText(src []byte) error + func (self BlockPayloadHash) MarshalText() ([]byte, error) + func (self BlockPayloadHash) String() string + type Bytes []byte + func (b *Bytes) UnmarshalText(text []byte) error + func (b Bytes) MarshalText() (text []byte, err error) + type Bytes20 [20]byte + func (self *Bytes20) UnmarshalText(src []byte) error + func (self Bytes20) MarshalText() ([]byte, error) + func (self Bytes20) String() string + type Bytes32 [32]byte + func (self *Bytes32) UnmarshalText(src []byte) error + func (self Bytes32) MarshalText() ([]byte, error) + func (self Bytes32) String() string + type Bytes48 [48]byte + func (self *Bytes48) UnmarshalText(src []byte) error + func (self Bytes48) MarshalText() ([]byte, error) + func (self Bytes48) String() string + type Bytes8 [8]byte + func (self *Bytes8) UnmarshalText(src []byte) error + func (self Bytes8) MarshalText() ([]byte, error) + func (self Bytes8) String() string + type Bytes96 [96]byte + func (self *Bytes96) UnmarshalText(src []byte) error + func (self Bytes96) MarshalText() ([]byte, error) + func (self Bytes96) String() string + type ChainID [ChainIdBytesLen]byte + func (self *ChainID) ToBase58() []byte + func (self *ChainID) UnmarshalText(src []byte) error + func (self ChainID) MarshalText() ([]byte, error) + func (self ChainID) String() string + type Comparable interface + ToKey func() K + type ContextHash [HashBytesLen]byte + func (self *ContextHash) ToBase58() []byte + func (self *ContextHash) UnmarshalText(src []byte) error + func (self ContextHash) MarshalText() ([]byte, error) + func (self ContextHash) String() string + type ContractHash [AddressBytesLen]byte + func (self *ContractHash) ToBase58() []byte + func (self *ContractHash) UnmarshalText(src []byte) error + func (self ContractHash) MarshalText() ([]byte, error) + func (self ContractHash) String() string + type ConventionalSignature interface + Generic func() *GenericSignature + type CycleNonce [CycleNonceBytesLen]byte + func (self *CycleNonce) UnmarshalText(src []byte) error + func (self CycleNonce) MarshalText() ([]byte, error) + func (self CycleNonce) String() string + type CycleNonceHash [CycleNonceBytesLen]byte + func (self *CycleNonceHash) ToBase58() []byte + func (self *CycleNonceHash) UnmarshalText(src []byte) error + func (self CycleNonceHash) MarshalText() ([]byte, error) + func (self CycleNonceHash) String() string + type DALCommitment [SlotHeaderBytesLen]byte + func (self *DALCommitment) ToBase58() []byte + func (self *DALCommitment) UnmarshalText(src []byte) error + func (self DALCommitment) MarshalText() ([]byte, error) + func (self DALCommitment) String() string + type Ed25519EncryptedPrivateKey [Ed25519EncryptedSeedBytesLen]byte + func (pk *Ed25519EncryptedPrivateKey) Decrypt(passCb func() ([]byte, error)) (PrivateKey, error) + func (self *Ed25519EncryptedPrivateKey) ToBase58() []byte + func (self *Ed25519EncryptedPrivateKey) UnmarshalText(src []byte) error + func (self Ed25519EncryptedPrivateKey) MarshalText() ([]byte, error) + func (self Ed25519EncryptedPrivateKey) String() string + type Ed25519PrivateKey [Ed25519SeedBytesLen]byte + func NewEd25519PrivateKey(key []byte) (*Ed25519PrivateKey, error) + func (pk *Ed25519PrivateKey) Decrypt(func() ([]byte, error)) (PrivateKey, error) + func (priv *Ed25519PrivateKey) PrivateKey() + func (self *Ed25519PrivateKey) ToBase58() []byte + func (self *Ed25519PrivateKey) UnmarshalText(src []byte) error + func (self Ed25519PrivateKey) MarshalText() ([]byte, error) + func (self Ed25519PrivateKey) String() string + type Ed25519PublicKey [Ed25519PublicKeyBytesLen]byte + func NewEd25519PublicKey(key []byte) (*Ed25519PublicKey, error) + func (pk *Ed25519PublicKey) Hash() PublicKeyHash + func (pk *Ed25519PublicKey) PublicKey() + func (self *Ed25519PublicKey) ToBase58() []byte + func (self *Ed25519PublicKey) UnmarshalText(src []byte) error + func (self Ed25519PublicKey) MarshalText() ([]byte, error) + func (self Ed25519PublicKey) String() string + type Ed25519PublicKeyHash [AddressBytesLen]byte + func (pkh *Ed25519PublicKeyHash) Eq(other PublicKeyHash) bool + func (pkh *Ed25519PublicKeyHash) PublicKeyHash() []byte + func (pkh *Ed25519PublicKeyHash) ToComparable() (out EncodedPublicKeyHash) + func (self *Ed25519PublicKeyHash) ToBase58() []byte + func (self *Ed25519PublicKeyHash) UnmarshalText(src []byte) error + func (self Ed25519PublicKeyHash) MarshalText() ([]byte, error) + func (self Ed25519PublicKeyHash) String() string + type Ed25519Signature [GenericSignatureBytesLen]byte + func NewEd25519Signature(sig []byte) *Ed25519Signature + func (self *Ed25519Signature) ToBase58() []byte + func (self *Ed25519Signature) UnmarshalText(src []byte) error + func (self Ed25519Signature) MarshalText() ([]byte, error) + func (self Ed25519Signature) String() string + func (sig *Ed25519Signature) Generic() *GenericSignature + func (sig *Ed25519Signature) Signature() + type EncodedPublicKeyHash [publicKeyHashComparableKeyLen]byte + func (k *EncodedPublicKeyHash) UnmarshalText(text []byte) error + func (k EncodedPublicKeyHash) MarshalText() (text []byte, err error) + func (k EncodedPublicKeyHash) ToKey() PublicKeyHash + type EncryptedPrivateKey interface + Decrypt func(passCb func() ([]byte, error)) (PrivateKey, error) + type GenericSignature [GenericSignatureBytesLen]byte + func (self *GenericSignature) ToBase58() []byte + func (self *GenericSignature) UnmarshalText(src []byte) error + func (self GenericSignature) MarshalText() ([]byte, error) + func (self GenericSignature) String() string + func (sig *GenericSignature) Generic() *GenericSignature + func (sig *GenericSignature) Signature() + type OperationHash [HashBytesLen]byte + func (self *OperationHash) ToBase58() []byte + func (self *OperationHash) UnmarshalText(src []byte) error + func (self OperationHash) MarshalText() ([]byte, error) + func (self OperationHash) String() string + type OperationsHash [HashBytesLen]byte + func (self *OperationsHash) ToBase58() []byte + func (self *OperationsHash) UnmarshalText(src []byte) error + func (self OperationsHash) MarshalText() ([]byte, error) + func (self OperationsHash) String() string + type Option struct + func None[T any]() Option[T] + func Some[T any](val T) Option[T] + func (op *Option[T]) CheckUnwrapPtr() (*T, bool) + func (op *Option[T]) DecodeMV(data []byte, ctx *encoding.Context) (rest []byte, err error) + func (op *Option[T]) EncodeMV(ctx *encoding.Context) ([]byte, error) + func (op *Option[T]) MarshalJSON() ([]byte, error) + func (op *Option[T]) UnmarshalJSON(data []byte) error + func (op *Option[T]) UnwrapPtr() *T + func (op Option[T]) CheckUnwrap() (T, bool) + func (op Option[T]) GoString() string + func (op Option[T]) IsNone() bool + func (op Option[T]) IsSome() bool + func (op Option[T]) Or(val Option[T]) Option[T] + func (op Option[T]) OrElse(f func() Option[T]) Option[T] + func (op Option[T]) Unwrap() T + func (op Option[T]) UnwrapOr(def T) T + func (op Option[T]) UnwrapOrElse(f func() T) T + func (op Option[T]) UnwrapOrZero() T + func (op Option[T]) UnwrapUnchecked() T + type Option1 struct + func (op *Option1[T]) EncodeMV(ctx *encoding.Context) ([]byte, error) + type P256EncryptedPrivateKey [P256EncryptedPrivateKeyBytesLen]byte + func (pk *P256EncryptedPrivateKey) Decrypt(passCb func() ([]byte, error)) (PrivateKey, error) + func (self *P256EncryptedPrivateKey) ToBase58() []byte + func (self *P256EncryptedPrivateKey) UnmarshalText(src []byte) error + func (self P256EncryptedPrivateKey) MarshalText() ([]byte, error) + func (self P256EncryptedPrivateKey) String() string + type P256PrivateKey [P256PrivateKeyBytesLen]byte + func NewP256PrivateKey(scalar *big.Int) (*P256PrivateKey, error) + func (pk *P256PrivateKey) Decrypt(func() ([]byte, error)) (PrivateKey, error) + func (priv *P256PrivateKey) PrivateKey() + func (self *P256PrivateKey) ToBase58() []byte + func (self *P256PrivateKey) UnmarshalText(src []byte) error + func (self P256PrivateKey) MarshalText() ([]byte, error) + func (self P256PrivateKey) String() string + type P256PublicKey [P256PublicKeyBytesLen]byte + func NewP256PublicKey(compressedPoint []byte) (*P256PublicKey, error) + func (pk *P256PublicKey) Hash() PublicKeyHash + func (pk *P256PublicKey) PublicKey() + func (self *P256PublicKey) ToBase58() []byte + func (self *P256PublicKey) UnmarshalText(src []byte) error + func (self P256PublicKey) MarshalText() ([]byte, error) + func (self P256PublicKey) String() string + type P256PublicKeyHash [AddressBytesLen]byte + func (pkh *P256PublicKeyHash) Eq(other PublicKeyHash) bool + func (pkh *P256PublicKeyHash) PublicKeyHash() []byte + func (pkh *P256PublicKeyHash) ToComparable() (out EncodedPublicKeyHash) + func (self *P256PublicKeyHash) ToBase58() []byte + func (self *P256PublicKeyHash) UnmarshalText(src []byte) error + func (self P256PublicKeyHash) MarshalText() ([]byte, error) + func (self P256PublicKeyHash) String() string + type P256Signature [GenericSignatureBytesLen]byte + func NewP256Signature(r, s *big.Int) *P256Signature + func (self *P256Signature) ToBase58() []byte + func (self *P256Signature) UnmarshalText(src []byte) error + func (self P256Signature) MarshalText() ([]byte, error) + func (self P256Signature) String() string + func (sig *P256Signature) Generic() *GenericSignature + func (sig *P256Signature) Point() (r, s *big.Int) + func (sig *P256Signature) Signature() + type PrivateKey interface + PrivateKey func() + type ProtocolHash [HashBytesLen]byte + func (self *ProtocolHash) ToBase58() []byte + func (self *ProtocolHash) UnmarshalText(src []byte) error + func (self ProtocolHash) MarshalText() ([]byte, error) + func (self ProtocolHash) String() string + type PublicKey interface + Hash func() PublicKeyHash + PublicKey func() + type PublicKeyHash interface + Eq func(other PublicKeyHash) bool + PublicKeyHash func() []byte + type ScRollupAddress [AddressBytesLen]byte + func (self *ScRollupAddress) ToBase58() []byte + func (self *ScRollupAddress) UnmarshalText(src []byte) error + func (self ScRollupAddress) MarshalText() ([]byte, error) + func (self ScRollupAddress) String() string + type ScRollupCommitmentHash [HashBytesLen]byte + func (self *ScRollupCommitmentHash) ToBase58() []byte + func (self *ScRollupCommitmentHash) UnmarshalText(src []byte) error + func (self ScRollupCommitmentHash) MarshalText() ([]byte, error) + func (self ScRollupCommitmentHash) String() string + type ScRollupStateHash [HashBytesLen]byte + func (self *ScRollupStateHash) ToBase58() []byte + func (self *ScRollupStateHash) UnmarshalText(src []byte) error + func (self ScRollupStateHash) MarshalText() ([]byte, error) + func (self ScRollupStateHash) String() string + type ScriptExprHash [HashBytesLen]byte + func (self *ScriptExprHash) ToBase58() []byte + func (self *ScriptExprHash) UnmarshalText(src []byte) error + func (self ScriptExprHash) MarshalText() ([]byte, error) + func (self ScriptExprHash) String() string + type Secp256k1EncryptedPrivateKey [Secp256k1EncryptedPrivateKeyBytesLen]byte + func (pk *Secp256k1EncryptedPrivateKey) Decrypt(passCb func() ([]byte, error)) (PrivateKey, error) + func (self *Secp256k1EncryptedPrivateKey) ToBase58() []byte + func (self *Secp256k1EncryptedPrivateKey) UnmarshalText(src []byte) error + func (self Secp256k1EncryptedPrivateKey) MarshalText() ([]byte, error) + func (self Secp256k1EncryptedPrivateKey) String() string + type Secp256k1PrivateKey [Secp256k1PrivateKeyBytesLen]byte + func NewSecp256k1PrivateKey(scalar *big.Int) (*Secp256k1PrivateKey, error) + func (pk *Secp256k1PrivateKey) Decrypt(func() ([]byte, error)) (PrivateKey, error) + func (priv *Secp256k1PrivateKey) PrivateKey() + func (self *Secp256k1PrivateKey) ToBase58() []byte + func (self *Secp256k1PrivateKey) UnmarshalText(src []byte) error + func (self Secp256k1PrivateKey) MarshalText() ([]byte, error) + func (self Secp256k1PrivateKey) String() string + type Secp256k1PublicKey [Secp256k1PublicKeyBytesLen]byte + func NewSecp256k1PublicKey(compressedPoint []byte) (*Secp256k1PublicKey, error) + func (pk *Secp256k1PublicKey) Hash() PublicKeyHash + func (pk *Secp256k1PublicKey) PublicKey() + func (self *Secp256k1PublicKey) ToBase58() []byte + func (self *Secp256k1PublicKey) UnmarshalText(src []byte) error + func (self Secp256k1PublicKey) MarshalText() ([]byte, error) + func (self Secp256k1PublicKey) String() string + type Secp256k1PublicKeyHash [AddressBytesLen]byte + func (pkh *Secp256k1PublicKeyHash) Eq(other PublicKeyHash) bool + func (pkh *Secp256k1PublicKeyHash) PublicKeyHash() []byte + func (pkh *Secp256k1PublicKeyHash) ToComparable() (out EncodedPublicKeyHash) + func (self *Secp256k1PublicKeyHash) ToBase58() []byte + func (self *Secp256k1PublicKeyHash) UnmarshalText(src []byte) error + func (self Secp256k1PublicKeyHash) MarshalText() ([]byte, error) + func (self Secp256k1PublicKeyHash) String() string + type Secp256k1Signature [GenericSignatureBytesLen]byte + func NewSecp256k1Signature(r, s *big.Int) *Secp256k1Signature + func (self *Secp256k1Signature) ToBase58() []byte + func (self *Secp256k1Signature) UnmarshalText(src []byte) error + func (self Secp256k1Signature) MarshalText() ([]byte, error) + func (self Secp256k1Signature) String() string + func (sig *Secp256k1Signature) Generic() *GenericSignature + func (sig *Secp256k1Signature) Point() (r, s *big.Int) + func (sig *Secp256k1Signature) Signature() + type SeedNonce [SeedNonceBytesLen]byte + func (self *SeedNonce) UnmarshalText(src []byte) error + func (self SeedNonce) MarshalText() ([]byte, error) + func (self SeedNonce) String() string + type Signature interface + Signature func() + type SmartRollupAddress [AddressBytesLen]byte + func (self *SmartRollupAddress) ToBase58() []byte + func (self *SmartRollupAddress) UnmarshalText(src []byte) error + func (self SmartRollupAddress) MarshalText() ([]byte, error) + func (self SmartRollupAddress) String() string + type SmartRollupCommitmentHash [HashBytesLen]byte + func (self *SmartRollupCommitmentHash) ToBase58() []byte + func (self *SmartRollupCommitmentHash) UnmarshalText(src []byte) error + func (self SmartRollupCommitmentHash) MarshalText() ([]byte, error) + func (self SmartRollupCommitmentHash) String() string + type SmartRollupStateHash [HashBytesLen]byte + func (self *SmartRollupStateHash) ToBase58() []byte + func (self *SmartRollupStateHash) UnmarshalText(src []byte) error + func (self SmartRollupStateHash) MarshalText() ([]byte, error) + func (self SmartRollupStateHash) String() string + type String string + func (str *String) DecodeMV(data []byte, ctx *encoding.Context) ([]byte, error) + func (str String) EncodeMV(ctx *encoding.Context) ([]byte, error) + type TXRollupAddress [AddressBytesLen]byte + func (self *TXRollupAddress) ToBase58() []byte + func (self *TXRollupAddress) UnmarshalText(src []byte) error + func (self TXRollupAddress) MarshalText() ([]byte, error) + func (self TXRollupAddress) String() string + type Timestamp int64 + func (t Timestamp) String() string + func (t Timestamp) Time() time.Time + type ToComparable interface + ToComparable func() H + type ZkRollupAddress [AddressBytesLen]byte + func (self *ZkRollupAddress) ToBase58() []byte + func (self *ZkRollupAddress) UnmarshalText(src []byte) error + func (self ZkRollupAddress) MarshalText() ([]byte, error) + func (self ZkRollupAddress) String() string