Tanoda
|
Conditionally disables a property based on the value of another property. The only condition types that are currently supported are bool types, and enum types. The property has two arguments names 'equalTo' and 'notEqualTo'. Exactly one of them must be specified, like so: More...
Public Member Functions | |
DisableIfBase (object isEqualTo, object isNotEqualTo, bool isAndOperation, bool nullIsValid, bool equalToComparison, params string[] propertyNames) | |
Public Attributes | |
readonly string[] | propertyNames |
readonly object | testValue |
readonly bool | disableResult |
readonly bool | isAndOperation |
readonly bool | nullIsValid |
readonly bool | equalToComparison |
Additional Inherited Members | |
![]() | |
FieldInfo? | fieldInfo [get, protected set] |
UnityObject[]? | targets [get, protected set] |
Conditionally disables a property based on the value of another property. The only condition types that are currently supported are bool types, and enum types. The property has two arguments names 'equalTo' and 'notEqualTo'. Exactly one of them must be specified, like so:
[DisableIf("myBoolProperty", isEqualTo: true)] [DisableIf("myEnumProperty", isNotEqualTo: MyEnum.Value)] [DisableIfAny("bool1", "bool2", isEqualTo: false)] [DisableIfAll("cond1", "cond2", "cond3", isNotEqualTo: true)]
Definition at line 27 of file DisableIf.cs.
Leap.Unity.Attributes.DisableIfBase.DisableIfBase | ( | object | isEqualTo, |
object | isNotEqualTo, | ||
bool | isAndOperation, | ||
bool | nullIsValid, | ||
bool | equalToComparison, | ||
params string[] | propertyNames | ||
) |
Definition at line 35 of file DisableIf.cs.
readonly bool Leap.Unity.Attributes.DisableIfBase.disableResult |
Definition at line 30 of file DisableIf.cs.
readonly bool Leap.Unity.Attributes.DisableIfBase.equalToComparison |
Definition at line 33 of file DisableIf.cs.
readonly bool Leap.Unity.Attributes.DisableIfBase.isAndOperation |
Definition at line 31 of file DisableIf.cs.
readonly bool Leap.Unity.Attributes.DisableIfBase.nullIsValid |
Definition at line 32 of file DisableIf.cs.
readonly string [] Leap.Unity.Attributes.DisableIfBase.propertyNames |
Definition at line 28 of file DisableIf.cs.
readonly object Leap.Unity.Attributes.DisableIfBase.testValue |
Definition at line 29 of file DisableIf.cs.