Documentation ¶
Index ¶
Constants ¶
View Source
const IDLength = 16
IDLength is the exact length a string (or a byte slice representing it) must have in order to be decoded into a valid ID.
Variables ¶
View Source
var ( // ErrInvalidID signifies invalid IDs. ErrInvalidID = errors.New("invalid ID") // ErrInvalidIDLength is returned when an ID has the incorrect number of bytes. ErrInvalidIDLength = errors.New("id must have a length of 16 bytes") )
Functions ¶
func Decode ¶ added in v2.3.0
Decode parses id as a hex-encoded byte-slice-string.
It errors if the input byte slice does not have the correct length or if it contains all zeros.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.