|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.sun.msv.grammar.Expression | +--com.sun.msv.grammar.ReferenceExp | +--com.sun.msv.grammar.xmlschema.ElementDeclExp
Element declaration.
the inherited exp field holds an expression that also matches to substituted element declarations.
body
field contains an expression that matches
only to this element declaration without no substituted element decls.
This table shows the mapping between "element declaration schema component properties" (which is defined in the spec) and corresponding method/field of this class.
Property of the spec | method/field of this class |
name |
The ReferenceExp.name field.
|
target namespace |
the getTargetNamespace() method.
|
type definition |
getTypeDefinition() method.
|
scope | To be implemented |
value constraint |
To be implemented. Accessible through the body field.
|
nillable |
the isNillable field.
|
identity constraints |
The identityConstraints field of the ElementDeclExp.XSElementExp ,
which in turn can be obtained throught the body field.
|
substitution group affiliation |
The substitutionAffiliation field.
|
substitution group exclusion |
The finalValue field.
|
disallowed substitution |
The block field.
|
abstract |
the isAbstract() method.
|
annotation | Unaccessible. This information is removed during the parsing phase. |
The exp
field and the self
field are very similar.
In fact, the only difference is that the former is affected by the abstract
property, while the latter isn't.
So if it has to be affected by the
abstract property (like referencing a complex type as the element body),
you should use the exp
field.
If you don't want to be affected by the abstract property
(like referencing a complex type as the base type of another complex type),
then you should refer to the body
field.
Inner Class Summary | |
class |
ElementDeclExp.XSElementExp
XML Schema version of ElementExp . |
Field Summary | |
int |
block
The disallowed substitution property of this schema component, implemented as a bit field. |
ElementDeclExp.XSElementExp |
body
body. |
static int |
EXTENSION
|
int |
finalValue
The substitution group exclusions property of this schema component, implemented as a bit field. |
boolean |
isNillable
gets the nillable property of this component as specified in the spec. |
XMLSchemaSchema |
parent
parent XMLSchemaSchema object to which this object belongs. |
static int |
RESTRICTION
|
static int |
SUBSTITUTION
|
ElementDeclExp |
substitutionAffiliation
The substitution group affiliation property of this component, if any. |
ReferenceExp |
substitutions
choices of all elements that can validly substitute this element. |
Fields inherited from class com.sun.msv.grammar.ReferenceExp |
exp, name |
Fields inherited from class com.sun.msv.grammar.Expression |
anyString, epsilon, nullSet, verifierTag |
Constructor Summary | |
ElementDeclExp(XMLSchemaSchema schema,
String typeLocalName)
|
Method Summary | |
Expression |
getContentModel()
gets the pattern that represents the content model of this element declaration. |
String |
getTargetNamespace()
gets the target namespace property of this component as specified in the spec. |
XMLSchemaTypeExp |
getTypeDefinition()
gets the type definition property of this schema component. |
boolean |
isAbstract()
checks if this element declaration is abstract. |
boolean |
isDefined()
checks if this ReferenceExp is properly defined. |
boolean |
isGlobal()
gets the scope property of this component as specified in the spec. |
boolean |
isRestrictionBlocked()
|
boolean |
isSubstitutionBlocked()
|
void |
setAbstract(boolean isAbstract)
|
Methods inherited from class com.sun.msv.grammar.ReferenceExp |
equals, visit, visit, visit, visit |
Methods inherited from class com.sun.msv.grammar.Expression |
hashCode, isEpsilonReducible, visit, visit, visit, visit |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public ElementDeclExp substitutionAffiliation
public ElementDeclExp.XSElementExp body
public final ReferenceExp substitutions
public final XMLSchemaSchema parent
public boolean isNillable
public static final int RESTRICTION
public static final int EXTENSION
public static final int SUBSTITUTION
public int finalValue
a bit-wise OR of RESTRICTION and EXTENSION.
public int block
a bit-wise OR of RESTRICTION, EXTENSION, and SUBSTITUTION.
Constructor Detail |
public ElementDeclExp(XMLSchemaSchema schema, String typeLocalName)
Method Detail |
public Expression getContentModel()
self.contentModel
.public boolean isGlobal()
public final String getTargetNamespace()
If the property is absent, then this method returns the empty string.
This method is just a shortcut for parent.targetNamespace
.
public boolean isAbstract()
public void setAbstract(boolean isAbstract)
public boolean isSubstitutionBlocked()
public boolean isRestrictionBlocked()
public XMLSchemaTypeExp getTypeDefinition()
public boolean isDefined()
ReferenceExp
isDefined
in class ReferenceExp
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |