Class EnumerationMetadataAttribute
Associates enumeration field description information with a target element. This class cannot be inherited.
Inheritance
Implements
Inherited Members
Namespace: Argotic.Common
Assembly: Argotic.Common.dll
Syntax
[AttributeUsage(AttributeTargets.Field, Inherited = false, AllowMultiple = false)]
[Serializable]
public sealed class EnumerationMetadataAttribute : Attribute, IComparable
Constructors
| Improve this Doc View SourceEnumerationMetadataAttribute()
Initializes a new instance of the EnumerationMetadataAttribute class.
Declaration
public EnumerationMetadataAttribute()
Properties
| Improve this Doc View SourceAlternateValue
Gets or sets the alternate textual value for the attributed field.
Declaration
public string AlternateValue { get; set; }
Property Value
Type | Description |
---|---|
System.String | The alternate textual value for the attributed field. |
DisplayName
Gets or sets the display name for the attributed field.
Declaration
public string DisplayName { get; set; }
Property Value
Type | Description |
---|---|
System.String | The display name for the attributed field. |
Methods
| Improve this Doc View SourceCompareTo(Object)
Compares the current instance with another object of the same type.
Declaration
public int CompareTo(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | An object to compare with this instance. |
Returns
Type | Description |
---|---|
System.Int32 | A 32-bit signed integer that indicates the relative order of the objects being compared. |
Exceptions
Type | Condition |
---|---|
System.ArgumentException | The |
Equals(Object)
Determines whether the specified System.Object is equal to the current instance.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | The System.Object to compare with the current instance. |
Returns
Type | Description |
---|---|
System.Boolean | true if the specified System.Object is equal to the current instance; otherwise, false. |
Overrides
GetHashCode()
Returns a hash code for the current instance.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | A 32-bit signed integer hash code. |
Overrides
ToString()
Returns a System.String that represents the current EnumerationMetadataAttribute.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | A System.String that represents the current EnumerationMetadataAttribute. |
Overrides
Remarks
This method returns a human-readable string for the current instance.
Operators
| Improve this Doc View SourceEquality(EnumerationMetadataAttribute, EnumerationMetadataAttribute)
Determines if operands are equal.
Declaration
public static bool operator ==(EnumerationMetadataAttribute first, EnumerationMetadataAttribute second)
Parameters
Type | Name | Description |
---|---|---|
EnumerationMetadataAttribute | first | Operand to be compared. |
EnumerationMetadataAttribute | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | true if the values of its operands are equal, otherwise; false. |
GreaterThan(EnumerationMetadataAttribute, EnumerationMetadataAttribute)
Determines if first operand is greater than second operand.
Declaration
public static bool operator>(EnumerationMetadataAttribute first, EnumerationMetadataAttribute second)
Parameters
Type | Name | Description |
---|---|---|
EnumerationMetadataAttribute | first | Operand to be compared. |
EnumerationMetadataAttribute | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | true if the first operand is greater than the second, otherwise; false. |
Inequality(EnumerationMetadataAttribute, EnumerationMetadataAttribute)
Determines if operands are not equal.
Declaration
public static bool operator !=(EnumerationMetadataAttribute first, EnumerationMetadataAttribute second)
Parameters
Type | Name | Description |
---|---|---|
EnumerationMetadataAttribute | first | Operand to be compared. |
EnumerationMetadataAttribute | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | false if its operands are equal, otherwise; true. |
LessThan(EnumerationMetadataAttribute, EnumerationMetadataAttribute)
Determines if first operand is less than second operand.
Declaration
public static bool operator <(EnumerationMetadataAttribute first, EnumerationMetadataAttribute second)
Parameters
Type | Name | Description |
---|---|---|
EnumerationMetadataAttribute | first | Operand to be compared. |
EnumerationMetadataAttribute | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | true if the first operand is less than the second, otherwise; false. |