Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func TypeByExtension ¶
TypeByExtension returns the type of a file according to its extension. A complete path can be provided, or just the extension with or without dot.
Types ¶
type FileEntry ¶
type FileEntry struct { Name string Size int64 Content []byte Template *ogdl.Graph Data *ogdl.Graph Info *ogdl.Graph Type string IsDirectory bool // This is for the original path, not the index.* Mime string Time time.Time Param map[string]string Mode os.FileMode Dir []os.FileInfo Doc *document.Document }
FileEntry type TODO: interface extension of os.FileInfo?
type FileInfo interface { Name() string // base name of the file Size() int64 // length in bytes for regular files; system-dependent for others Mode() FileMode // file mode bits ModTime() time.Time // modification time IsDir() bool // abbreviation for Mode().IsDir() Sys() interface{} // underlying data source (can return nil) }
Click to show internal directories.
Click to hide internal directories.