bytes

package
v0.0.0-...-c1b4e3e Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2025 License: GPL-3.0, LGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func And

func And(a, b []byte) []byte

And, AND the contents: `a & b`. Returns the result, leaving `a` and `b` unmodified.

func AndInto

func AndInto(inout, b []byte)

AndInto, AND the contents of two byte-slices of same length, write result into first parameter. `inout` will contain `inout[i] & b[i]`, for all `i`.

func Or

func Or(a, b []byte) []byte

Or, OR the contents: `a | b`. Returns the result, leaving `a` and `b` unmodified.

func OrInto

func OrInto(inout, b []byte)

OrInto, OR the contents of two byte-slices of same length, write result into first parameter. `inout` will contain `inout[i] | b[i]`, for all `i`.

func ReadByte

func ReadByte(in io.Reader, buffer []byte) error

func ReadBytes

func ReadBytes(in io.Reader, buffer []byte) error

func ShiftLeft

func ShiftLeft(slice []byte, n int)

ShiftLeft shifts contents of byte-slice `n` bits left, for n >= 0.

func ShiftRight

func ShiftRight(slice []byte, n int)

ShiftRight shifts contents of byte-slice `n` bits right, for n >= 0.

func Xor

func Xor(a, b []byte) []byte

Xor, XOR the contents of `a ^ b`. Returns the result, leaving `a` and `b` unmodified.

func XorInto

func XorInto(inout, b []byte)

XorInto, XOR the contents of two byte-slices of same length, write result into first parameter. `inout` will contain `inout[i] ^ b[i]`, for all `i`.

Types

This section is empty.

Jump to

Keyboard shortcuts

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