public class DefaultValidatorDescriptor extends Object implements ValidatorDescriptor
ValidatorDescriptor
implementation.ValidatorDescriptor.Builder
Constructor and Description |
---|
DefaultValidatorDescriptor() |
Modifier and Type | Method and Description |
---|---|
Integer |
getFractionDigits()
Get the fractional digits count.
|
Set<?> |
getIn()
Get the admitted values
|
Integer |
getIntegerDigits()
Get the integer digits count.
|
Number |
getMax()
Get the maximum value.
|
Number |
getMin()
Get the minimum value.
|
Set<?> |
getNotIn()
Get the not admitted values
|
String |
getPattern()
Get the value regexp pattern.
|
boolean |
isEmail()
Get whether the value is of email type.
|
boolean |
isExclusiveMax()
Get whether the maximum value is exclusive.
|
boolean |
isExclusiveMin()
Get whether the minimum value is exclusive.
|
boolean |
isFuture()
Get whether the value must be in the future.
|
boolean |
isPast()
Get whether the value must be in the past.
|
boolean |
isRequired()
Get whether the value is required.
|
void |
setEmail(boolean email)
Set whether the value is of email type.
|
void |
setExclusiveMax(boolean exclusiveMax)
Set whether the maximum value is exclusive.
|
void |
setExclusiveMin(boolean exclusiveMin)
Set whether the minimum value is exclusive.
|
void |
setFractionDigits(Integer fractionDigits)
Set the fractional digits count.
|
void |
setFuture(boolean future)
Set whether the value must be in the future.
|
void |
setIn(Set<?> in)
Set the admitted values.
|
void |
setIntegerDigits(Integer integerDigits)
Set the integer digits count.
|
void |
setMax(Number max)
Set the maximum value.
|
void |
setMin(Number min)
Set the miminum value.
|
void |
setNotIn(Set<?> notIn)
Set the not admitted values.
|
void |
setPast(boolean past)
Set whether the value must be in the past.
|
void |
setPattern(String pattern)
Set the value regexp pattern.
|
void |
setRequired(boolean required)
Set whether the value is required.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
builder
public boolean isRequired()
ValidatorDescriptor
isRequired
in interface ValidatorDescriptor
public void setRequired(boolean required)
required
- whether the value is requiredpublic boolean isEmail()
ValidatorDescriptor
isEmail
in interface ValidatorDescriptor
public void setEmail(boolean email)
email
- whether the value is of email type.public boolean isPast()
ValidatorDescriptor
isPast
in interface ValidatorDescriptor
public void setPast(boolean past)
past
- whether the value must be in the pastpublic boolean isFuture()
ValidatorDescriptor
isFuture
in interface ValidatorDescriptor
public void setFuture(boolean future)
future
- whether the value must be in the futurepublic Number getMin()
ValidatorDescriptor
getMin
in interface ValidatorDescriptor
public void setMin(Number min)
min
- the miminum valuepublic Number getMax()
ValidatorDescriptor
getMax
in interface ValidatorDescriptor
public void setMax(Number max)
max
- the maximum valuepublic boolean isExclusiveMin()
ValidatorDescriptor
isExclusiveMin
in interface ValidatorDescriptor
public boolean isExclusiveMax()
ValidatorDescriptor
isExclusiveMax
in interface ValidatorDescriptor
public void setExclusiveMin(boolean exclusiveMin)
exclusiveMin
- whether the minimum value is exclusivepublic void setExclusiveMax(boolean exclusiveMax)
exclusiveMax
- whether the maximum value is exclusivepublic String getPattern()
ValidatorDescriptor
getPattern
in interface ValidatorDescriptor
public void setPattern(String pattern)
pattern
- the value regexp patternpublic Integer getIntegerDigits()
ValidatorDescriptor
getIntegerDigits
in interface ValidatorDescriptor
public void setIntegerDigits(Integer integerDigits)
integerDigits
- the integer digits countpublic Integer getFractionDigits()
ValidatorDescriptor
getFractionDigits
in interface ValidatorDescriptor
public void setFractionDigits(Integer fractionDigits)
fractionDigits
- the fractional digits countpublic Set<?> getIn()
ValidatorDescriptor
getIn
in interface ValidatorDescriptor
public Set<?> getNotIn()
ValidatorDescriptor
getNotIn
in interface ValidatorDescriptor
public void setIn(Set<?> in)
in
- Valuespublic void setNotIn(Set<?> notIn)
notIn
- ValuesCopyright © 2019 The Holon Platform. All rights reserved.