EnumItemAttribute Class

Assembly: CodeEffects.Rule.Common.dll
Namespace: CodeEffects.Rule.Common.Attributes

Summary

When applied to a member of an enumeration that is used by a source object as a rule field, this attribute specifies the display name for that member.

Syntax

[AttributeUsage(AttributeTargets.Field, AllowMultiple = false, Inherited = false)]
public class EnumItemAttribute : System.Attribute,
	CodeEffects.Rule.Common.Attributes.IDisplayableAttribute

Properties

  • DisplayName
    Type: System.String

    Gets or sets the display name of the enumeration member in the Rule Editor.

Example

using CodeEffects.Rule.Common.Attributes;

public enum State
{
	[ExcludeFromEvaluation]
	Undefined,

	Arizona,
	California,
	Florida,
	Georgia,

	[EnumItem("North Dakota")]
	NorthDakota,

	[EnumItem("South Carolina")]
	SouthCarolina
}

p101

l097 --

l102

p101

×