Documentation ¶
Index ¶
- func MakeFakeDirFileInfo(name string) os.FileInfo
- func ReadSeekerToReaderAt(rs io.ReadSeeker) io.ReaderAt
- func WrapReaderWithCloser(rsc vfs.ReadSeekCloser, closer io.Closer) vfs.ReadSeekCloser
- type FSCloser
- type FakeDirFileInfo
- type ReadSeekerAt
- type ZipOpenFS
- func (fs *ZipOpenFS) Close() error
- func (fs *ZipOpenFS) Lstat(p string) (os.FileInfo, error)
- func (fs *ZipOpenFS) Open(p string) (vfs.ReadSeekCloser, error)
- func (fs *ZipOpenFS) ReadDir(p string) ([]os.FileInfo, error)
- func (fs *ZipOpenFS) Stat(p string) (os.FileInfo, error)
- func (fs *ZipOpenFS) String() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MakeFakeDirFileInfo ¶
func ReadSeekerToReaderAt ¶
func ReadSeekerToReaderAt(rs io.ReadSeeker) io.ReaderAt
ReadSeekerToReaderAt takes a io.ReadSeeker and returns a new io.ReaderAt that will be a proxy for the ReadSeeker. Note that this new ReaderAt is not as powerful, because it does not allow ReadAt calls to be run in parallel (they lock while waiting)
func WrapReaderWithCloser ¶
func WrapReaderWithCloser(rsc vfs.ReadSeekCloser, closer io.Closer) vfs.ReadSeekCloser
Types ¶
type FSCloser ¶
type FSCloser interface { vfs.FileSystem io.Closer }
func NewZipOpeningFS ¶
func NewZipOpeningFS(fs vfs.FileSystem) FSCloser
type FakeDirFileInfo ¶
type FakeDirFileInfo struct {
// contains filtered or unexported fields
}
FakeDirFileInfo is just a os.FileInfo that has nothing but a name and says it's a directory
func (FakeDirFileInfo) IsDir ¶
func (i FakeDirFileInfo) IsDir() bool
func (FakeDirFileInfo) ModTime ¶
func (i FakeDirFileInfo) ModTime() time.Time
func (FakeDirFileInfo) Mode ¶
func (i FakeDirFileInfo) Mode() os.FileMode
func (FakeDirFileInfo) Name ¶
func (i FakeDirFileInfo) Name() string
func (FakeDirFileInfo) Size ¶
func (i FakeDirFileInfo) Size() int64
func (FakeDirFileInfo) Sys ¶
func (i FakeDirFileInfo) Sys() interface{}
type ReadSeekerAt ¶
type ReadSeekerAt struct {
// contains filtered or unexported fields
}
ReadSeekerAt is a simple wrapper around a ReadSeeker to make it a ReaderAt. Note that using this canibalizes the seeking behavior of the underlying io.ReadSeeker, so it should not be used again
Click to show internal directories.
Click to hide internal directories.