public static FilePath CreateTempFile(string prefix, string suffix, FilePath directory) { string file; if (prefix == null) { throw new ArgumentNullException("prefix"); } if (prefix.Length < 3) { throw new ArgumentException("prefix must have at least 3 characters"); } string str = (directory == null) ? Path.GetTempPath() : directory.GetPath(); do { file = Path.Combine(str, prefix + Interlocked.Increment(ref _tempCounter) + suffix); } while (File.Exists(file)); new FileOutputStream(file).Close(); return(new FilePath(file)); }
public FileWriter (FilePath path) : base(path.GetPath ()) { }
public static FilePath CreateTempFile (string prefix, string suffix, FilePath directory) { string file; if (prefix == null) { throw new ArgumentNullException ("prefix"); } if (prefix.Length < 3) { throw new ArgumentException ("prefix must have at least 3 characters"); } string str = (directory == null) ? Path.GetTempPath () : directory.GetPath (); do { file = Path.Combine (str, prefix + Interlocked.Increment (ref _tempCounter) + suffix); } while (File.Exists (file)); new FileOutputStream (file).Close (); return new FilePath (file); }
public FileOutputStream(FilePath file, bool append) : this(file.GetPath(), append) { }
public FileOutputStream(FilePath file) : this(file.GetPath(), false) { }
public RandomAccessFile(FilePath file, string mode) : this(file.GetPath(), mode) { }
public RandomAccessFile (FilePath file, string mode) : this(file.GetPath (), mode) { }
public FileInputStream(FilePath file) : this(file.GetPath()) { }
public FileWriter(FilePath path) : base(path.GetPath()) { }
public FileInputStream (FilePath file) : this(file.GetPath ()) { }