diff --git a/fs.go b/fs.go index b1f1283..380b3ef 100644 --- a/fs.go +++ b/fs.go @@ -39,13 +39,14 @@ type File interface { io.Seeker io.Writer io.WriterAt - //Fd() uintptr - Stat() (os.FileInfo, error) + + Name() string Readdir(count int) ([]os.FileInfo, error) Readdirnames(n int) ([]string, error) - WriteString(s string) (ret int, err error) + Stat() (os.FileInfo, error) + Sync() error Truncate(size int64) error - Name() string + WriteString(s string) (ret int, err error) } // Fs is the filesystem interface. diff --git a/memfile.go b/memfile.go index 90a5ae0..6be5c87 100644 --- a/memfile.go +++ b/memfile.go @@ -74,6 +74,10 @@ func (f *InMemoryFile) Stat() (os.FileInfo, error) { return &InMemoryFileInfo{f}, nil } +func (f *InMemoryFile) Sync() error { + return nil +} + func (f *InMemoryFile) Readdir(count int) (res []os.FileInfo, err error) { var outLength int64