Documentation
¶
Overview ¶
Package byte_operations provides helper functions to (un-) marshal objects from or into a buffer
Index ¶
- type ByteOperations
- func (bo *ByteOperations) CopyBytesFromBuffer(length uint64, out []byte) ([]byte, error)
- func (bo *ByteOperations) CopyBytesToBuffer(copyBytes []byte) error
- func (bo *ByteOperations) CopyBytesToBufferWithUint32LengthIndicator(copyBytes []byte) error
- func (bo *ByteOperations) CopyBytesToBufferWithUint64LengthIndicator(copyBytes []byte) error
- func (bo *ByteOperations) DiscardBytesFromBufferWithUint32LengthIndicator() uint32
- func (bo *ByteOperations) DiscardBytesFromBufferWithUint64LengthIndicator() uint64
- func (bo *ByteOperations) MoveBufferPositionForward(length uint64)
- func (bo *ByteOperations) MoveBufferToAbsolutePosition(pos uint64)
- func (bo *ByteOperations) ReadBytesFromBuffer(length uint64) []byte
- func (bo *ByteOperations) ReadBytesFromBufferWithUint32LengthIndicator() []byte
- func (bo *ByteOperations) ReadBytesFromBufferWithUint64LengthIndicator() []byte
- func (bo *ByteOperations) ReadUint16() uint16
- func (bo *ByteOperations) ReadUint32() uint32
- func (bo *ByteOperations) ReadUint64() uint64
- func (bo *ByteOperations) ReadUint8() uint8
- func (bo *ByteOperations) WriteByte(b byte)
- func (bo *ByteOperations) WriteUint16(value uint16)
- func (bo *ByteOperations) WriteUint32(value uint32)
- func (bo *ByteOperations) WriteUint64(value uint64)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ByteOperations ¶
func (*ByteOperations) CopyBytesFromBuffer ¶
func (bo *ByteOperations) CopyBytesFromBuffer(length uint64, out []byte) ([]byte, error)
func (*ByteOperations) CopyBytesToBuffer ¶
func (bo *ByteOperations) CopyBytesToBuffer(copyBytes []byte) error
func (*ByteOperations) CopyBytesToBufferWithUint32LengthIndicator ¶ added in v1.18.0
func (bo *ByteOperations) CopyBytesToBufferWithUint32LengthIndicator(copyBytes []byte) error
Writes a uint32 length indicator about the buffer that's about to follow, then writes the buffer itself
func (*ByteOperations) CopyBytesToBufferWithUint64LengthIndicator ¶ added in v1.18.0
func (bo *ByteOperations) CopyBytesToBufferWithUint64LengthIndicator(copyBytes []byte) error
Writes a uint64 length indicator about the buffer that's about to follow, then writes the buffer itself
func (*ByteOperations) DiscardBytesFromBufferWithUint32LengthIndicator ¶ added in v1.18.0
func (bo *ByteOperations) DiscardBytesFromBufferWithUint32LengthIndicator() uint32
func (*ByteOperations) DiscardBytesFromBufferWithUint64LengthIndicator ¶ added in v1.18.0
func (bo *ByteOperations) DiscardBytesFromBufferWithUint64LengthIndicator() uint64
func (*ByteOperations) MoveBufferPositionForward ¶
func (bo *ByteOperations) MoveBufferPositionForward(length uint64)
func (*ByteOperations) MoveBufferToAbsolutePosition ¶ added in v1.18.0
func (bo *ByteOperations) MoveBufferToAbsolutePosition(pos uint64)
func (*ByteOperations) ReadBytesFromBuffer ¶ added in v1.18.0
func (bo *ByteOperations) ReadBytesFromBuffer(length uint64) []byte
func (*ByteOperations) ReadBytesFromBufferWithUint32LengthIndicator ¶ added in v1.18.0
func (bo *ByteOperations) ReadBytesFromBufferWithUint32LengthIndicator() []byte
func (*ByteOperations) ReadBytesFromBufferWithUint64LengthIndicator ¶ added in v1.18.0
func (bo *ByteOperations) ReadBytesFromBufferWithUint64LengthIndicator() []byte
func (*ByteOperations) ReadUint16 ¶
func (bo *ByteOperations) ReadUint16() uint16
func (*ByteOperations) ReadUint32 ¶
func (bo *ByteOperations) ReadUint32() uint32
func (*ByteOperations) ReadUint64 ¶
func (bo *ByteOperations) ReadUint64() uint64
func (*ByteOperations) ReadUint8 ¶ added in v1.18.1
func (bo *ByteOperations) ReadUint8() uint8
func (*ByteOperations) WriteByte ¶
func (bo *ByteOperations) WriteByte(b byte)
func (*ByteOperations) WriteUint16 ¶
func (bo *ByteOperations) WriteUint16(value uint16)
func (*ByteOperations) WriteUint32 ¶
func (bo *ByteOperations) WriteUint32(value uint32)
func (*ByteOperations) WriteUint64 ¶
func (bo *ByteOperations) WriteUint64(value uint64)
Click to show internal directories.
Click to hide internal directories.