Class AvailableValuesAttribute
- Namespace
- Exiled.API.Features.Attributes.Validators
- Assembly
- Exiled.API.dll
Checks if value is in list of available values.
[AttributeUsage(AttributeTargets.Property)]
public class AvailableValuesAttribute : Attribute, _Attribute, IValidator
- Inheritance
-
AvailableValuesAttribute
- Implements
- Inherited Members
- Extension Methods
Constructors
AvailableValuesAttribute(params object[])
Initializes a new instance of the AvailableValuesAttribute class.
public AvailableValuesAttribute(params object[] values)
Parameters
valuesobject[]
Properties
Values
Gets the array of possible values.
public object[] Values { get; }
Property Value
- object[]
Methods
Check(object)
Checks if other is satisfying this attributes condition.
public bool Check(object other)
Parameters
otherobjectValue to check.
Returns
- bool
Whether the value has passed check.