public class TelephoneNumberSyntaxChecker extends SyntaxChecker
| Modifier and Type | Field and Description |
|---|---|
private java.util.List<java.util.regex.Pattern> |
compiledREs
Other regexp to extend the initial one, compiled
|
private static java.lang.String |
DEFAULT_REGEXP
The default pattern used to check a TelephoneNumber
|
protected boolean |
defaultMandatory
A flag set when only the default regexp should be tested
|
private java.util.regex.Pattern |
defaultPattern
The compiled default pattern
|
private static org.slf4j.Logger |
LOG
A logger for this class
|
private java.util.List<java.lang.String> |
regexps
Other regexps to extend the initial one
|
serialVersionUIDdescription, extensions, isEnabled, isObsolete, isReadOnly, locked, names, objectType, oid, schemaName, specification| Constructor and Description |
|---|
TelephoneNumberSyntaxChecker()
Creates a new instance of TelephoneNumberSyntaxChecker.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addRegexp(java.lang.String regexp)
Add a new valid regexp for a Telephone number
|
boolean |
isValidSyntax(java.lang.Object value)
Determines if the attribute's value conforms to the attribute syntax.
|
void |
setDefaultRegexp(java.lang.String regexp)
Set the defaut regular expression for the Telephone number
|
equals, setSchemaManager, toStringcopy, getBytecode, getFqcn, isValid, setBytecode, setFqcnaddExtension, addExtension, addName, clear, compareOid, copy, getDescription, getExtension, getExtensions, getName, getNames, getObjectType, getOid, getSchemaName, getSpecification, hasExtension, hashCode, isDisabled, isEnabled, isObsolete, isReadOnly, lock, setDescription, setEnabled, setExtensions, setNames, setNames, setObsolete, setOid, setReadOnly, setSchemaName, setSpecification, unlockprivate static final org.slf4j.Logger LOG
private java.util.List<java.lang.String> regexps
private java.util.List<java.util.regex.Pattern> compiledREs
private static final java.lang.String DEFAULT_REGEXP
private java.util.regex.Pattern defaultPattern
protected boolean defaultMandatory
public TelephoneNumberSyntaxChecker()
public void addRegexp(java.lang.String regexp)
regexp - The new regexp to checkpublic void setDefaultRegexp(java.lang.String regexp)
regexp - the default regular expression.public boolean isValidSyntax(java.lang.Object value)
isValidSyntax in class SyntaxCheckervalue - the value of some attribute with the syntax