Documentation ¶
Index ¶
- Constants
- func AtaSwap16(x uint16) uint16
- func AtaSwap32(x uint32) uint32
- func AtaSwapWordEndian(input []byte)
- func GetStrucOptions() *struc.Options
- func GetStrucOptionsWithBigEndian() *struc.Options
- func IsAlignedPointer(align int, pointer uintptr) bool
- func Ternary[T any](statement bool, a T, b T) T
- type AlignedBuffer
- func (b *AlignedBuffer) GetBuffer() []byte
- func (b *AlignedBuffer) GetCapacity() int
- func (b *AlignedBuffer) GetPointer() *byte
- func (b *AlignedBuffer) GetPos() int
- func (b *AlignedBuffer) Read(p []byte) (n int, err error)
- func (b *AlignedBuffer) Reset()
- func (b *AlignedBuffer) ResetRead()
- func (b *AlignedBuffer) ResetWrite()
- func (b *AlignedBuffer) SetLimit(limit int)
- func (b *AlignedBuffer) SetReadPos(offset int)
- func (b *AlignedBuffer) SetWritePos(offset int)
- func (b *AlignedBuffer) Write(p []byte) (n int, err error)
- func (b *AlignedBuffer) WriteByte(p byte) (err error)
- type WrappedBuffer
Constants ¶
View Source
const IS_64_BIT = uint64(^uintptr(0)) == ^uint64(0)
Variables ¶
This section is empty.
Functions ¶
func AtaSwapWordEndian ¶
func AtaSwapWordEndian(input []byte)
func GetStrucOptions ¶
func IsAlignedPointer ¶
Types ¶
type AlignedBuffer ¶
func NewAlignedBuffer ¶
func NewAlignedBuffer(align int, size int) *AlignedBuffer
func (*AlignedBuffer) GetBuffer ¶
func (b *AlignedBuffer) GetBuffer() []byte
func (*AlignedBuffer) GetCapacity ¶
func (b *AlignedBuffer) GetCapacity() int
func (*AlignedBuffer) GetPointer ¶
func (b *AlignedBuffer) GetPointer() *byte
func (*AlignedBuffer) GetPos ¶ added in v0.3.0
func (b *AlignedBuffer) GetPos() int
func (*AlignedBuffer) Reset ¶ added in v0.3.0
func (b *AlignedBuffer) Reset()
func (*AlignedBuffer) ResetRead ¶
func (b *AlignedBuffer) ResetRead()
func (*AlignedBuffer) ResetWrite ¶
func (b *AlignedBuffer) ResetWrite()
func (*AlignedBuffer) SetLimit ¶
func (b *AlignedBuffer) SetLimit(limit int)
func (*AlignedBuffer) SetReadPos ¶ added in v0.3.0
func (b *AlignedBuffer) SetReadPos(offset int)
func (*AlignedBuffer) SetWritePos ¶ added in v0.3.0
func (b *AlignedBuffer) SetWritePos(offset int)
func (*AlignedBuffer) WriteByte ¶ added in v0.3.0
func (b *AlignedBuffer) WriteByte(p byte) (err error)
type WrappedBuffer ¶
func NewWrappedBuffer ¶
func NewWrappedBuffer(buffer []byte) *WrappedBuffer
func (*WrappedBuffer) GetCapacity ¶
func (b *WrappedBuffer) GetCapacity() int
func (*WrappedBuffer) ResetRead ¶
func (b *WrappedBuffer) ResetRead()
func (*WrappedBuffer) ResetWrite ¶
func (b *WrappedBuffer) ResetWrite()
func (*WrappedBuffer) SetLimit ¶
func (b *WrappedBuffer) SetLimit(limit int)
Click to show internal directories.
Click to hide internal directories.