|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jibx.custom.classes.CustomBase
org.jibx.custom.classes.SharedNestingBase
org.jibx.custom.classes.NestingBase
org.jibx.custom.classes.GlobalCustom
public class GlobalCustom
Global customization information. This includes some options specific to the <binding> element of the definition, as well as controls for structuring of the generated binding(s). It handles the binding customization child elements directly, by invoking the abstract unmarshallers for the child elements to process the content. It also allows for extension elements which are not part of the binding customization structure, as long as the binding in use defines the unmarshalling for these elements.
Nested Class Summary | |
---|---|
static class |
GlobalCustom.Mapper
Unmarshaller implementation for class. |
Field Summary | |
---|---|
static int |
BOTH_BINDING
|
static java.lang.String |
ELEMENT_NAME
Element name in XML customization file. |
static int |
IN_BINDING
|
private boolean |
m_addConstructors
|
private IClassLocator |
m_classLocator
|
private java.util.List |
m_extensionChildren
|
private boolean |
m_forceClasses
|
private boolean |
m_isInput
|
private boolean |
m_isOutput
|
private boolean |
m_namespaceModular
|
private java.util.Map |
m_packageMap
|
private boolean |
m_trackSource
|
private java.util.ArrayList |
m_unmarshalledClasses
|
static int |
OUT_BINDING
|
static StringArray |
s_allowedAttributes
Enumeration of allowed attribute names |
(package private) static EnumSet |
s_directionEnum
|
Fields inherited from class org.jibx.custom.classes.NestingBase |
---|
ATTRIBUTE_STYLE_INTEGER, ATTRIBUTE_VALUE_STYLE, ELEMENT_STYLE_INTEGER, ELEMENT_VALUE_STYLE, s_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 | |
---|---|
GlobalCustom()
Constructor. |
|
GlobalCustom(IClassLocator loc)
Constructor with class locator supplied. |
Method Summary | |
---|---|
ClassCustom |
addClassCustomization(java.lang.String type)
Get initialized class customization information, creating it if it doesn't already exist. |
void |
addExtensionChild(java.lang.Object child)
Add a child extension element. |
private ClassCustom |
buildClassCustomization(java.lang.String type)
Build new class customization information. |
void |
fillClasses()
Fills in class information based on inspection of the actual class data. |
private ClassCustom |
forceClassCustomization(java.lang.String type)
Get class customization information, creating it if it doesn't already exist. |
ClassCustom |
getClassCustomization(java.lang.String type)
Get class customization information. |
IClass |
getClassInfo(java.lang.String type)
Get class information. |
protected IClassLocator |
getClassLocator()
Get class locator. |
private java.lang.String |
getDirectionText()
Direction get text method. |
java.util.List |
getExtensionChildren()
Get the extension elements used in this customization. |
GlobalCustom |
getGlobal()
Get global customizations root. |
PackageCustom |
getPackage(java.lang.String name)
Get package customizations. |
java.util.ArrayList |
getUnmarshalledClasses()
Get list of unmarshalled classes. |
void |
initClasses()
Initialize the global default namespace, along with special classes with built-in defaults. |
protected void |
internalAddExtensionChild(java.lang.Object child)
Internal method used during unmarshalling to add a child extension element. |
boolean |
isAddConstructors()
Get 'add-constructors' setting. |
boolean |
isClassUsed(java.lang.String type)
Check if a class is included in the customization information. |
boolean |
isForceClasses()
Get 'force-classes' setting. |
boolean |
isInput()
Check for an input binding. |
boolean |
isKnownMapping(java.lang.String type)
Check if type represents a known mapping. |
boolean |
isOutput()
Check for an output binding. |
boolean |
isTrackSource()
Get 'track-source' attribute value. |
private void |
preSet(IUnmarshallingContext uctx)
Make sure all attributes are defined. |
void |
setAddConstructors(boolean add)
Set 'add-constructors' value. |
private void |
setDirectionText(java.lang.String text,
IUnmarshallingContext ictx)
Direction set text method. |
void |
setForceClasses(boolean force)
Set 'force-classes' value. |
void |
setInput(boolean input)
Set input binding flag. |
void |
setOutput(boolean output)
Set output binding falg. |
void |
setTrackSource(boolean track)
Set 'track-source' value. |
Methods inherited from class org.jibx.custom.classes.NestingBase |
---|
getStripPrefixes, getStripSuffixes, getValueStyle, isForceMapping, isForceStructureNames, isMapAbstract, isPropertyAccess, isWrapCollections, setMapAbstract, setValueStyle |
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, getParent, packageOfType, packageToNamespace, validateAttributes |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final StringArray s_allowedAttributes
public static final java.lang.String ELEMENT_NAME
public static final int IN_BINDING
public static final int OUT_BINDING
public static final int BOTH_BINDING
static final EnumSet s_directionEnum
private java.util.Map m_packageMap
private final IClassLocator m_classLocator
private java.util.List m_extensionChildren
private boolean m_addConstructors
private boolean m_forceClasses
private boolean m_trackSource
private boolean m_namespaceModular
private boolean m_isInput
private boolean m_isOutput
private java.util.ArrayList m_unmarshalledClasses
Constructor Detail |
---|
public GlobalCustom(IClassLocator loc)
loc
- public GlobalCustom()
Method Detail |
---|
private void preSet(IUnmarshallingContext uctx)
uctx
- unmarshalling contextpublic GlobalCustom getGlobal()
getGlobal
in class CustomBase
public java.util.ArrayList getUnmarshalledClasses()
public boolean isAddConstructors()
public void setAddConstructors(boolean add)
add
- 'add-constructors' valuepublic boolean isForceClasses()
public void setForceClasses(boolean force)
force
- 'force-classes' valuepublic boolean isTrackSource()
public void setTrackSource(boolean track)
track
- 'track-source' valuepublic boolean isInput()
public void setInput(boolean input)
input
- public boolean isOutput()
public void setOutput(boolean output)
output
- protected IClassLocator getClassLocator()
public IClass getClassInfo(java.lang.String type)
type
- fully-qualified class name
null
if unable to loadpublic java.util.List getExtensionChildren()
protected void internalAddExtensionChild(java.lang.Object child)
child
- public void addExtensionChild(java.lang.Object child)
IApply.apply(IClassLocator)
method, if present.
child
- public boolean isClassUsed(java.lang.String type)
type
- fully qualified class name
true
if class includes, false
if notpublic ClassCustom getClassCustomization(java.lang.String type)
type
- fully qualified class name
null
if not defined)private ClassCustom buildClassCustomization(java.lang.String type)
getClassCustomization(String)
and
obtaining a null
result.
type
- fully qualified class name
private ClassCustom forceClassCustomization(java.lang.String type)
type
- fully qualified class name
public ClassCustom addClassCustomization(java.lang.String type)
type
- fully qualified class name
public boolean isKnownMapping(java.lang.String type)
type
- fully qualified class name
private void setDirectionText(java.lang.String text, IUnmarshallingContext ictx)
text
- ictx
- private java.lang.String getDirectionText()
public void initClasses()
public void fillClasses()
public PackageCustom getPackage(java.lang.String name)
name
-
|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |