syncio

package
v0.0.0-...-f756a1e Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package syncio contains synchronized wrappers for interfaces from io package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BufWriterAt

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

BufWriterAt is synchronized buffer which implements io.WriterAt.

func (*BufWriterAt) Bytes

func (b *BufWriterAt) Bytes() (r []byte)

Bytes returns copy of data from buffer.

func (*BufWriterAt) Len

func (b *BufWriterAt) Len() int

Len returns buffer available data size.

func (*BufWriterAt) ReadAt

func (b *BufWriterAt) ReadAt(p []byte, off int64) (n int, err error)

ReadAt implements io.ReaderAt.

func (*BufWriterAt) WriteAt

func (b *BufWriterAt) WriteAt(p []byte, off int64) (n int, err error)

WriteAt implements io.WriterAt.

type Reader

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

Reader is synchronized io.Reader.

func NewReader

func NewReader(r io.Reader) *Reader

NewReader creates new Reader.

func (*Reader) Read

func (s *Reader) Read(p []byte) (n int, err error)

Read implements io.Reader.

type WriterAt

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

WriterAt is synchronized io.WriterAt.

func NewWriterAt

func NewWriterAt(w io.WriterAt) *WriterAt

NewWriterAt creates new WriterAt.

func (*WriterAt) WriteAt

func (s *WriterAt) WriteAt(p []byte, off int64) (n int, err error)

WriteAt implements io.WriterAt.

Jump to

Keyboard shortcuts

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