CannotApplyEqualityOperatorAttribute Class |
Indicates that the value of the marked type (or its derivatives)
cannot be compared using '==' or '!=' operators and Equals()
should be used instead. However, using '==' or '!=' for comparison
with null is always permitted.
Inheritance Hierarchy
Namespace: Ozeki.CommonAssembly: OzekiSDK (in OzekiSDK.dll) Version: 1.8.12.0 (1.8.12)
Syntax public sealed class CannotApplyEqualityOperatorAttribute : Attribute
Public NotInheritable Class CannotApplyEqualityOperatorAttribute
Inherits Attribute
public ref class CannotApplyEqualityOperatorAttribute sealed : public Attribute
[<SealedAttribute>]
type CannotApplyEqualityOperatorAttribute =
class
inherit Attribute
end
The CannotApplyEqualityOperatorAttribute type exposes the following members.
Constructors Examples [CannotApplyEqualityOperator]
class NoEquality { }
class UsesNoEquality {
public void Test() {
var ca1 = new NoEquality();
var ca2 = new NoEquality();
if (ca1 != null) {
bool condition = ca1 == ca2;
}
}
}
See Also