Key
in package
Table of Contents
Methods
- convertPrivateKeyToBech32() : string
- Convert a private hex key to bech32.
- convertPublicKeyToBech32() : string
- Convert a public hex key to bech32.
- convertToHex() : string
- Convert a key to hex.
- generatePrivateKey() : string
- Generate private key as hex.
- getPublicKey() : string
- Generate public key from private key as hex.
- convertToBech32() : string
- Convert a hex key to bech32.
Methods
convertPrivateKeyToBech32()
Convert a private hex key to bech32.
public
convertPrivateKeyToBech32(string $key) : string
Parameters
- $key : string
Return values
stringconvertPublicKeyToBech32()
Convert a public hex key to bech32.
public
convertPublicKeyToBech32(string $key) : string
Parameters
- $key : string
Return values
stringconvertToHex()
Convert a key to hex.
public
convertToHex(string $key) : string
Parameters
- $key : string
Return values
stringgeneratePrivateKey()
Generate private key as hex.
public
generatePrivateKey() : string
Return values
stringgetPublicKey()
Generate public key from private key as hex.
public
getPublicKey(string $private_hex) : string
Parameters
- $private_hex : string
Return values
stringconvertToBech32()
Convert a hex key to bech32.
protected
convertToBech32(string $key, string $prefix) : string
Parameters
- $key : string
- $prefix : string