ArgValue.opEquals
Compares this value to another ArgValue for equality.
Two ArgValue instances are considered equal if and only if they are of the same underlying Type and their contained values are equal. For the NONE type, two values compare equal.
Parameters
rhs | The right-hand side ArgValue to compare with. |
Returns
bool opEquals(string rhs) const @safe pure nothrow @nogcCompares this ArgValue with a string for equality.
Equality returns true only when this value holds a STRING and the stored string equals rhs. For any other underlying type, the result is false.
Parameters
rhs | The string value to compare against. |
Returns
STRING with the same content as rhs.bool opEquals(bool rhs) const @safe pure nothrow @nogcCompares this ArgValue with a boolean for equality.
Equality returns true only when this value holds a BOOL and the stored boolean equals rhs. For any other underlying type, the result is false.
Parameters
rhs | The boolean value to compare against. |
Returns
BOOL equal to rhs.bool opEquals(int rhs) const @safe pure nothrow @nogcCompares this ArgValue with a 32-bit integer for equality.
Equality returns true only when this value holds a LONG and the stored integer (narrowed to 32-bit) equals rhs. For any other underlying type, the result is false.
Parameters
rhs | The 32-bit integer value to compare against. |
Returns
LONG whose value equals rhs after narrowing.bool opEquals(long rhs) const @safe pure nothrow @nogcCompares this ArgValue with a long integer for equality.
Equality returns true only when this value holds a LONG and the stored integer equals rhs. For any other underlying type, the result is false.
Parameters
rhs | The long value to compare against. |
Returns
LONG equal to rhs.bool opEquals(double rhs) const @safe pure nothrow @nogcCompares this ArgValue with a double for equality.
Equality returns true only when this value holds a DOUBLE and the stored floating point value equals rhs exactly.
Parameters
rhs | The double value to compare against. |
Returns
DOUBLE equal to rhs.bool opEquals(const(string[]) rhs) const @safe pure nothrow @nogcCompares this ArgValue with a list of strings for equality.
Equality returns true only when this value holds a LIST and the stored list equals rhs element-wise. For any other underlying type, the result is false.
Parameters
rhs | The list to compare against. |
Returns
LIST equal to rhs.