UnitRangeAttribute
StockSharp.Messages
Restricción de rango para valores de unidad.
Hereda de: RangeAttribute
Implementa: IValidator
Constructores
UnitRangeAttribute
public UnitRangeAttribute(Unit min, Unit max)
unitRangeAttribute = UnitRangeAttribute(min, max)
Inicia una nueva instancia de la UnitRangeAttribute.
- min
- Valor mínimo (inclusivo).
- max
- Valor máximo (inclusivo).
Propiedades
DisableNullCheck
public bool DisableNullCheck { get; set; }
value = unitRangeAttribute.DisableNullCheck
unitRangeAttribute.DisableNullCheck = value
Gets or sets a value indicating whether null checks should be disabled.
Métodos
IsValid
public override bool IsValid(object value)
result = unitRangeAttribute.IsValid(value)
Validates the specified value by converting it and applying the custom validation.
- value
- The value to validate.
Devuelve: True if the value is valid; otherwise, false.