xsd.resolveComplexTypeDefinition(gmlNamespace, "AbstractFeatureType");
/** * Checks the given element's content against the complex type with a given name retrieved from the given schema. * @param schema the schema used to retrieve the complex type definition. * @param complexTypeName the name of the complex type. * @param part annotation part. * @param anchor annotation anchor. * @param element the element whose content to check. * @return a list of partially populated XSDDiagnostics---the primary component is not set---or the empty list if the content is valid. * @since 2.5 */ public static List<XSDDiagnostic> checkComplexContent(XSDSchema schema, String complexTypeName, String part, String anchor, Element element) { XSDComplexTypeDefinition xsdComplexTypeDefinition = schema.resolveComplexTypeDefinition(complexTypeName); return checkComplexContent(xsdComplexTypeDefinition, part, anchor, element); }
public XSDComplexTypeDefinition resolveComplexTypeDefinition(String namespace, String localName) { XSDSchema xsdSchema = getSchema(); if (xsdSchema != null) { return xsdSchema.resolveComplexTypeDefinition(namespace, localName); } else { return createUnresolvedComplexTypeDefinition(namespace, localName); } }
public XSDComplexTypeDefinition resolveComplexTypeDefinition(String namespace, String localName) { XSDSchema xsdSchema = getSchema(); if (xsdSchema != null) { return xsdSchema.resolveComplexTypeDefinition(namespace, localName); } else { return createUnresolvedComplexTypeDefinition(namespace, localName); } }
protected XSDDiagnostic checkComplexContent (XSDComplexTypeDefinition xsdComplexTypeDefinition, String part, String anchor, Element element) { List<XSDDiagnostic> xsdDiagnostics = XSDUtil.checkComplexContent(xsdComplexTypeDefinition, part, anchor, element); for (XSDDiagnostic xsdDiagnostic : xsdDiagnostics) { xsdDiagnostic.setPrimaryComponent(this); } getDiagnostics().addAll(xsdDiagnostics); return xsdDiagnostics.isEmpty() ? null : xsdDiagnostics.get(xsdDiagnostics.size() - 1); }
public XSDComplexTypeDefinition resolveComplexTypeDefinition(String localName) { XSDSchema xsdSchema = getSchema(); if (xsdSchema != null) { return xsdSchema.resolveComplexTypeDefinition(xsdSchema.getTargetNamespace(), localName); } else { return createUnresolvedComplexTypeDefinition(null, localName); } }
public XSDComplexTypeDefinition resolveComplexTypeDefinition(String localName) { XSDSchema xsdSchema = getSchema(); if (xsdSchema != null) { return xsdSchema.resolveComplexTypeDefinition(xsdSchema.getTargetNamespace(), localName); } else { return createUnresolvedComplexTypeDefinition(null, localName); } }
XSDSchemaImpl.getSchemaForSchema(theElement.getNamespaceURI()).resolveComplexTypeDefinition("anyType"); newBaseTypeDefinition = xsdSchema.getSchemaForSchema().resolveComplexTypeDefinition("anyType");
public static class FeatureIteratorImpl extends EContentsEList.FeatureIteratorImpl<XSDConcreteComponent> { public FeatureIteratorImpl(EObject eObject) { super(eObject, (EStructuralFeature [])((BasicEList<?>)eObject.eClass().getEAllReferences()).data()); } public FeatureIteratorImpl(EObject eObject, EStructuralFeature [] eStructuralFeatures) { super(eObject, eStructuralFeatures); } @Override protected boolean isIncluded(EStructuralFeature eStructuralFeature) { EReference eReference = (EReference)eStructuralFeature; return !eReference.isTransient(); } } }
@Override public XSDTypeDefinition getBaseType() { XSDTypeDefinition result = getBaseTypeDefinition(); if (result == this && XSDConstants.isAnyType(this)) { XSDSchema xsdSchema = getSchema(); if (xsdSchema != null) { String schemaForSchemaNamespace = xsdSchema.getSchemaForSchemaNamespace(); XSDSchemaImpl.getSchemaForSchema(schemaForSchemaNamespace).resolveComplexTypeDefinition("anyType"); } } return result; }
@Override public XSDTypeDefinition getBaseType() { XSDTypeDefinition result = getBaseTypeDefinition(); if (result == this && XSDConstants.isAnyType(this)) { XSDSchema xsdSchema = getSchema(); if (xsdSchema != null) { String schemaForSchemaNamespace = xsdSchema.getSchemaForSchemaNamespace(); XSDSchemaImpl.getSchemaForSchema(schemaForSchemaNamespace).resolveComplexTypeDefinition("anyType"); } } return result; }
public static class FeatureIteratorImpl extends EContentsEList.FeatureIteratorImpl<XSDConcreteComponent> { public FeatureIteratorImpl(EObject eObject) { super(eObject, (EStructuralFeature [])((BasicEList<?>)eObject.eClass().getEAllReferences()).data()); } public FeatureIteratorImpl(EObject eObject, EStructuralFeature [] eStructuralFeatures) { super(eObject, eStructuralFeatures); } @Override protected boolean isIncluded(EStructuralFeature eStructuralFeature) { EReference eReference = (EReference)eStructuralFeature; return !eReference.isTransient(); } } }
XSDSchemaImpl.getSchemaForSchema(theElement.getNamespaceURI()).resolveComplexTypeDefinition("anyType"); newBaseTypeDefinition = xsdSchema.getSchemaForSchema().resolveComplexTypeDefinition("anyType");
@Override public XSDComplexTypeDefinition resolveComplexTypeDefinition(String namespace, String localName) { XSDTypeDefinition xsdTypeDefinition = (XSDTypeDefinition)resolveNamedComponent(XSDPackage.Literals.XSD_SCHEMA__TYPE_DEFINITIONS, namespace, localName); XSDComplexTypeDefinition result = xsdTypeDefinition instanceof XSDComplexTypeDefinition ? (XSDComplexTypeDefinition)xsdTypeDefinition : null; if (result == null && XSDConstants.isSchemaForSchemaNamespace(namespace) && !XSDConstants.isSchemaForSchemaNamespace(getTargetNamespace())) { result = getSchemaForSchema(namespace).resolveComplexTypeDefinition(namespace, localName); } if (result == null) { result = createUnresolvedComplexTypeDefinition(namespace, localName); } return result; }
@Override public XSDComplexTypeDefinition resolveComplexTypeDefinition(String namespace, String localName) { XSDTypeDefinition xsdTypeDefinition = (XSDTypeDefinition)resolveNamedComponent(XSDPackage.Literals.XSD_SCHEMA__TYPE_DEFINITIONS, namespace, localName); XSDComplexTypeDefinition result = xsdTypeDefinition instanceof XSDComplexTypeDefinition ? (XSDComplexTypeDefinition)xsdTypeDefinition : null; if (result == null && XSDConstants.isSchemaForSchemaNamespace(namespace) && !XSDConstants.isSchemaForSchemaNamespace(getTargetNamespace())) { result = getSchemaForSchema(namespace).resolveComplexTypeDefinition(namespace, localName); } if (result == null) { result = createUnresolvedComplexTypeDefinition(namespace, localName); } return result; }
schema.resolveComplexTypeDefinition(GML.NAMESPACE, "AbstractFeatureType"));
XSDComplexTypeDefinition anyTypeDefinition = ctd.getSchema().getSchemaForSchema().resolveComplexTypeDefinition("anyType"); XSDContentTypeCategory contentType = ctd.getContentTypeCategory();
protected XSDDiagnostic checkComplexContent (XSDComplexTypeDefinition xsdComplexTypeDefinition, String part, String anchor, Element element) { XSDParticle complexType = xsdComplexTypeDefinition.getComplexType(); XSDParticle.DFA dfa = complexType.getDFA(); XSDParticle.DFA.State state = dfa.getInitialState(); for (Node child = element.getFirstChild(); child != null; child = child.getNextSibling()) { if (child.getNodeType() == Node.ELEMENT_NODE) { XSDParticle.DFA.Transition transition = state.accept(child.getNamespaceURI(), child.getLocalName()); if (transition != null) { state = transition.getState(); } else { XSDDiagnostic xsdDiagnostic = getXSDFactory().createXSDDiagnostic(); xsdDiagnostic.setSeverity(XSDDiagnosticSeverity.ERROR_LITERAL); xsdDiagnostic.setMessage (XSDPlugin.INSTANCE.getString ("_UI_XSDError_message", new Object [] { populateDiagnostic (xsdDiagnostic, "content-valid.1",
}; xsdComplexTypeDefinition = getSchema().getSchemaForSchema().resolveComplexTypeDefinition("keybase"); }; xsdComplexTypeDefinition = getSchema().getSchemaForSchema().resolveComplexTypeDefinition("keybase"); break;
}; xsdComplexTypeDefinition = getSchema().getSchemaForSchema().resolveComplexTypeDefinition("keybase"); }; xsdComplexTypeDefinition = getSchema().getSchemaForSchema().resolveComplexTypeDefinition("keybase"); break;