Versions in this module Expand all Collapse all v2 v2.3.3 Oct 19, 2023 Changes in this version + const AddressLength + const ZXAddrPrefix + const ZXAddrPrefixLength + const ZXAddrSuffixLength + const ZXAddressLength + var BlankHash = make([]byte, hashLength) + var ZeroHash = Keccak256(nil) + func EVMIntToHashBytes(i *Int) [hashLength]byte + func FromHex(s string) ([]byte, error) + func GetDataFrom(src []byte, offset uint64, size uint64) []byte + func Has0xPrefix(str string) bool + func Keccak256(data []byte) []byte + func LeftPadBytes(slice []byte, l int) []byte + func LeftPaddingSlice(src []byte, toSize int) []byte + func MarshalPublicKey(pk crypto.PublicKey) (pkBytes []byte, err error) + func MinI(i, j int64) int64 + func RightPaddingSlice(src []byte, toSize int) []byte + func ZXAddress(data []byte) (string, error) + func ZXAddressFromCertificatePEM(certPEM []byte) (string, error) + func ZXAddressFromCertificatePath(certPath string) (string, error) + func ZXAddressFromPublicKey(pk crypto.PublicKey) (string, error) + func ZXAddressFromPublicKeyDER(pkDER []byte) (string, error) + func ZXAddressFromPublicKeyPEM(pkPEM []byte) (string, error) + type Address [AddressLength]byte + func BigToAddress(b *Int) Address + func BytesToAddress(b []byte) Address + func HexToAddress(s string) (Address, error) + func MakeHexToAddress(s string) (Address, error) + func StringToAddress(s string) (Address, error) + func (a *Address) SetBytes(b []byte) + func (a *Address) String() string + type Int struct + func BytesDataToEVMIntHash(data []byte) *Int + func EthHashBytesToEVMInt(hash [hashLength]byte) (*Int, error) + func FromBigInt(i *big.Int) *Int + func FromDecimalString(s string) *Int + func FromHexString(s string) *Int + func FromString(ss string) *Int + func HashBytesToEVMInt(hash []byte) (*Int, error) + func MakeAddress(data []byte) *Int + func MakeAddressFromHex(str string) (*Int, error) + func MakeAddressFromString(str string) (*Int, error) + func MinInt(i, j *Int) *Int + func New(i int64) *Int + func (i *Int) Add(y *Int) *Int + func (i *Int) AddMod(y *Int, m *Int) *Int + func (i *Int) And(y *Int) *Int + func (i *Int) AsStringKey() string + func (i *Int) ByteAt(n int) byte + func (i *Int) Div(y *Int) *Int + func (i *Int) EQ(y *Int) bool + func (i *Int) Exp(e *Int) *Int + func (i *Int) GT(y *Int) bool + func (i *Int) GetSigned() *Int + func (i *Int) IsZero() bool + func (i *Int) LT(y *Int) bool + func (i *Int) Mod(m *Int) *Int + func (i *Int) Mul(y *Int) *Int + func (i *Int) MulMod(y *Int, m *Int) *Int + func (i *Int) Not(y *Int) *Int + func (i *Int) Or(y *Int) *Int + func (i *Int) SAR(n uint64) *Int + func (i *Int) SDiv(y *Int) *Int + func (i *Int) SGT(y *Int) bool + func (i *Int) SHL(n uint64) *Int + func (i *Int) SHR(n uint64) *Int + func (i *Int) SLT(y *Int) bool + func (i *Int) SMod(m *Int) *Int + func (i *Int) SignExtend(baseBytes *Int) *Int + func (i *Int) Sub(y *Int) *Int + func (i *Int) XOr(y *Int) *Int + func (i Int) Clone() *Int