|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.xerces.impl.validation.datatypes.eTypes.Models.AbstractProperty | +--org.apache.xerces.impl.validation.datatypes.eTypes.Models.PartialOrder | +--org.apache.xerces.impl.validation.datatypes.eTypes.Data.BasicStringProperty
Supports constraints on length, range (using lexicographic order) and regular expression.
Empty string ("") may be valid, null string always
Inner classes inherited from class org.apache.xerces.impl.validation.datatypes.eTypes.Models.AbstractProperty |
AbstractProperty.AbstractSummary |
Inner classes inherited from class org.apache.xerces.impl.validation.datatypes.eTypes.Interfaces.Property |
Property.ValidationSummary |
Field Summary | |
static int |
classNumberSubProperties
|
static java.lang.reflect.Method |
evalMaxLenClosed
|
static java.lang.reflect.Method |
evalMaxLenOpen
|
static java.lang.reflect.Method |
evalMinLenClosed
|
static java.lang.reflect.Method |
evalMinLenOpen
|
static java.lang.reflect.Method |
evalPattern
|
static int |
MAX_LEN
length constraints are inclusive. |
static int |
MIN_LEN
length constraints are inclusive. |
static int |
PATTERN
|
java.lang.String |
sValue
|
Fields inherited from class org.apache.xerces.impl.validation.datatypes.eTypes.Models.PartialOrder |
classNumberSubProperties,
CLOSED_ABOVE,
CLOSED_BELOW,
MAX,
MIN |
Fields inherited from class org.apache.xerces.impl.validation.datatypes.eTypes.Models.AbstractProperty |
classNumberSubProperties,
ht,
required |
Fields inherited from interface org.apache.xerces.impl.validation.datatypes.eTypes.Interfaces.StringProperty |
classNumberSubProperties,
MAX_LEN,
MIN_LEN,
PATTERN |
Fields inherited from interface org.apache.xerces.impl.validation.datatypes.eTypes.Interfaces.Property |
accumulate,
classNumberSubProperties,
constraint,
eval,
instance,
merge |
Constructor Summary | |
BasicStringProperty()
|
|
BasicStringProperty(java.lang.Class cl,
java.lang.String str)
|
|
BasicStringProperty(java.lang.String str)
|
Method Summary | |
boolean |
accumulate(java.lang.String dt)
|
java.lang.Integer |
compareTo(java.lang.Object other)
Compare using java.lang.String.compareTo. |
protected void |
enableSubProp(java.lang.String name)
The next method is included to remind developer's that they are responsible for setting the eval and merge functions for subProp's for classes which they define. |
static java.lang.Object |
evalMaxLenClosed(java.lang.Object obj,
java.lang.Object constraint)
Determines whether obj (which is String) has length <= constraint (which is String or Integer) Returns length if yes, else null |
static java.lang.Object |
evalMaxLenOpen(java.lang.Object obj,
java.lang.Object constraint)
Determines whether obj (which is String) has length < constraint (which is String or Integer) Returns length if yes, else null |
static java.lang.Object |
evalMinLenClosed(java.lang.Object obj,
java.lang.Object constraint)
Determines whether obj (which is String) has length >> constraint (which is String or Integer). |
static java.lang.Object |
evalMinLenOpen(java.lang.Object obj,
java.lang.Object constraint)
Determines whether obj (which is String) has length > constraint (which is String or Integer). |
static java.lang.Object |
evalPattern(java.lang.Object obj,
java.lang.Object constraint)
Determines whether obj (which is String) matches Pattern contained in constraint. |
int |
getMaxLength(java.lang.Integer type)
If > 0, length of longest string which may be valid |
int |
getMinLength(java.lang.Integer type)
If > 0, length of shortest string which may be valid |
java.lang.String |
getPattern()
Returns pattern (Perl 5 syntax) which restricts form of valid strings |
java.lang.String |
getPatternOptions()
Returns options assoc with pattern (Perl 5 syntax) (regex.jar) |
java.lang.String |
getSValue()
|
java.lang.String |
mapString(java.lang.String o)
|
void |
setMaxLength(int newMaxLength,
java.lang.Integer type)
length constraints are inclusive |
void |
setMinLength(int newMinLength,
java.lang.Integer type)
length constraints are inclusive |
void |
setPattern(java.lang.String newPattern)
Sets pattern which restricts form of valid strings |
void |
setPattern(java.lang.String newPattern,
java.lang.String options)
|
void |
setSValue(java.lang.String newSValue)
|
Property |
twin()
Regular expressions are mutable so 'clone' it |
boolean |
validate(java.lang.String val)
Null string is always |
Methods inherited from class org.apache.xerces.impl.validation.datatypes.eTypes.Models.PartialOrder |
getBound,
getClosed,
glb,
gt,
isBounded,
isClosed,
lt,
lub,
merge,
merge,
setBound,
setClosed |
Methods inherited from class org.apache.xerces.impl.validation.datatypes.eTypes.Models.AbstractProperty |
accumulate,
add2Report,
clone,
getJClass,
getName,
getPossible,
getReport,
getSubProp,
getSubPropEval,
getSubPropMerge,
getSubPropName,
getSubPropNameIndex,
merge,
msg,
resetAccumulator,
resetConstraint,
resetInstance,
setJClass,
setName,
setPossible,
setRequired,
setSubProp,
setSubProp,
setSubPropEval,
setSubPropMerge,
setSubPropName,
toString,
validate |
Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
public static final int MAX_LEN
public static final int MIN_LEN
public static final int PATTERN
public static final int classNumberSubProperties
public static final java.lang.reflect.Method evalMinLenOpen
public static final java.lang.reflect.Method evalMinLenClosed
public static final java.lang.reflect.Method evalMaxLenOpen
public static final java.lang.reflect.Method evalMaxLenClosed
public static final java.lang.reflect.Method evalPattern
public java.lang.String sValue
Constructor Detail |
public BasicStringProperty()
public BasicStringProperty(java.lang.Class cl, java.lang.String str)
public BasicStringProperty(java.lang.String str)
Method Detail |
public boolean accumulate(java.lang.String dt)
public java.lang.Integer compareTo(java.lang.Object other)
other
- com.ibm.eTypes.Interfaces.PO_IFprotected void enableSubProp(java.lang.String name)
public static final java.lang.Object evalMaxLenClosed(java.lang.Object obj, java.lang.Object constraint)
public static final java.lang.Object evalMaxLenOpen(java.lang.Object obj, java.lang.Object constraint)
public static final java.lang.Object evalMinLenClosed(java.lang.Object obj, java.lang.Object constraint)
public static final java.lang.Object evalMinLenOpen(java.lang.Object obj, java.lang.Object constraint)
public static final java.lang.Object evalPattern(java.lang.Object obj, java.lang.Object constraint)
constraint instanceof RegularExpression
it returns
Boolean.TRUE or null. If constraint instanceof Object[] && constraint[0]
instanceof RegularExpression && constraint[1] instanceof Match
returns the match (after matching) or nullpublic int getMaxLength(java.lang.Integer type)
public int getMinLength(java.lang.Integer type)
public java.lang.String getPattern()
public java.lang.String getPatternOptions()
public java.lang.String getSValue()
public java.lang.String mapString(java.lang.String o)
public void setMaxLength(int newMaxLength, java.lang.Integer type)
public void setMinLength(int newMinLength, java.lang.Integer type)
public void setPattern(java.lang.String newPattern)
newPattern
- java.lang.Stringpublic void setPattern(java.lang.String newPattern, java.lang.String options)
public void setSValue(java.lang.String newSValue)
newSValue
- java.lang.Stringpublic Property twin()
public boolean validate(java.lang.String val)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |