Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RemoveContents ¶
RemoveContents removes the contents of the specified directory
Types ¶
type FileReaderIter ¶
type FileReaderIter interface {
// Current returns a slice of bytes for the current chunk read
// the return value is only valid until Next() is called next
Current() []byte
// Next returns a flag to indicate if the iterator was able to
// read the next chunk of data
Next() bool
// Err returns if the reader ran into an error
Err() error
// Checksum returns the running checksum
Checksum() uint32
// Close releases any releases held by the iter
Close() error
}
FileReaderIter is an iterator interface over a file
func NewBytesReaderIter ¶
func NewBytesReaderIter(bytes []byte) FileReaderIter
NewBytesReaderIter creates a new FileReaderIter to iterate over a fixed byte slice.
func NewFileReaderIter ¶
func NewFileReaderIter( filepath string, ) (FileReaderIter, error)
NewFileReaderIter creates a new buffered FileReaderIter
func NewSizedFileReaderIter ¶
func NewSizedFileReaderIter( filepath string, bufferSize int, ) (FileReaderIter, error)
NewSizedFileReaderIter creates a new buffered FileReaderIter
Click to show internal directories.
Click to hide internal directories.