C# Class Mosa.FileSystem.VFS.NodeBase

Provides a default implementation for INodes. A file system implementation may choose to derive from BasicNode to receive a default implementation of the interface.
Inheritance: IVfsNode
ファイルを表示 Open project: tgiphil/MOSA-Project

Public Methods

Method Description
Create ( string name, VfsNodeType type, object settings ) : IVfsNode

Creates a new file system entry of the given name and type.

In theory every file system should support any VfsNodeType. Standard objects, such as directories and files are obvious. For other objects however, the file system is encouraged to store the passed settings in a specially marked file and treat these files as the appropriate node type. Instances of these objects can be retrieved using VfsObjectFactory.Create(settings). Access rights do not need to be checked by the node implementation. They have been already been checked by the VirtualFileSystem itself.

Delete ( IVfsNode child, DirectoryEntry entry ) : void

Deletes the specified child.

Lookup ( string name ) : IVfsNode

Requests the IVfsNode to perform a lookup on its children.

Open ( FileAccess access, FileShare sharing ) : object

Opens the specified access.

Protected Methods

Method Description
NodeBase ( IFileSystem fs, VfsNodeType type ) : System.IO

Initializes a new instance of the NodeBase class.

Method Details

Create() public abstract method

Creates a new file system entry of the given name and type.
In theory every file system should support any VfsNodeType. Standard objects, such as directories and files are obvious. For other objects however, the file system is encouraged to store the passed settings in a specially marked file and treat these files as the appropriate node type. Instances of these objects can be retrieved using VfsObjectFactory.Create(settings). Access rights do not need to be checked by the node implementation. They have been already been checked by the VirtualFileSystem itself.
The specified nodetype is not supported in the file system owning the node. See remarks about this.
public abstract Create ( string name, VfsNodeType type, object settings ) : IVfsNode
name string The name of the file system entry to create.
type VfsNodeType The type of the file system entry. See remarks.
settings object Potential settings for the file systeme entry.
return IVfsNode

Delete() public abstract method

Deletes the specified child.
public abstract Delete ( IVfsNode child, DirectoryEntry entry ) : void
child IVfsNode The child.
entry DirectoryEntry The entry.
return void

Lookup() public method

Requests the IVfsNode to perform a lookup on its children.
public Lookup ( string name ) : IVfsNode
name string The name of the item to find.
return IVfsNode

NodeBase() protected method

Initializes a new instance of the NodeBase class.
protected NodeBase ( IFileSystem fs, VfsNodeType type ) : System.IO
fs IFileSystem The fs.
type VfsNodeType The type.
return System.IO

Open() public abstract method

Opens the specified access.
public abstract Open ( FileAccess access, FileShare sharing ) : object
access FileAccess The access.
sharing FileShare The sharing.
return object