Documentation ¶
Index ¶
- Variables
- func FileSystem() http.FileSystem
- func Load(c *Chunk)
- func Walk(fn NodeWalker)
- type Chunk
- type File
- type Node
- func (n *Node) Child(name string) *Node
- func (n *Node) Ensure(name ...string) *Node
- func (n *Node) FileInfo() os.FileInfo
- func (n *Node) FileSystem() http.FileSystem
- func (n *Node) Find(name ...string) *Node
- func (n *Node) Load(c *Chunk)
- func (n *Node) Open(name string) (File, error)
- func (n *Node) ReadSeeker() io.ReadSeeker
- func (n *Node) SortedChildren() []*Node
- func (n *Node) Walk(fn NodeWalker)
- type NodeWalker
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultRoot = &Node{}
DefaultRoot the default root of BinFS
View Source
var ErrIsDirectory = errors.New("is a directory")
ErrIsDirectory error returned while trying read/seek a directory
Functions ¶
func FileSystem ¶
func FileSystem() http.FileSystem
FileSystem creates http.FileSystem implementation
Types ¶
type Node ¶
Node represents a internal node in file tree
func (*Node) FileSystem ¶
func (n *Node) FileSystem() http.FileSystem
FileSystem creates http.FileSystem implementation
func (*Node) ReadSeeker ¶
func (n *Node) ReadSeeker() io.ReadSeeker
ReadSeeker creates a related io.ReadSeeker
func (*Node) SortedChildren ¶
SortedChildren returns children sorted by name
Click to show internal directories.
Click to hide internal directories.