Class ComplexKey
Multi-element container that implements by-value comparison semantics and Hashcode caching; for use in Dictionary where you need an efficient, dynamic key. It only works if you consider it immutable and don't change the underlying objects!
Inherited Members
Namespace: SuperOffice.Util
Assembly: SoCore.dll
Syntax
public class ComplexKey
Constructors
ComplexKey(object[])
Create immutable instance with given values
Declaration
public ComplexKey(object[] keys)
Parameters
Type | Name | Description |
---|---|---|
object[] | keys |
Properties
Keys
The fields of the key
Declaration
public IEnumerable<object> Keys { get; }
Property Value
Type | Description |
---|---|
IEnumerable<object> |
Methods
Equals(object)
Override: By-value comparison semantics
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
object | obj |
Returns
Type | Description |
---|---|
bool |
Overrides
GetHashCode()
Override: return cached hashcode rather than recalculating all the time.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int |
Overrides
ToString()
Override for debugging
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string |