Base interface for classes that provide data for files.
interface
|
IFileData
|
extends
|
IConfigurable
|
||
IEquatable<IFileData>
|
|||||
IPathInfo
|
|||||
IValidatable
|
|||||
base of
|
FileData
|
Can the PathInfo value be used to access the file data in the local filesystem?
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.
|
Returns a Path object that represents the file path this object is associated with.
property
|
PathInfo
{
get
}
|
||
type
|
Path
|
||
value
|
|
The path info. | |
inherited
|
IPathInfo.PathInfo
|
Remarks:
Objects that do not have a meaningful file path association simply return Unknown.
Opens a sequential data stream that returns the file data.
[OwnerReturn]
|
||||
method
|
OpenStream
()
|
|||
type
|
IDataStream
|
|||
returns
|
|
The
data
stream.
The
CanSeek
might
return
false .
|
Returns the configuration value that describes this object.
method
|
ToConfig
()
|
||
type
|
ConfigValue
|
||
returns
|
|
The configuration value. | |
inherited
|
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.
Validates the state of this object.
method
|
Validate
(Validator validator)
|
||
params
|
validator
|
[not-null]
|
The validator object. |
inherited
|
IValidatable.Validate
|
Treats the file as an archive (the archive format is guessed from the file extension) and extracts the given entry.
method
|
Zip
(string name = null)
|
||
type
|
IFileData
|
||
params
|
name
|
The
entry
name;
if
null
the
first
entry
will
be
used. |
|
returns
|
|
The resulting IFileData object. |