Hi,
I need to know the model group name in my application. There is a named
model group in my schema, which is like,
......
<xsd:group name="A">
<xsd:sequence>
<xsd:element name="B"/>
<xsd:element name="C"/>
</xsd:sequence>
</xsd:group>
......
My code is like,
......
XSNamedMap xsNameMap =
xsModel.getComponentsByNamespace(XSConstants.MODEL_GROUP_DEFINITION,
null);
for(int i = 0; i < xsNameMap.getLength(); i++) {
XSObject xso = xsNameMap.item(i);
XSModelGroupDefinition m =
(XSModelGroupDefinition)xsModel.getModelGroupDefinition(xso.getName(),
null);
System.out.println(m.getModelGroup().getName());
}
.......
However, the getName() method of the the ModelGroup object returns null. I
think it should tell us that the name is "A". Do you have any idea what is
going on? Or could be a bug in Xerces?
Thanks.
Lingzhi
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]