Miner.Desktop.DesignerExpress Assembly > Miner.Desktop.DesignerExpress.Annotations Namespace : CannotApplyEqualityOperatorAttribute Class |
Equals()
should be used instead. However, using '==' or '!=' for comparison with null
is always permitted.'Declaration <AttributeUsageAttribute(ValidOn=AttributeTargets.Class Or _ AttributeTargets.Struct Or _ AttributeTargets.Interface, AllowMultiple=False, Inherited=True)> Public NotInheritable Class CannotApplyEqualityOperatorAttribute Inherits System.Attribute
'Usage Dim instance As CannotApplyEqualityOperatorAttribute
[AttributeUsage(ValidOn=AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Interface, AllowMultiple=false, Inherited=true)] public sealed class CannotApplyEqualityOperatorAttribute : System.Attribute
[CannotApplyEqualityOperator] class NoEquality { } class UsesNoEquality { public void Test() { var ca1 = new NoEquality(); var ca2 = new NoEquality(); if (ca1 != null) { // OK bool condition = ca1 == ca2; // Warning } } }
System.Object
System.Attribute
Miner.Desktop.DesignerExpress.Annotations.CannotApplyEqualityOperatorAttribute
Target Platforms: Windows XP SP3 (32-bit and 64-bit), Windows 7 (32-bit and 64-bit)
Not all Operating Systems are supported on all products. Visit the ArcFM Solution Supported Versions page for full details.