Documentation ¶
Index ¶
- func Clone(b []byte) []byte
- func CloneSlice(a [][]byte) [][]byte
- func Contains(a [][]byte, x []byte) bool
- func Intersect(a, b [][]byte) [][]byte
- func IsSorted(a [][]byte) bool
- func Pack(a []byte, width int, val byte) []byte
- func SearchBytes(a [][]byte, x []byte) int
- func SearchBytesFixed(a []byte, sz int, fn func(x []byte) bool) int
- func Sort(a [][]byte)
- func SortDedup(a [][]byte) [][]byte
- func Union(a, b [][]byte) [][]byte
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CloneSlice ¶ added in v1.4.1
CloneSlice returns a copy of a slice of byte slices.
func Pack ¶ added in v1.5.0
Pack converts a sparse array to a dense one. It removes sections of a containing runs of val of length width. The returned value is a subslice of a.
func SearchBytes ¶
SearchBytes performs a binary search for x in the sorted slice a.
func SearchBytesFixed ¶ added in v1.4.1
SearchBytesFixed searches a for x using a binary search. The size of a must be a multiple of of x or else the function panics. There returned value is the index within a where x should exist. The caller should ensure that x does exist at this index.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.