EnumArgumentAttribute Class

Summary

This attribute can be applied to enum-properties in option classes, to specify the arguments to pass to the executable in case of each possible enum value for the property. Note that usage of any enum values that don't have a corresponding EnumArgumentAttribute will be ignored.
Assembly
Mercurial.Net.dll
Namespace
Mercurial.Attributes
Interfaces
  • _Attribute
Base Types
graph TD Base0["ArgumentAttribute"]-->Type click Base0 "/Cake.Hg/api/Mercurial.Attributes/ArgumentAttribute" Base1["Attribute"]-->Base0 Base2["object"]-->Base1 Interface0["_Attribute"]-.->Type Type["EnumArgumentAttribute"] class Type type-node

Syntax

public sealed class EnumArgumentAttribute : ArgumentAttribute, _Attribute

Attributes

Type Description
AttributeUsageAttribute

Constructors

Name Summary
EnumArgumentAttribute(object, string) Initializes a new instance of the EnumArgumentAttribute class with one argument for the enum value.
EnumArgumentAttribute(object, string, string) Initializes a new instance of the EnumArgumentAttribute class with two arguments for the enum value.

Properties

Name Value Summary
Argument1 string
Gets the first argument that the Value is mapped to, or System.String.Empty if there is no argument.
Argument2 string
Gets the second argument that the Value is mapped to, or System.String.Empty if there is no second argument.
IsBitmask bool
Gets or sets a value indicating whether the enum value is a bitmask value (see System.FlagsAttribute) or not.
Value object
Gets the enum value to map the arguments to.

Methods

Name Value Summary
GetOptions(object) string[]
Gets a collection of options or arguments to pass to the Mercurial executable, based on the property value from the command class.