示例#1
0
 public Entry(@string name = default, long mtime = default, long uid = default, long gid = default, os.FileMode mode = default, long size = default)
 {
     this.name  = name;
     this.mtime = mtime;
     this.uid   = uid;
     this.gid   = gid;
     this.mode  = mode;
     this.size  = size;
 }
示例#2
0
 private static (ptr <os.File>, error) openFile(@string name, long flag, os.FileMode perm)
 {
     ptr <os.File> _p0 = default !;
示例#3
0
 public pathMode(@string path = default, os.FileMode mode = default)
 {
     this.path = path;
     this.mode = mode;
 }
示例#4
0
 // OpenFile is like os.OpenFile, but returns a locked file.
 // If flag includes os.O_WRONLY or os.O_RDWR, the file is write-locked;
 // otherwise, it is read-locked.
 public static (ptr <File>, error) OpenFile(@string name, long flag, os.FileMode perm) => func((_, panic, __) =>
示例#5
0
文件: renameio.cs 项目: zjmit/go2cs
 // WriteFile is like ioutil.WriteFile, but first writes data to an arbitrary
 // file in the same directory as filename, then renames it atomically to the
 // final name.
 //
 // That ensures that the final location, if it exists, is always a complete file.
 public static error WriteFile(@string filename, slice <byte> data, os.FileMode perm)
 {
     error err = default !;