NameHash

References
Contains information that is useful to uniquely identify an object name. This object is immutable.

Constructors

NameHash

#
protected NameHash(NameHash other)
Constructs a copy of a content hash.
other (NameHash)The other content hash to copy.

NameHash

#Since v6.0
public NameHash(string name, Guid parentId, bool ignoreCase)
Creates a new NameHash, representing a piece of text.
name (string)A name. This can be null and can refer to a non-existing path.
parentId (Guid)The id of the parent layer. This is only useful with layers.
ignoreCase (bool)All manifest searches currently ignore case, except for groups.
A new hash

NameHash

#Since v6.0
public NameHash(string name, Guid parentId, ModelComponentType type)
Creates a new NameHash, representing a piece of text.
name (string)A name. This can be null and can refer to a non-existing path.
parentId (Guid)The id of the parent layer. This is only useful with layers.
type (ModelComponentType)Calls ModelComponent.ModelComponentTypeIgnoresCase(ModelComponentType) to determine if case should be used in search.
A new hash

NameHash

#Since v6.0
public NameHash(string name, Guid parentId)
Creates a new NameHash, representing a piece of text.
name (string)A name. This can be null and can refer to a non-existing path.
parentId (Guid)The id of the parent layer. This is only useful with layers.
A new hash

NameHash

#Since v6.0
public NameHash(string name)
Creates a new NameHash, representing a piece of text.
name (string)A name. This can be null and can refer to a non-existing path.

Properties

MappedCodePoints

#Since v6.0
[CLSCompliant(false)] public uint MappedCodePoints { get; }
Gets the NameHash flags. In some cases = number of mapped code points.

ParentId

#Since v6.0
public Guid ParentId { get; }
Only useful if this participates in a tree structure, as with layers.

Sha1Hash

#Since v6.0
public byte[] Sha1Hash { get; }
Gets the 20-bytes long SHA-1 hash of ordinal minimum mapped Unicode (UTF-32) code points.

Methods

Clone

#Since v6.0
public NameHash Clone()
Creates a copy of this name hash. Because content hash is immutable, this can be used as a deep copy.
A different instance of the same name hash.

CreateFilePathHash

#Since v6.0
public static NameHash CreateFilePathHash(string path)
Creates a new NameHash, representing the name of a file.
path (string)A path. This can be null and can refer to a non-existing path.

Equals

#Since v6.0
public bool Equals(NameHash other)
Determines if another name hash has the same value.
other (NameHash)The other name hash to compare.
True if the two hashes are equal.

Equals

#
public override bool Equals(object obj)
Determines if another object is a name hash with same value.
obj (object)The other content hash to compare.
True if the two hashes are equal.
Object.Equals

GetHashCode

#
public override int GetHashCode()
Gets an hash code for this name hash. Two equal content hashes have equal hash code. The other way around might not be true.
An hash code value.
Explicit

ICloneable.Clone

#Since v6.0

Operators

OperationResultDescription
NameHash==NameHashboolDetermines if two NameHash instances are equal by value.
NameHash!=NameHashboolDetermines if two NameHash instances are different by value.