public class AttributeSchemaValidationBuilder extends Object
Modifier and Type | Class and Description |
---|---|
static class |
AttributeSchemaValidationBuilder.DD_VALIDATION_TYPES |
static class |
AttributeSchemaValidationBuilder.SCHEMA_BASE_TYPES |
Modifier and Type | Field and Description |
---|---|
protected String |
attributeKey |
protected Map |
attributeMap |
protected static String |
DD_ALLOW_WHITESPACE_KEY |
protected static String |
DD_MAP_EXACT_LENGTH_KEY |
protected static String |
DD_MAP_EXCLUSIVE_MAX_KEY |
protected static String |
DD_MAP_EXCLUSIVE_MIN_KEY |
protected static String |
DD_MAP_MAX_LENGTH_KEY |
protected static String |
DD_MAP_REQUIRED_KEY |
protected static String |
DD_MAP_VALIDATION_KEY |
protected static String |
DD_MAP_VALIDATION_TYPE_KEY |
static String |
XSD_SCHEMA_PREFIX |
Constructor and Description |
---|
AttributeSchemaValidationBuilder()
Constructs a AttributeSchemaValidationBuilder.java.
|
AttributeSchemaValidationBuilder(String attributeKey)
Constructs a AttributeSchemaValidationBuilder.java.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
getAllowWhitespaceFromMap()
Helper method to get the allow whitespace setting from dd Map
|
String |
getAttributeKey()
Gets the attributeKey attribute.
|
protected int |
getExactLengthFromMap()
Helper method to get the exact length from the dd Map
|
Collection |
getFurtherRestrictionTags()
Based on attribute definition adds any further restrictions to the type
|
protected int |
getMaxLengthFromMap()
Helper method to get the max length from the dd map
|
protected boolean |
getRequiredFromMap()
Helper method to get the required setting from dd Map
|
String |
getRestrictionTagCloser()
Builds restriction closing tag
|
String |
getRestrictionTagOpener()
Builds restriction opening tag.
|
String |
getTypeTagCloser()
Builds simple type closing tag .
|
String |
getTypeTagOpener()
Builds simple type opening tag .
|
protected String |
getValidationType()
Helper method to get validation type from dd Map
|
protected boolean |
isDateType()
Determines if the attribute's validation type is the Date validation type
|
protected boolean |
isDecimalType()
Determines if the attribute's validation type is the Decimal validation type
|
protected boolean |
isFloatingType()
Determines if the attribute's validation type is the Floating validation type
|
protected boolean |
isNumericType()
Determines if the attribute's validation type is the Numeric validation type
|
protected boolean |
isStringType()
Determines if the attribute's validation type is a String validation type
|
protected boolean |
isTimestampType()
Determines if the attribute's validation type is the Timestamp validation type
|
void |
setAttributeKey(String attributeKey)
Sets the attributeKey attribute value.
|
Collection |
toSchemaType()
Based on data dictionary configuration for attribute builds a complete schema simple type with the appropriate base and
restrictions
|
protected static final String DD_MAP_MAX_LENGTH_KEY
protected static final String DD_MAP_EXACT_LENGTH_KEY
protected static final String DD_MAP_REQUIRED_KEY
protected static final String DD_MAP_EXCLUSIVE_MIN_KEY
protected static final String DD_MAP_EXCLUSIVE_MAX_KEY
protected static final String DD_MAP_VALIDATION_KEY
protected static final String DD_MAP_VALIDATION_TYPE_KEY
protected static final String DD_ALLOW_WHITESPACE_KEY
public static final String XSD_SCHEMA_PREFIX
protected String attributeKey
protected Map attributeMap
public AttributeSchemaValidationBuilder()
public AttributeSchemaValidationBuilder(String attributeKey)
attributeKey
- name of data dictionary entry to build type forpublic Collection toSchemaType()
public String getTypeTagOpener()
public String getTypeTagCloser()
public String getRestrictionTagOpener()
public String getRestrictionTagCloser()
public Collection getFurtherRestrictionTags()
protected int getMaxLengthFromMap()
protected int getExactLengthFromMap()
protected boolean getRequiredFromMap()
protected boolean getAllowWhitespaceFromMap()
protected String getValidationType()
protected boolean isDateType()
protected boolean isTimestampType()
protected boolean isNumericType()
protected boolean isDecimalType()
protected boolean isFloatingType()
protected boolean isStringType()
public String getAttributeKey()
public void setAttributeKey(String attributeKey)
attributeKey
- The attributeKey to set.Copyright © 2004–2015 The Kuali Foundation. All rights reserved.