Documentation ¶
Index ¶
- Constants
- Variables
- func ClientBlockAssembly(inCh <-chan []byte, out []chan []byte, wg *sync.WaitGroup, db int, ...)
- func CloseByteChan(out []chan []byte, name string)
- func GZIPDecompressor(inCh <-chan []byte, out chan<- []byte, wg *sync.WaitGroup)
- func GZIPcompressor(inp []byte) []byte
- func GetInnerCompression(msg []byte) uint16
- func JavaTSNow() uint64
- func LZMADecompressor(inCh <-chan []byte, out chan<- []byte, wg *sync.WaitGroup)
- func LZMAcompressor(inp []byte) []byte
- func SetHeader(block []byte, header TheHeader)
- func SetInnerHeader(block []byte, header InnerHeader)
- func ZeroDecompressor(inCh <-chan []byte, out chan<- []byte, wg *sync.WaitGroup)
- func Zerocompressor(in []byte) []byte
- type CompressableData
- type CompressedData
- type InnerHeader
- type TheHeader
- type TheMessage
Constants ¶
View Source
const CommDataBlockSize = 4096
View Source
const CommHeaderSize = 16
View Source
const InnerHeaderSize = 32
Variables ¶
View Source
var Compressors = [...]func([]byte) []byte{ Zerocompressor, LZMAcompressor, GZIPcompressor, }
View Source
var Decompressors = [...]func(<-chan []byte, chan<- []byte, *sync.WaitGroup){ ZeroDecompressor, LZMADecompressor, GZIPDecompressor, }
Functions ¶
func ClientBlockAssembly ¶
func CloseByteChan ¶
func GZIPDecompressor ¶
func GZIPcompressor ¶
func GetInnerCompression ¶
func LZMADecompressor ¶
func LZMAcompressor ¶
func SetInnerHeader ¶
func SetInnerHeader(block []byte, header InnerHeader)
func ZeroDecompressor ¶
func Zerocompressor ¶
Types ¶
type CompressableData ¶
type CompressedData ¶
type CompressedData struct { Header InnerHeader Data []byte }
type InnerHeader ¶
type InnerHeader struct { Compression uint16 // 0 // Datatype uint16 // 2 // Uncompressed uint32 // 4 HASH uint64 // 8 TS uint64 // 16 Reserved2 uint64 // 24 }
func GetInnerHeader ¶
func GetInnerHeader(msg []byte) (InnerHeader, []byte)
type TheHeader ¶
type TheMessage ¶
type TheMessage []byte
func (TheMessage) String ¶
func (b TheMessage) String() string
Click to show internal directories.
Click to hide internal directories.