Documentation ¶
Index ¶
Constants ¶
View Source
const ( MaxChunkLength = 4096 FileNameLength = 50 MaxDirectoryNameLength = 50 PathSeperator = string(os.PathSeparator) MaxPodNameLength = 25 SpanLength = 8 )
View Source
const (
AddressLength = 20
)
View Source
const (
ReferenceLength = 32
)
Variables ¶
View Source
var ( ErrEmptyString = &decError{"empty hex string"} ErrMissingPrefix = &decError{"hex string without 0x prefix"} ErrSyntax = &decError{"invalid hex string"} ErrOddLength = &decError{"hex string of odd length"} ErrUint64Range = &decError{"hex number > 64 bits"} )
View Source
var ZeroAddress = NewAddress(nil)
Functions ¶
func HashString ¶
Types ¶
type Address ¶
type Address [AddressLength]byte
func BytesToAddress ¶
func HexToAddress ¶
func NewAddress ¶
func (Address) StringToAddress ¶
type Reference ¶
type Reference struct {
// contains filtered or unexported fields
}
func NewReference ¶
func ParseHexReference ¶
type SharingReference ¶
type SharingReference struct {
// contains filtered or unexported fields
}
func NewSharingReference ¶
func NewSharingReference(b []byte, n int64) SharingReference
func ParseSharingReference ¶
func ParseSharingReference(s string) (a SharingReference, err error)
func (SharingReference) GetNonce ¶
func (ref SharingReference) GetNonce() int64
func (SharingReference) GetRef ¶
func (ref SharingReference) GetRef() []byte
func (SharingReference) String ¶
func (ref SharingReference) String() string
Click to show internal directories.
Click to hide internal directories.