ReadWriteFileSystemProvider.CreateFile Method
Namespace: Rebex.IO.FileSystem
Assembly: Rebex.FileSystem.dll (version 7.0.9147)
CreateFile(DirectoryNode, FileNode)
Override this method to implement File
When the virtual file system is used in the FileServer component, the server session, which contains information about the user and the active connection, can be accessed using Current property.
Declaration
protected abstract FileNode CreateFile(DirectoryNode parent, FileNode child)
Parameters
Type | Name | Description |
---|---|---|
Directory |
parent | Parent Directory |
File |
child | To be created File |
Returns
Type | Description |
---|---|
File |
An up-to-date instance of File |
Examples
protected override FileNode CreateFile(DirectoryNode parent, FileNode child)
{
var newFileFullPath = getFullPath(child.Path);
File.Create(newFileFullPath).Close();
return child;
}