basics

package
v0.0.0-...-4bf9e1d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 9, 2023 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Address

type Address crypto.Digest

Address is a unique identifier corresponding to ownership of money

func UnmarshalChecksumAddress

func UnmarshalChecksumAddress(address string) (Address, error)

UnmarshalChecksumAddress tries to unmarshal the checksummed address string. Algorand strings addresses ( base32 encoded ) have a postamble which serves as the checksum of the address. When converted to an Address object representation, that checksum is dropped (after validation).

func (*Address) CanMarshalMsg

func (_ *Address) CanMarshalMsg(z interface{}) bool

func (*Address) CanUnmarshalMsg

func (_ *Address) CanUnmarshalMsg(z interface{}) bool

func (Address) GetChecksum

func (addr Address) GetChecksum() []byte

GetChecksum returns the checksum as []byte Checksum in Algorand are the last 4 bytes of the shortAddress Hash. H(Address)[28:]

func (Address) GetUserAddress

func (addr Address) GetUserAddress() string

GetUserAddress returns the human-readable, checksummed version of the address

func (Address) IsZero

func (addr Address) IsZero() bool

IsZero checks if an address is the zero value.

func (*Address) MarshalMsg

func (z *Address) MarshalMsg(b []byte) []byte

MarshalMsg implements msgp.Marshaler

func (Address) MarshalText

func (addr Address) MarshalText() ([]byte, error)

MarshalText returns the address string as an array of bytes

func (*Address) MsgIsZero

func (z *Address) MsgIsZero() bool

MsgIsZero returns whether this is a zero value

func (*Address) Msgsize

func (z *Address) Msgsize() int

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (Address) String

func (addr Address) String() string

String returns a string representation of Address

func (*Address) UnmarshalMsg

func (z *Address) UnmarshalMsg(bts []byte) ([]byte, error)

UnmarshalMsg implements msgp.Unmarshaler

func (*Address) UnmarshalText

func (addr *Address) UnmarshalText(text []byte) error

UnmarshalText initializes the Address from an array of bytes.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL