Class ConditionAttribute
Attribute to specify conditions for a field or property.
NOTE: Use this to create your own custom conditions.
[AttributeUsage(AttributeTargets.Property|AttributeTargets.Field, Inherited = true, AllowMultiple = false)]
public class ConditionAttribute : Attribute
- Inheritance
-
ConditionAttribute
- Derived
Methods
EvaluateActive(object)
Override this method to calculate if the field is active or not.
public virtual bool EvaluateActive(object target)
Parameters
target
objectThe object to evaluate the condition for.
Returns
- bool
True if the field is active; otherwise false.
EvaluateReadOnly(object)
Override this method to calculate if the field is read only or not.
public virtual bool EvaluateReadOnly(object target)
Parameters
target
objectThe object to evaluate the condition for.
Returns
- bool
True if the field is read only; otherwise false.