コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="InMemoryFile"/> class.
 /// </summary>
 /// <param name="fileSystem">The file system this document belongs to</param>
 /// <param name="parent">The parent collection</param>
 /// <param name="path">The root-relative path of this document</param>
 /// <param name="name">The name of this document</param>
 /// <param name="data">The initial data of this document</param>
 public InMemoryFile(InMemoryFileSystem fileSystem, ICollection parent, Uri path, string name, byte[] data)
     : base(fileSystem, parent, path, name)
 {
     Data = new MemoryStream(data);
 }
コード例 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="InMemoryFile"/> class.
 /// </summary>
 /// <param name="fileSystem">The file system this document belongs to</param>
 /// <param name="parent">The parent collection</param>
 /// <param name="path">The root-relative path of this document</param>
 /// <param name="name">The name of this document</param>
 public InMemoryFile(InMemoryFileSystem fileSystem, ICollection parent, Uri path, string name)
     : this(fileSystem, parent, path, name, new byte[0])
 {
 }