C# Class Summer.Batch.Common.IO.FileSystemResource

Implementation of T:IResource for a file in the file system.
Inheritance: Summer.Batch.Common.IO.AbstractResource
Datei anzeigen Open project: SummerBatch/SummerBatch Class Usage Examples

Public Methods

Method Description
CreateRelative ( string relativePath ) : IResource

Creates a new resource relative to this resource.

Exists ( ) : bool

Checks if a resource actually exists.

FileSystemResource ( FileInfo fileInfo ) : System

Constructs a new T:FileSystemResource for the given file info.

FileSystemResource ( string path ) : System

Constructs a new T:FileSystemResource for the given path.

GetDescription ( ) : string

Computes a literal description for this resource. Implementations are encouraged to return this value for their ToString() method.

GetFileInfo ( ) : FileInfo
GetFilename ( ) : string

Determines the filename for this resource.

GetFullPath ( ) : string

Returns the full path for this resource.

GetInputStream ( ) : Stream

Opens a new read T:System.IO.Stream for the underlying resource. Each call is expected to return a new instance.

GetLastModified ( ) : System.DateTime

Determines when this resource was last modified.

GetUri ( ) : Uri

Method Details

CreateRelative() public method

Creates a new resource relative to this resource.
public CreateRelative ( string relativePath ) : IResource
relativePath string a path relative to this resource
return IResource

Exists() public method

Checks if a resource actually exists.
public Exists ( ) : bool
return bool

FileSystemResource() public method

Constructs a new T:FileSystemResource for the given file info.
public FileSystemResource ( FileInfo fileInfo ) : System
fileInfo System.IO.FileInfo a file info
return System

FileSystemResource() public method

Constructs a new T:FileSystemResource for the given path.
public FileSystemResource ( string path ) : System
path string the path to the file to reference
return System

GetDescription() public method

Computes a literal description for this resource. Implementations are encouraged to return this value for their ToString() method.
public GetDescription ( ) : string
return string

GetFileInfo() public method

public GetFileInfo ( ) : FileInfo
return System.IO.FileInfo

GetFilename() public method

Determines the filename for this resource.
public GetFilename ( ) : string
return string

GetFullPath() public method

Returns the full path for this resource.
public GetFullPath ( ) : string
return string

GetInputStream() public method

Opens a new read T:System.IO.Stream for the underlying resource. Each call is expected to return a new instance.
if the stream cannot be open
public GetInputStream ( ) : Stream
return Stream

GetLastModified() public method

Determines when this resource was last modified.
if the resource cannot be resolved
public GetLastModified ( ) : System.DateTime
return System.DateTime

GetUri() public method

public GetUri ( ) : Uri
return System.Uri