Versions in this module Expand all Collapse all v1 v1.0.4 Jul 20, 2023 v1.0.2 Jul 20, 2023 Changes in this version + const BytesOpSize + const StringOpSize + var ErrLimit = errors.New("read reached limit") + func HandleRecovery(e any) error + func ReadAllLimit(r io.Reader, limit int) ([]byte, error) + func Write(w io.Writer, p []byte, np *int64) error + func WriteAndReset(w *Writer, iow io.Writer, np *int64) error + func WriteAndResetPanic(w *Writer, iow io.Writer, np *int64) + func WritePanic(w io.Writer, p []byte, np *int64) + func WriteString(w io.Writer, s string, np *int64) error + func WriteStringPanic(w io.Writer, s string, np *int64) + func WriteTo(wt io.WriterTo, w io.Writer, np *int64) error + func WriteToPanic(wt io.WriterTo, w io.Writer, np *int64) + type Data interface + Bytes func() []byte + type OpWriter struct + func NewOpWriter(buf []byte) *OpWriter + func OpWriterAppendEmbedded(w *OpWriter, emb T) *OpWriter + func (w *OpWriter) AppendByte(b byte) *OpWriter + func (w *OpWriter) AppendBytes(bs []byte) *OpWriter + func (w *OpWriter) AppendEmbeddedBytes(bs []byte) *OpWriter + func (w *OpWriter) AppendEmbeddedString(s string) *OpWriter + func (w *OpWriter) AppendString(s string) *OpWriter + func (w *OpWriter) AppendUint16(u uint16) *OpWriter + func (w *OpWriter) AppendUint32(u uint32) *OpWriter + func (w *OpWriter) AppendUint64(u uint64) *OpWriter + func (w *OpWriter) AppendWriter(writer io.WriterTo, size int) *OpWriter + func (w *OpWriter) Bytes() []byte + func (w *OpWriter) Clear() + func (w *OpWriter) Read(p []byte) (n int, err error) + func (w *OpWriter) Reset() + func (w *OpWriter) SetBuf(buf []byte) *OpWriter + func (w *OpWriter) Size() int + func (w *OpWriter) WriteTo(_w io.Writer) (n int64, err error) + type Writer struct + Buf []byte + func (w *Writer) Bytes() []byte + func (w *Writer) Len() int + func (w *Writer) Remain() int + func (w *Writer) Reset() + func (w *Writer) ResetBuf(buf []byte) + func (w *Writer) Write(p []byte) (n int, err error) + func (w *Writer) WriteByte(b byte) *Writer + func (w *Writer) WriteBytes(p []byte) (n int) + func (w *Writer) WriteBytesAnd(p []byte) *Writer + func (w *Writer) WriteLittleUint16(u uint16) *Writer + func (w *Writer) WriteLittleUint32(u uint32) *Writer + func (w *Writer) WriteLittleUint64(u uint64) *Writer + func (w *Writer) WriteString(s string) (n int) + func (w *Writer) WriteStringAnd(s string) *Writer + func (w *Writer) WriteUint16(u uint16) *Writer + func (w *Writer) WriteUint32(u uint32) *Writer + func (w *Writer) WriteUint64(u uint64) *Writer + func (w *Writer) WriterTo(wt io.Writer, np *int64) error + func (w *Writer) WriterToAndReset(wt io.Writer, np *int64) error