use of org.apache.ws.commons.schema.XmlSchemaContent in project tomee by apache.
the class CommonsSchemaInfoBuilder method isSoapArray.
private static boolean isSoapArray(XmlSchemaComplexType complexType) {
// Soap arrays are based on complex content restriction
XmlSchemaContentModel contentModel = complexType.getContentModel();
if (contentModel == null) {
return false;
}
XmlSchemaContent content = contentModel.getContent();
if (!(content instanceof XmlSchemaComplexContentRestriction)) {
return false;
}
XmlSchemaComplexContentRestriction restriction = (XmlSchemaComplexContentRestriction) content;
return SOAP_ARRAY.equals(restriction.getBaseTypeName());
}
use of org.apache.ws.commons.schema.XmlSchemaContent in project ddf by codice.
the class FeatureMetacardType method processComplexType.
private void processComplexType(XmlSchemaElement xmlSchemaElement) {
if (!processGmlType(xmlSchemaElement)) {
XmlSchemaType schemaType = xmlSchemaElement.getSchemaType();
if ((schemaType != null) && (schemaType instanceof XmlSchemaComplexType)) {
XmlSchemaComplexType complexType = (XmlSchemaComplexType) schemaType;
if (complexType.getParticle() != null) {
processXmlSchemaParticle(complexType.getParticle());
} else {
if (complexType.getContentModel() instanceof XmlSchemaComplexContent) {
XmlSchemaContent content = complexType.getContentModel().getContent();
if (content instanceof XmlSchemaComplexContentExtension) {
XmlSchemaComplexContentExtension extension = (XmlSchemaComplexContentExtension) content;
processXmlSchemaParticle(extension.getParticle());
}
}
}
}
}
}
Aggregations