Documentation
¶
Index ¶
Constants ¶
View Source
const DefaultScratchBufferSize = 64 * 1024
DefaultScratchBufferSize specifies the size of the scratch buffer that will be allocated by Walk
Variables ¶
View Source
var (
ErrNonDir = errors.New("walk: Cannot iterate non-directory")
)
Errors
Functions ¶
Types ¶
type Dirent ¶
type Dirent struct {
// contains filtered or unexported fields
}
Dirent stores a single directory entry (see getDirents)
type ErrorHandler ¶
ErrorHandler callback function
type Options ¶
type Options struct {
// Invoked before entering a (sub)directory.
Enter Visitor
// Invoked for every encountered directory entry.
Visit Visitor
// Invoked after leaving a (sub)directory.
Leave ErrorHandler
// Invoked on error.
Error ErrorHandler
// ScratchBuffer is an optional byte slice to use as a scratch buffer.
ScratchBuffer []byte
}
Options provide parameters for how the Walk function operates.
Click to show internal directories.
Click to hide internal directories.