textandbinarywriter

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2026 License: MIT Imports: 3 Imported by: 0

README

Tests on Linux, MacOS and Windows Go Report Card GoDoc

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BlobMarker [8]byte = [8]byte{'T', 'A', 'K', '3', '5', 'E', 'M', '1'}

BlobMarker is used to identify start of a binary blob.

Functions

func ReadBlobHeader

func ReadBlobHeader(r io.Reader) (id, size uint32, err error)

ReadBlobHeader reads a blob header from r and returns the id and size using little-endian encoding.

func ReadBlobHeaderExcludingMarker

func ReadBlobHeaderExcludingMarker(r io.Reader) (id, size uint32, err error)

ReadBlobHeaderExcludingMarker reads a blob header from r excluding the marker using little-endian encoding.

func WriteBlobHeader

func WriteBlobHeader(w io.Writer, id, size uint32) error

WriteBlobHeader writes a blob header to w with the given id and size using little-endian encoding.

Types

type Writer

type Writer struct {
	// contains filtered or unexported fields
}

func NewWriter

func NewWriter(textw, binaryw io.Writer) *Writer

func (*Writer) Close

func (w *Writer) Close() (err error)

func (*Writer) Write

func (w *Writer) Write(p []byte) (n int, err error)

Write implements io.Writer.

Jump to

Keyboard shortcuts

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