Package org.cip4.jdflib.extensions
Class XJDFSchemaCreator.WalkElement
- java.lang.Object
-
- org.cip4.jdflib.elementwalker.BaseWalker
-
- org.cip4.jdflib.extensions.XJDFSchemaCreator.WalkElement
-
- All Implemented Interfaces:
java.lang.Comparable<BaseWalker>,IWalker
- Direct Known Subclasses:
XJDFSchemaCreator.WalkChildProduct,XJDFSchemaCreator.WalkDependent,XJDFSchemaCreator.WalkDeviceCap,XJDFSchemaCreator.WalkEnumerationType,XJDFSchemaCreator.WalkIgnore,XJDFSchemaCreator.WalkJobPhase,XJDFSchemaCreator.WalkNode,XJDFSchemaCreator.WalkProduct,XJDFSchemaCreator.WalkProductList,XJDFSchemaCreator.WalkResource,XJDFSchemaCreator.WalkResourceElement,XJDFSchemaCreator.WalkResSet,XJDFSchemaCreator.WalkRoot,XJDFSchemaCreator.WalkState,XJDFSchemaCreator.WalkTerm,XJDFSchemaCreator.WalkTextElement
- Enclosing class:
- XJDFSchemaCreator
protected class XJDFSchemaCreator.WalkElement extends BaseWalker
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classXJDFSchemaCreator.WalkElement.AttributeDescriptorprotected classXJDFSchemaCreator.WalkElement.VAttributeDescriptor
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Set<java.lang.String>baseAttribsprotected java.util.Set<java.lang.String>baseElmsprotected KElementcomplexElementprotected KElementcomplexTypeprotected KElemente2protected java.util.Set<java.lang.String>myNodesprotected java.util.Set<java.lang.String>refElmsprotected java.util.Set<java.lang.String>refsElms-
Fields inherited from class org.cip4.jdflib.elementwalker.BaseWalker
depth, log
-
-
Constructor Summary
Constructors Constructor Description WalkElement()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected KElementappendSimpleTypeList(KElement schemaRoot, java.lang.String typeName, java.lang.String baseType)protected voidcreatebaseAttribs()protected voidcreatebaseElms()protected voidcreateSubstitutionBase(KElement out, java.lang.String name)voidfinalizeWalk(KElement e, KElement trackElem)hook for guaranteed postwalk finalizationprotected XJDFSchemaCreator.WalkElement.VAttributeDescriptorgetKnownAtts()protected VStringgetKnownElms()protected java.lang.StringgetNewName(java.lang.String string)locally map attnames and elmnamesprotected XJDFSchemaCreator.WalkElement.AttributeDescriptorgetSpanAttDesc(java.lang.String s)protected java.lang.StringgetTypeForName(java.lang.String elmName)booleanmatches(KElement e)this is the check whether or not to use this walker for a given element should be overwrittenvoidprepareWalk(KElement e, KElement trackElem)hook for guaranteed prewalk initializationprotected KElementsetComplexType(KElement out, java.lang.String name)protected voidsetGeneric(KElement complexType, boolean bID)protected KElementsetXSAttribute(KElement root, java.lang.String attName, java.lang.String typName, boolean required, org.apache.commons.lang.enums.ValuedEnum ve)protected voidsetXSAttribute(KElement root, java.lang.String attName, AttributeInfo.EnumAttributeType typ, boolean required)protected KElementsetXSAttribute(XJDFSchemaCreator.WalkElement.AttributeDescriptor ad)protected voidsetXSElement(KElement root, java.lang.String elmName)KElementwalk(KElement in, KElement out)the mother routine for walking....-
Methods inherited from class org.cip4.jdflib.elementwalker.BaseWalker
compareTo, getDepth, getElementNames, toString
-
-
-
-
Field Detail
-
complexType
protected KElement complexType
-
complexElement
protected KElement complexElement
-
baseAttribs
protected java.util.Set<java.lang.String> baseAttribs
-
baseElms
protected java.util.Set<java.lang.String> baseElms
-
refElms
protected java.util.Set<java.lang.String> refElms
-
refsElms
protected java.util.Set<java.lang.String> refsElms
-
myNodes
protected java.util.Set<java.lang.String> myNodes
-
e2
protected KElement e2
-
-
Method Detail
-
createbaseAttribs
protected void createbaseAttribs()
-
walk
public KElement walk(KElement in, KElement out)
Description copied from class:BaseWalkerthe mother routine for walking....- Specified by:
walkin interfaceIWalker- Overrides:
walkin classBaseWalker- Parameters:
in-out-- Returns:
- not null if must continue
- See Also:
IWalker.walk(KElement, KElement)
-
setXSAttribute
protected KElement setXSAttribute(XJDFSchemaCreator.WalkElement.AttributeDescriptor ad)
- Parameters:
ad-- Returns:
-
getNewName
protected java.lang.String getNewName(java.lang.String string)
locally map attnames and elmnames- Parameters:
string-- Returns:
-
createbaseElms
protected void createbaseElms()
-
matches
public boolean matches(KElement e)
Description copied from class:BaseWalkerthis is the check whether or not to use this walker for a given element should be overwritten- Overrides:
matchesin classBaseWalker- Parameters:
e-- Returns:
- See Also:
BaseWalker.matches(org.cip4.jdflib.core.KElement)
-
finalizeWalk
public void finalizeWalk(KElement e, KElement trackElem)
Description copied from class:BaseWalkerhook for guaranteed postwalk finalization- Specified by:
finalizeWalkin interfaceIWalker- Overrides:
finalizeWalkin classBaseWalker- Parameters:
e-trackElem-- See Also:
BaseWalker.finalizeWalk(org.cip4.jdflib.core.KElement, org.cip4.jdflib.core.KElement)
-
prepareWalk
public void prepareWalk(KElement e, KElement trackElem)
Description copied from class:BaseWalkerhook for guaranteed prewalk initialization- Specified by:
prepareWalkin interfaceIWalker- Overrides:
prepareWalkin classBaseWalker- Parameters:
e-trackElem-- See Also:
BaseWalker.prepareWalk(org.cip4.jdflib.core.KElement, org.cip4.jdflib.core.KElement)
-
setXSAttribute
protected void setXSAttribute(KElement root, java.lang.String attName, AttributeInfo.EnumAttributeType typ, boolean required)
- Parameters:
root-attName-typ-required-
-
setXSAttribute
protected KElement setXSAttribute(KElement root, java.lang.String attName, java.lang.String typName, boolean required, org.apache.commons.lang.enums.ValuedEnum ve)
- Parameters:
root-attName-typName-required-ve- a valued enum to generate values- Returns:
-
setGeneric
protected void setGeneric(KElement complexType, boolean bID)
- Parameters:
complexType-bID-
-
setComplexType
protected KElement setComplexType(KElement out, java.lang.String name)
- Parameters:
out-name-- Returns:
-
setXSElement
protected void setXSElement(KElement root, java.lang.String elmName)
- Parameters:
root-elmName-
-
getTypeForName
protected java.lang.String getTypeForName(java.lang.String elmName)
- Parameters:
elmName-- Returns:
-
getSpanAttDesc
protected XJDFSchemaCreator.WalkElement.AttributeDescriptor getSpanAttDesc(java.lang.String s)
- Parameters:
s-- Returns:
-
getKnownAtts
protected XJDFSchemaCreator.WalkElement.VAttributeDescriptor getKnownAtts()
- Returns:
- See Also:
getKnownAtts()
-
getKnownElms
protected VString getKnownElms()
- Returns:
- See Also:
getKnownElms()
-
createSubstitutionBase
protected void createSubstitutionBase(KElement out, java.lang.String name)
- Parameters:
out-name-
-
-