Package org.jibx.custom.classes
Class NestingBase
- java.lang.Object
-
- org.jibx.custom.classes.CustomBase
-
- org.jibx.custom.classes.SharedNestingBase
-
- org.jibx.custom.classes.NestingBase
-
- Direct Known Subclasses:
ClassCustom,GlobalCustom,PackageCustom
public abstract class NestingBase extends SharedNestingBase
Base class for all standard binding customizations that can contain other customizations.- Author:
- Dennis M. Sosnoski
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.IntegerATTRIBUTE_STYLE_INTEGERstatic intATTRIBUTE_VALUE_STYLEstatic java.lang.IntegerELEMENT_STYLE_INTEGERstatic intELEMENT_VALUE_STYLEprivate java.lang.Booleanm_forceMappingprivate java.lang.Booleanm_forceNamesprivate java.lang.Booleanm_mapAbstractprivate java.lang.Booleanm_propertyAccessprivate java.lang.String[]m_stripPrefixesprivate java.lang.String[]m_stripSuffixesprivate java.lang.Integerm_valueStyleprivate java.lang.Booleanm_wrapCollectionsstatic StringArrays_allowedAttributesEnumeration of allowed attribute namesstatic EnumSets_valueStyleEnum-
Fields inherited from class org.jibx.custom.classes.CustomBase
CAMEL_CASE_NAMES, DERIVE_BY_PACKAGE, DERIVE_FIXED, DERIVE_NONE, DOTTED_NAMES, HYPHENATED_NAMES, REQUIRE_ALL, REQUIRE_NONE, REQUIRE_OBJECTS, REQUIRE_PRIMITIVES, s_namespaceStyleEnum, s_nameStyleEnum, s_requireEnum, UNDERSCORED_NAMES, UPPER_CAMEL_CASE_NAMES
-
-
Constructor Summary
Constructors Constructor Description NestingBase(SharedNestingBase parent)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String[]getStripPrefixes()Get prefixes to be stripped from field names.java.lang.String[]getStripSuffixes()Get suffixes to be stripped from field names.intgetValueStyle(java.lang.String type)Get value style code.private java.lang.StringgetValueStyleText()Value style get text method.booleanisForceMapping()Check force mapping flag.booleanisForceStructureNames()Check force structure names flag.booleanisMapAbstract()Check abstract mapping flag.booleanisPropertyAccess()Check property access mode flag.booleanisWrapCollections()Check wrap collections flag.voidsetMapAbstract(java.lang.Boolean abs)Set abstract mapping flag.voidsetValueStyle(java.lang.Integer style)Set value style.private voidsetValueStyleText(java.lang.String text, IUnmarshallingContext ictx)Value style set text method.-
Methods inherited from class org.jibx.custom.classes.SharedNestingBase
convertName, getFormatterClass, getNamespace, getNamespaceStyle, getNameStyle, getSpecifiedNamespace, isObjectRequired, isPrimitiveRequired, isUseJavaDocs, setNamespace, setNamespaceStyle, setNameStyle
-
Methods inherited from class org.jibx.custom.classes.CustomBase
convertName, deriveItemName, deriveNamespace, getContainingObject, getGlobal, getParent, packageOfType, packageToNamespace, validateAttributes
-
-
-
-
Field Detail
-
s_allowedAttributes
public static final StringArray s_allowedAttributes
Enumeration of allowed attribute names
-
ATTRIBUTE_VALUE_STYLE
public static final int ATTRIBUTE_VALUE_STYLE
- See Also:
- Constant Field Values
-
ELEMENT_VALUE_STYLE
public static final int ELEMENT_VALUE_STYLE
- See Also:
- Constant Field Values
-
ATTRIBUTE_STYLE_INTEGER
public static final java.lang.Integer ATTRIBUTE_STYLE_INTEGER
-
ELEMENT_STYLE_INTEGER
public static final java.lang.Integer ELEMENT_STYLE_INTEGER
-
s_valueStyleEnum
public static final EnumSet s_valueStyleEnum
-
m_valueStyle
private java.lang.Integer m_valueStyle
-
m_propertyAccess
private java.lang.Boolean m_propertyAccess
-
m_stripPrefixes
private java.lang.String[] m_stripPrefixes
-
m_stripSuffixes
private java.lang.String[] m_stripSuffixes
-
m_mapAbstract
private java.lang.Boolean m_mapAbstract
-
m_wrapCollections
private java.lang.Boolean m_wrapCollections
-
m_forceMapping
private java.lang.Boolean m_forceMapping
-
m_forceNames
private java.lang.Boolean m_forceNames
-
-
Constructor Detail
-
NestingBase
public NestingBase(SharedNestingBase parent)
Constructor.- Parameters:
parent-
-
-
Method Detail
-
isMapAbstract
public boolean isMapAbstract()
Check abstract mapping flag. If not set at any nesting level, the default istrue.- Returns:
- abstract mapping flag
-
setMapAbstract
public void setMapAbstract(java.lang.Boolean abs)
Set abstract mapping flag.- Parameters:
abs-
-
isForceMapping
public boolean isForceMapping()
Check force mapping flag. If not set at any nesting level, the default isfalse.- Returns:
- force mapping flag
-
isForceStructureNames
public boolean isForceStructureNames()
Check force structure names flag. If not set at any nesting level, the default istrue.- Returns:
- force names flag
-
isWrapCollections
public boolean isWrapCollections()
Check wrap collections flag. If not set at any nesting level, the default isfalse.- Returns:
- wrap collections flag
-
isPropertyAccess
public boolean isPropertyAccess()
Check property access mode flag. If not set at any nesting level, the default isfalse.- Returns:
trueif bean-style get/set methods to be used,falseif fields to be used directly
-
getStripPrefixes
public java.lang.String[] getStripPrefixes()
Get prefixes to be stripped from field names.- Returns:
- strip prefixes (
nullif none)
-
getStripSuffixes
public java.lang.String[] getStripSuffixes()
Get suffixes to be stripped from field names.- Returns:
- strip suffix (
nullif none)
-
getValueStyle
public int getValueStyle(java.lang.String type)
Get value style code.- Parameters:
type- value type name- Returns:
- value from
s_valueStyleEnumenumeration
-
setValueStyle
public void setValueStyle(java.lang.Integer style)
Set value style.- Parameters:
style- (nullif none at this level)
-
setValueStyleText
private void setValueStyleText(java.lang.String text, IUnmarshallingContext ictx)Value style set text method. This is intended for use during unmarshalling. TODO: add validation- Parameters:
text-ictx-
-
getValueStyleText
private java.lang.String getValueStyleText()
Value style get text method. This is intended for use during marshalling.- Returns:
- text
-
-