Documentation
¶
Index ¶
Constants ¶
View Source
const VersionByte byte = 6 << 3
base32 encodes to G
Variables ¶
View Source
var XlmCrc16Tab = [256]uint16{}/* 256 elements not displayed */
Functions ¶
func NewAddressBuilder ¶
func NewAddressBuilder(cfg *xc.ChainBaseConfig) (xc.AddressBuilder, error)
Types ¶
type AddressBuilder ¶
type AddressBuilder struct{}
func (AddressBuilder) GetAddressFromPublicKey ¶
func (ab AddressBuilder) GetAddressFromPublicKey(publicKeyBytes []byte) (xc.Address, error)
GetAddressFromPublicKey generates an Address from a given public key. The method takes a public key in the form of a byte slice and returns a corresponding Address after encoding it with a version byte and a checksum. The public key must be 32 bytes long.
func (AddressBuilder) GetAllPossibleAddressesFromPublicKey ¶
func (ab AddressBuilder) GetAllPossibleAddressesFromPublicKey(publicKeyBytes []byte) ([]xc.PossibleAddress, error)
GetAllPossibleAddressesFromPublicKey returns all PossubleAddress(es) given a public key TODO: Consider listing all federation accounts for given public key [Stellar federation documentation]: https://developers.stellar.org/docs/learn/encyclopedia/network-configuration/federation#:~:text=Stellar%20federated%20addresses%20are%20divided,stellar.org%20is%20the%20domain
Click to show internal directories.
Click to hide internal directories.