public static class ExecutionControls.ControlsOptionValidator extends TypeValidators.TypeValidator
ExecConstants.DRILLBIT_CONTROL_INJECTIONS
option is validated using this class. Controls are short-lived options.OptionValidator.OptionDescription| Constructor and Description |
|---|
ControlsOptionValidator(String name,
int ttl,
OptionValidator.OptionDescription description)
Constructor for controls option validator.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getTtl()
If an option is short-lived, this method returns the number of queries for which the option is valid.
|
boolean |
isShortLived()
This function returns true if and only if this validator is meant for a short-lived option.
|
void |
validate(OptionValue v,
OptionMetaData metaData,
OptionSet manager)
Validates the option value.
|
getConfigProperty, getKindgetOptionDescription, getOptionNamepublic ControlsOptionValidator(String name, int ttl, OptionValidator.OptionDescription description)
name - the name of the validatorttl - the number of queries for which this option should be validdescription - Description of the optionpublic int getTtl()
OptionValidatorOptionValidator.isShortLived()getTtl in class OptionValidatorpublic boolean isShortLived()
OptionValidatorOptionValidator.getTtl().
E.g. ExecutionControls.ControlsOptionValidatorisShortLived in class OptionValidatorpublic void validate(OptionValue v, OptionMetaData metaData, OptionSet manager)
OptionValidatorvalidate in class TypeValidators.TypeValidatorv - the value to validatemanager - the manager for accessing validation dependencies (options)Copyright © 2022 The Apache Software Foundation. All rights reserved.