TINMAN 3D / REALTIME TERRAIN
Software Development Kit - User Manual

class FileData in Tinman.Terrain.Util

abstract class FileData implements IFileData

Configuration

Config

The configurator object for this type.

public static property Config { get }
type IConfigurator<IFileData>
value [not-null] The configurator object.

Public / Attributes

IsPathInfoValid

Can the PathInfo value be used to access the file data in the local filesystem?

public abstract property IsPathInfoValid { get }
type bool
value true if the path info points to a valid file or directory in the local filesystem, false if it is some artificial or virtual value.
implements IFileData.IsPathInfoValid

PathInfo

Returns a Path object that represents the file path this object is associated with.

public abstract property PathInfo { get }
type Path
value [not-null] The path info.
implements IPathInfo.PathInfo

Remarks:

Objects that do not have a meaningful file path association simply return Unknown.

Public / Methods

Equals

Compares this object with the given one.

[Pure]
public abstract method Equals (IFileData other)
type bool
params other The object to compare to.
returns true if this object is equal to other, false if not.
implements IEquatable.Equals

For

Returns a IFileData object for the given file in the local file system.

public static method For (string path)
type IFileData
params path [not-null] The file path.
returns [not-null] The IFileData object.

Returns a IFileData object for the given file in the local file system.

public static method For (Path path)
type IFileData
params path [not-null] The file path.
returns [not-null] The IFileData object.

Returns a IFileData object for the given bytes.

public static method For (int8[] data)
type IFileData
params data [not-null] The file data.
returns [not-null] The IFileData object.

OpenStream

Opens a sequential data stream that returns the file data.

[OwnerReturn]
public abstract method OpenStream ()
type IDataStream
returns [not-null] The data stream. The CanSeek might return false.
implements IFileData.OpenStream

ToConfig

Returns the configuration value that describes this object.

public abstract method ToConfig ()
type ConfigValue
returns [not-null] The configuration value.
implements IConfigurable.ToConfig

Remarks:

All configurable objects need to implement this interface. For simple types, it is preferable to delegate to ToValue.

The returned value may be of type Invalid, which means that this object in its current state cannot be described with the configuration API.

Before returning the resulting configuration value, Cache must be called on it, passing this IConfigurable object as parameter.

Validate

Validates the state of this object.

public abstract method Validate (Validator validator)
params validator [not-null] The validator object.
implements IValidatable.Validate

Zip

Treats the file as an archive (the archive format is guessed from the file extension) and extracts the given entry.

public method Zip (string name)
type IFileData
params name The entry name; if null the first entry will be used.
returns [not-null] The resulting IFileData object.
implements IFileData.Zip