Class
caplin.core.validator

MapConfigValueValidator

Implements caplin.core.Validator.

Constructor Summary

Attributes Name and Description
caplin.core.validator.MapConfigValueValidator(object config)

The MapConfigValueValidator is a caplin.trading.validation.Validator that ensures the value being validated conforms to the given configuration.

Method Summary

Attributes Name and Description
void validate(Object value, Object attributes, caplin.core.ValidationResult validationResult)

Determine whether the given value conforms to any required type, minimum, value, etc and set result on the provided caplin.core.ValidationResult.

Constructor Detail

caplin.core.validator.MapConfigValueValidator(object config)

The MapConfigValueValidator is a caplin.trading.validation.Validator that ensures the value being validated conforms to the given configuration.

Parameters
object config configuration object specifying the allowed/required keys and values in a map. The validity of the config object is checked by the utility method caplin.core.validator.MapConfigUtility.checkConfig.

Method Detail

void validate(Object value, Object attributes, caplin.core.ValidationResult validationResult)

Determine whether the given value conforms to any required type, minimum, value, etc and set result on the provided caplin.core.ValidationResult.

Parameters
Object value The value to validate.
Object attributes attributes to control the validation process.
caplin.core.ValidationResult validationResult the ValidationResult in which to store the result of this validation.