FileReference

References
public sealed class FileReference : IDisposable
Manages a reference to an existing or non-existing file, using either or both absolute or relative paths. Once constructed, this class is immutable.

Constructors

FileReference

#Since v6.0
public FileReference(string fullPath, string relativePath, ContentHash hash, FileReferenceStatus status)
Constructs a new instance of the FileReference class, given a fullPath, a relativePath a content hash and a status value.
fullPath (string)
relativePath (string)
hash (ContentHash)
status (FileReferenceStatus)

Finalizer

~FileReference

#
~FileReference()

Properties

ContentHash

#Since v6.0
public ContentHash ContentHash { get; }
Gets the content hash.

FullPath

#Since v6.0
public string FullPath { get; }
Gets the absolute path of this file reference.

FullPathStatus

#Since v6.0
public FileReferenceStatus FullPathStatus { get; }
Gets the file reference status.

IsSet

#Since v6.0
public bool IsSet { get; }
Returns an indication of the fact that the reference is actually set to a non-null value.

RelativePath

#Since v6.0
public string RelativePath { get; }
Gets the relative path of this file reference.

Methods

CreateFromFullAndRelativePaths

#Since v6.0
public static FileReference CreateFromFullAndRelativePaths(string fullPath, string relativePath)
Returns a new file reference. This returns a new instance even if the path does not exist.
fullPath (string)A full path. This parameter cannot be null.
relativePath (string)A relative path. This parameter can be null.
A file reference to the specified paths.

CreateFromFullPath

#Since v6.0
public static FileReference CreateFromFullPath(string fullPath)
Returns a new file reference. This returns a new instance even if the path does not exist.
fullPath (string)A full path.
A file reference to the specified path.

Dispose

#Since v6.0
public void Dispose()
Reclaims unmanaged resources used by this object.