T - Value typeC - Concrete input typepublic interface ValidatableInputBuilder<T,C extends ValidatableInput<T>>
ValidatableInput builder.| Modifier and Type | Method and Description |
|---|---|
C |
build()
Build the
ValidatableInput instance. |
static <T> ValidatableInputBuilder<T,ValidatableInput<T>> |
create(Input<T> input)
Get a builder to create and setup a
ValidatableInput from given Input. |
ValidatableInputBuilder<T,C> |
required()
Sets the
Input as required. |
ValidatableInputBuilder<T,C> |
required(com.holonplatform.core.i18n.Localizable message)
Sets the
Input as required, using given message as validation error message. |
default ValidatableInputBuilder<T,C> |
required(String message)
Sets the
Input as required, using given message as validation error message. |
default ValidatableInputBuilder<T,C> |
required(String message,
String messageCode,
Object... arguments)
Sets the
Input as required, using given message as validation error message. |
ValidatableInputBuilder<T,C> |
required(com.holonplatform.core.Validator<T> validator)
Set the
Input as required, using given Validator to check the input value. |
ValidatableInputBuilder<T,C> |
validateOnValueChange(boolean validateOnValueChange)
|
ValidatableInputBuilder<T,C> |
validationStatusHandler(ValidationStatusHandler<ValidatableInput<T>> validationStatusHandler)
Set the
ValidationStatusHandler to use to input validation status changes. |
ValidatableInputBuilder<T,C> |
withValidator(com.holonplatform.core.Validator<T> validator)
|
ValidatableInputBuilder<T,C> withValidator(com.holonplatform.core.Validator<T> validator)
validator - Validator to add (not null)ValidatableInputBuilder<T,C> validationStatusHandler(ValidationStatusHandler<ValidatableInput<T>> validationStatusHandler)
ValidationStatusHandler to use to input validation status changes.validationStatusHandler - the ValidationStatusHandler to set (not null)ValidatableInputBuilder<T,C> validateOnValueChange(boolean validateOnValueChange)
Input component value every time the Input value changes.
Default is true.
validateOnValueChange - true to perform value validation every time the Input value
changes, false if notValidatableInputBuilder<T,C> required()
Input as required. Required inputs must filled by the user, and its validation will fail when
empty.ValidatableInputBuilder<T,C> required(com.holonplatform.core.Validator<T> validator)
Input as required, using given Validator to check the input value. Required inputs must
filled by the user, and its validation will fail when empty.validator - The Validator to use to check the required input value (not null)ValidatableInputBuilder<T,C> required(com.holonplatform.core.i18n.Localizable message)
Input as required, using given message as validation error message. Required inputs must filled
by the user, and its validation will fail when empty.message - The message to use to notify the required validation failuredefault ValidatableInputBuilder<T,C> required(String message, String messageCode, Object... arguments)
Input as required, using given message as validation error message. Required inputs must filled
by the user, and its validation will fail when empty.message - The default message to use to notify the required validation failuremessageCode - The message localization codearguments - Optional message translation argumentsdefault ValidatableInputBuilder<T,C> required(String message)
Input as required, using given message as validation error message. Required inputs must filled
by the user, and its validation will fail when empty.message - The default message to use to notify the required validation failureC build()
ValidatableInput instance.ValidatableInput instancestatic <T> ValidatableInputBuilder<T,ValidatableInput<T>> create(Input<T> input)
ValidatableInput from given Input.T - Value typeinput - The Input instance (not null)ValidatableInput builderCopyright © 2019 The Holon Platform. All rights reserved.