Documentation ¶
Index ¶
- func IsDir(filePath string) bool
- func IsFile(filePath string) bool
- type File
- type FileLocation
- type FileSystem
- type LocalFileSystem
- func (l *LocalFileSystem) Accept(loc *FileLocation) bool
- func (l *LocalFileSystem) IsDir(loc *FileLocation) bool
- func (l *LocalFileSystem) IsFile(loc *FileLocation) bool
- func (l *LocalFileSystem) List(loc *FileLocation) ([]*FileLocation, error)
- func (l *LocalFileSystem) Open(loc *FileLocation) (File, error)
- type MemoryFileSystem
- func (l *MemoryFileSystem) Accept(loc *FileLocation) bool
- func (l *MemoryFileSystem) IsDir(loc *FileLocation) bool
- func (l *MemoryFileSystem) IsFile(loc *FileLocation) bool
- func (l *MemoryFileSystem) List(loc *FileLocation) ([]*FileLocation, error)
- func (l *MemoryFileSystem) Open(loc *FileLocation) (File, error)
- type S3FileSystem
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type File ¶
type File interface { io.ReadCloser }
type FileLocation ¶
type FileLocation struct {
Path string
}
func List ¶
func List(filePath string) ([]*FileLocation, error)
func NewFileLocation ¶
func NewFileLocation(filePath string) *FileLocation
type FileSystem ¶
type FileSystem interface { Accept(*FileLocation) bool Open(*FileLocation) (File, error) List(*FileLocation) ([]*FileLocation, error) IsFile(*FileLocation) bool IsDir(*FileLocation) bool }
type LocalFileSystem ¶
type LocalFileSystem struct { }
func NewLocalFileSystem ¶
func NewLocalFileSystem() *LocalFileSystem
func (*LocalFileSystem) Accept ¶
func (l *LocalFileSystem) Accept(loc *FileLocation) bool
func (*LocalFileSystem) IsDir ¶
func (l *LocalFileSystem) IsDir(loc *FileLocation) bool
func (*LocalFileSystem) IsFile ¶
func (l *LocalFileSystem) IsFile(loc *FileLocation) bool
func (*LocalFileSystem) List ¶
func (l *LocalFileSystem) List(loc *FileLocation) ([]*FileLocation, error)
func (*LocalFileSystem) Open ¶
func (l *LocalFileSystem) Open(loc *FileLocation) (File, error)
type MemoryFileSystem ¶
func NewMemoryFileSystem ¶
func NewMemoryFileSystem() *MemoryFileSystem
func (*MemoryFileSystem) Accept ¶
func (l *MemoryFileSystem) Accept(loc *FileLocation) bool
func (*MemoryFileSystem) IsDir ¶
func (l *MemoryFileSystem) IsDir(loc *FileLocation) bool
func (*MemoryFileSystem) IsFile ¶
func (l *MemoryFileSystem) IsFile(loc *FileLocation) bool
func (*MemoryFileSystem) List ¶
func (l *MemoryFileSystem) List(loc *FileLocation) ([]*FileLocation, error)
func (*MemoryFileSystem) Open ¶
func (l *MemoryFileSystem) Open(loc *FileLocation) (File, error)
type S3FileSystem ¶
type S3FileSystem struct {
// contains filtered or unexported fields
}
func NewS3FileSystem ¶
func NewS3FileSystem() *S3FileSystem
func (*S3FileSystem) Accept ¶
func (l *S3FileSystem) Accept(loc *FileLocation) bool
func (*S3FileSystem) IsDir ¶
func (l *S3FileSystem) IsDir(loc *FileLocation) bool
func (*S3FileSystem) IsFile ¶
func (l *S3FileSystem) IsFile(loc *FileLocation) bool
func (*S3FileSystem) List ¶
func (l *S3FileSystem) List(loc *FileLocation) ([]*FileLocation, error)
func (*S3FileSystem) Open ¶
func (l *S3FileSystem) Open(loc *FileLocation) (File, error)
Click to show internal directories.
Click to hide internal directories.