Class ParticleBinder
java.lang.Object
com.sun.tools.xjc.reader.xmlschema.ParticleBinder
Binds the content models of
XSParticle as properties of the class that's being built.- Author:
- Kohsuke Kawaguchi (kohsuke.kawaguchi@sun.com)
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal voidbuild(XSParticle p) Builds theCPropertyInfos from the given particle (and its descendants), and set them to the class returned byClassSelector.getCurrentBean().abstract voidbuild(XSParticle p, Collection<XSParticle> forcedProps) The version of the build method that forces a specified set of particles to become a property.abstract booleanSimilar to the build method but this method only checks if the BGM that will be built by the build method will do the fallback (map all the properties into one list) or not.protected final StringComputes the label of a given particle.protected final ClassSelectorprotected final CClassInfoprotected final ErrorReporterprotected final <T extends BIDeclaration>
TgetLocalCustomization(XSParticle p, Class<T> type) protected final BIPropertyGets the BIProperty object that applies to the given particle.protected final StringgetSpecDefaultName(XSModelGroup mg, boolean repeated) Computes a name from unnamed model group by following the spec.protected final StringmakeJavaName(boolean isRepeated, String xmlName) Converts an XML name to the corresponding Java name.protected final StringmakeJavaName(XSParticle p, String xmlName)
-
Field Details
-
builder
-
-
Constructor Details
-
ParticleBinder
protected ParticleBinder()
-
-
Method Details
-
build
Builds theCPropertyInfos from the given particle (and its descendants), and set them to the class returned byClassSelector.getCurrentBean(). -
build
The version of the build method that forces a specified set of particles to become a property. -
checkFallback
Similar to the build method but this method only checks if the BGM that will be built by the build method will do the fallback (map all the properties into one list) or not.- Returns:
- false if the fallback will not happen.
-
getCurrentBean
-
getLocalPropCustomization
Gets the BIProperty object that applies to the given particle. -
getLocalCustomization
-
computeLabel
Computes the label of a given particle. Usually, the getLabel method should be used instead. -
makeJavaName
Converts an XML name to the corresponding Java name. -
makeJavaName
-
getSpecDefaultName
Computes a name from unnamed model group by following the spec. Taking first three elements and combine them.- Parameters:
repeated- if the said model group is repeated more than once- Throws:
ParseException- If the method cannot generate a name. For example, when a model group doesn't contain any element reference/declaration at all.
-
getErrorReporter
-
getClassSelector
-