Documentation
¶
Index ¶
- type AssetCompilerInterface
- type AssetGetterInterface
- type AssetInterface
- type AssetReaderFunc
- type AssetReaderFuncC
- type BasicFileInfo
- func NewBasicFileInfo(pth string, size int64, mode os.FileMode, modTime, changeTime time.Time) BasicFileInfo
- func NewCleanedBasicFileInfo(pth string, name ...string) BasicFileInfo
- func OsFileInfoToBasic(pth string, info os.FileInfo) BasicFileInfo
- func SetBasicFileInfoPath(b BasicFileInfo, path string) BasicFileInfo
- type BasicFileInfoWithChangedTime
- type CbWalkFunc
- type CbWalkInfoFunc
- type Compresseder
- type DirFileInfo
- type FileInfo
- type FileType
- type GetAssetInfoFunc
- type GetAssetInfoFuncC
- type Glob
- type GlobError
- type GlobFunc
- type GlobInfoFunc
- type GlobPattern
- type HttpFileSystem
- type Interface
- type LocalSource
- type LocalSourceInfo
- type LocalSourceRegister
- type LocalSourcesAttribute
- type LocalSourcesGetter
- type NameSpacedInterface
- type PathFormatterFunc
- type PathRegisterCallback
- type PathRegistrator
- type Plugin
- type RFileInfo
- type RawReadGetter
- type TraversableInterface
- type WalkFunc
- type WalkInfoFunc
- type WalkMode
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AssetCompilerInterface ¶
type AssetCompilerInterface interface {
Compile() error
}
type AssetGetterInterface ¶
type AssetGetterInterface interface { Asset(path string) (AssetInterface, error) AssetC(ctx context.Context, path string) (asset AssetInterface, err error) MustAsset(path string) AssetInterface MustAssetC(ctx context.Context, path string) AssetInterface AssetInfo(path string) (FileInfo, error) AssetInfoC(ctx context.Context, path string) (FileInfo, error) MustAssetInfo(path string) FileInfo MustAssetInfoC(ctx context.Context, path string) FileInfo AssetReader() AssetReaderFunc AssetReaderC() AssetReaderFuncC Provider(providers ...Interface) Providers() []Interface }
type AssetInterface ¶
type AssetInterface interface { Name() string Path() string Reader() (io.ReadCloser, error) }
type AssetReaderFunc ¶
type AssetReaderFuncC ¶
type BasicFileInfo ¶
func NewBasicFileInfo ¶
func NewCleanedBasicFileInfo ¶
func NewCleanedBasicFileInfo(pth string, name ...string) BasicFileInfo
func OsFileInfoToBasic ¶
func OsFileInfoToBasic(pth string, info os.FileInfo) BasicFileInfo
func SetBasicFileInfoPath ¶
func SetBasicFileInfoPath(b BasicFileInfo, path string) BasicFileInfo
type BasicFileInfoWithChangedTime ¶
type BasicFileInfoWithChangedTime interface { BasicFileInfo ChangeTime() time.Time }
type CbWalkFunc ¶
type CbWalkInfoFunc ¶
type Compresseder ¶
type Compresseder interface {
Compressed() bool
}
type DirFileInfo ¶
type GetAssetInfoFunc ¶
type GetAssetInfoFuncC ¶
type Glob ¶
type Glob interface { GetPattern() GlobPattern SetPattern(pattern GlobPattern) FS() Interface Name(cb func(pth string, isDir bool) error) error NameOrPanic(cb func(pth string, isDir bool) error) Names() ([]string, error) SortedNames() ([]string, error) NamesOrPanic() []string Info(cb func(info FileInfo) error) error Infos() ([]FileInfo, error) SortedInfos() (items []FileInfo, err error) InfoOrPanic(cb func(info FileInfo) error) InfosOrPanic() []FileInfo }
type GlobFunc ¶
type GlobFunc = func(pattern GlobPattern, cb func(pth string, isDir bool) error) error
type GlobInfoFunc ¶
type GlobInfoFunc = func(pattern GlobPattern, cb func(info FileInfo) error) error
type GlobPattern ¶
type GlobPattern interface { Dir() string Pattern() string IsRecursive() bool AllowDirs() bool AllowFiles() bool Recursive() GlobPattern Match(value string) bool Wrap(dir ...string) GlobPattern GetPathFormatter() PathFormatterFunc PathFormatter(formatter PathFormatterFunc) GlobPattern }
type HttpFileSystem ¶
func NewHttpFileSystem ¶
func NewHttpFileSystem(fs Interface) *HttpFileSystem
type Interface ¶
type Interface interface { AssetGetterInterface AssetCompilerInterface TraversableInterface LocalSourcesAttribute http.Handler GetNameSpace(nameSpace string) (NameSpacedInterface, error) NameSpaces() []NameSpacedInterface NameSpace(nameSpace string) NameSpacedInterface GetPath() string GetParent() Interface RegisterPlugin(plugins ...Plugin) DumpFiles(cb func(info FileInfo) error) error Dump(cb func(info FileInfo) error, ignore ...func(pth string) bool) error }
type LocalSource ¶
type LocalSource interface { Dir() string Get(name string) (info LocalSourceInfo, err error) }
type LocalSourceInfo ¶
type LocalSourceRegister ¶
type LocalSourceRegister interface { Register(name string, src LocalSource) Get(name string) (src LocalSource) }
type LocalSourcesAttribute ¶
type LocalSourcesAttribute interface { LocalSourcesGetter SetLocalSources(sources LocalSourceRegister) }
type LocalSourcesGetter ¶
type LocalSourcesGetter interface {
LocalSources() LocalSourceRegister
}
type NameSpacedInterface ¶
type PathFormatterFunc ¶
type PathFormatterFunc = func(pth *string)
type PathRegisterCallback ¶
type PathRegisterCallback = func(fs Interface)
type PathRegistrator ¶
type RFileInfo ¶
type RFileInfo interface { BasicFileInfo RealPath() string }
type RawReadGetter ¶
type RawReadGetter interface {
RawReader() io.ReadCloser
}
type TraversableInterface ¶
type TraversableInterface interface { Walk(dir string, cb CbWalkFunc, mode ...WalkMode) error WalkInfo(dir string, cb CbWalkInfoFunc, mode ...WalkMode) error ReadDir(dir string, cb CbWalkInfoFunc, skipDir bool) (err error) Glob(pattern GlobPattern, cb func(pth string, isDir bool) error) error GlobInfo(pattern GlobPattern, cb func(info FileInfo) error) error NewGlob(pattern GlobPattern) Glob NewGlobString(pattern string) Glob }
type WalkInfoFunc ¶
type WalkInfoFunc = func(path string, cb CbWalkInfoFunc, mode WalkMode) error
type WalkMode ¶
type WalkMode int
const ( WalkDirs WalkMode = 1 << iota WalkFiles WalkNameSpaces WalkNameSpacesLookUp WalkParentLookUp WalkReverse WalkAll = WalkFiles | WalkDirs | WalkNameSpaces | WalkNameSpacesLookUp | WalkParentLookUp )
func (WalkMode) IsNameSpaces ¶
func (WalkMode) IsNameSpacesLookUp ¶
func (WalkMode) IsParentLookUp ¶
Click to show internal directories.
Click to hide internal directories.