Method Equals
Equals(FieldValue)
Returns a value indicating whether the value of this instance is
equal to the value of the specified FieldValue
instance.
Declaration
public override bool Equals(FieldValue other)
Parameters
Type | Name | Description |
---|---|---|
FieldValue | other | The value to compare with this instance for equality. |
Returns
Type | Description |
---|---|
Boolean | true if other is not
null and the value of this instance is equal to
other according to the defined rules,
otherwise false . |
Overrides
Remarks
The equality comparison semantics roughly follows the one
described in section Value Comparison Operators in the
SQL Reference Guide. All comparisons supported by
CompareTo(FieldValue) are also supported as equality
comparisons. In addition to these, the following comparisons are
also supported:
- An instance of BinaryValue is comparable with another instance of BinaryValue for equality. They are equal if their byte array values are the same length and are equal byte-per-byte.
- Singleton instance of NullValue is equal to itself and not equal to instance of any other type. Same goes for singleton instance of JsonNullValue.
- An instance of ArrayValue is comparable with another instance of ArrayValue for equality. They are equal if the two arrays are the same length and the elements of the two arrays are equal pair-wise, with equality of elements defined in recursive fashion.
- An instance of MapValue is comparable with another instance of MapValue for equality. They are equal if the two dictionaries have the same size and contain equal keys and values, that is for each key in the first dictionary there must exist the same key in the second map with the value equal to the corresponding value in the first map, with equality of the values defined in recursive fashion.
- An instance of RecordValue is comparable with another instance of RecordValue for equality. They are equal if the two ordered dictionaries have the same size and for each position their keys and values are equal pair-wise, with equality of values defined in recursive fashion.
false
.