Class Id
- Namespace
- Geotab.Checkmate.ObjectModel
- Assembly
- Geotab.Checkmate.ObjectModel.dll
This is an identifier for an Entity object in the Geotab system. In JavaScript this is a string.
public abstract class Id : IComparable<Id>
- Inheritance
-
Id
- Implements
- Derived
- Inherited Members
Constructors
Id()
protected Id()
Fields
Null
The instance of Null Id for internal usage.
public static readonly Id Null
Field Value
Methods
Clone()
Returns this instance.
public Id Clone()
Returns
CompareTo(Id?)
public virtual int CompareTo(Id? other)
Parameters
other
Id
Returns
Create(in Guid)
public static Id Create(in Guid value)
Parameters
Returns
Create(long)
public static Id Create(long value)
Parameters
Returns
Create(string)
public static Id? Create(string value)
Parameters
Returns
Equals(object?)
public override bool Equals(object? obj)
Parameters
obj
object
Returns
GetHashCode()
public override int GetHashCode()
Returns
GetValue()
Internal method that gets the boxed value of the underlying identifier.
public abstract object GetValue()
Returns
- object
value of the database identifier.
SerializeId(Utf8JsonWriter, bool)
An method used to write the json representation of the id to the provided Utf8JsonWriter.
public abstract void SerializeId(Utf8JsonWriter writer, bool asPropertyName = false)
Parameters
writer
Utf8JsonWriterThe Utf8JsonWriter to write the json representation of the id to.
asPropertyName
boolA bool indicating if the Id is to be a property name or a value. The default is value.
Operators
operator ==(Id?, Id?)
Operator == the specified entity. Allows the Id(s) to be compared as value types.
public static bool operator ==(Id? identifier1, Id? identifier2)
Parameters
Returns
- bool
True if equals; otherwise false.
operator >(Id, Id)
Implements the operator >.
public static bool operator >(Id id1, Id id2)
Parameters
Returns
- bool
The result of the operator.
operator >=(Id, Id)
Implements the operator >=.
public static bool operator >=(Id id1, Id id2)
Parameters
Returns
- bool
The result of the operator.
operator !=(Id?, Id?)
Operator != the specified entity. Allows the Id(s) to be compared as value types.
public static bool operator !=(Id? identifier1, Id? identifier2)
Parameters
Returns
- bool
True if not equal; otherwise false.
operator <(Id, Id)
Implements the operator <.
public static bool operator <(Id id1, Id id2)
Parameters
Returns
- bool
The result of the operator.
operator <=(Id, Id)
Implements the operator <=.
public static bool operator <=(Id id1, Id id2)
Parameters
Returns
- bool
The result of the operator.