Casts an enum or int value in the inspector to specific enum type for rendering of its popup list. Supplying a method name rather than a type allows a property with the type Type to be used to dynamically get the enum type.
More...
Inherits DrawerPropertyAttribute.
|
| | DisplayAsEnumAttribute (string enumTypeMemberName) |
| | Initializes a new instance of the DisplayAsEnumAttribute class with the specified enum type member name.
|
| | DisplayAsEnumAttribute (Type enumType) |
| | Initializes a new instance of the DisplayAsEnumAttribute class with the specified enum type.
|
|
| PropertyAttribute (bool applyToCollection=false) |
|
|
Type | EnumType [get] |
| | Gets the type of the enum.
|
|
string | EnumTypeMemberName [get] |
| | Gets the name of the member that returns the enum type.
|
|
new bool | applyToCollection [get] |
|
|
| DrawerPropertyAttribute (bool applyToCollection=false) |
Casts an enum or int value in the inspector to specific enum type for rendering of its popup list. Supplying a method name rather than a type allows a property with the type Type to be used to dynamically get the enum type.
◆ DisplayAsEnumAttribute() [1/2]
| DisplayAsEnumAttribute |
( |
Type | enumType | ) |
|
Initializes a new instance of the DisplayAsEnumAttribute class with the specified enum type.
- Parameters
-
| enumType | The type of the enum. |
◆ DisplayAsEnumAttribute() [2/2]
| DisplayAsEnumAttribute |
( |
string | enumTypeMemberName | ) |
|
Initializes a new instance of the DisplayAsEnumAttribute class with the specified enum type member name.
- Parameters
-
| enumTypeMemberName | The name of the member that returns the enum type. |