9fans.net/go@v0.0.5/plan9/client/fsys_plan9.go (about)

     1  package client
     2  
     3  import (
     4  	"os"
     5  	"path/filepath"
     6  
     7  	"9fans.net/go/plan9"
     8  )
     9  
    10  type Fsys struct {
    11  	Mtpt string
    12  }
    13  
    14  func (c *Conn) Attach(afid *Fid, user, aname string) (*Fsys, error) {
    15  	panic("unimplemented")
    16  }
    17  
    18  func (fs *Fsys) Access(name string, mode int) error {
    19  	panic("unimplemented")
    20  }
    21  
    22  func (fs *Fsys) Create(name string, mode uint8, perm plan9.Perm) (*Fid, error) {
    23  	panic("unimplemented")
    24  }
    25  
    26  func (fs *Fsys) Open(name string, mode uint8) (*Fid, error) {
    27  	f, err := os.OpenFile(filepath.Join(fs.Mtpt, name), int(mode), 0)
    28  	return &Fid{File: f}, err
    29  }
    30  
    31  func (fs *Fsys) Remove(name string) error {
    32  	panic("unimplemented")
    33  }
    34  
    35  func (fs *Fsys) Stat(name string) (*plan9.Dir, error) {
    36  	panic("unimplemented")
    37  }
    38  
    39  func (fs *Fsys) Wstat(name string, d *plan9.Dir) error {
    40  	panic("unimplemented")
    41  }