public void validateRoot() { XSDConcreteComponent diagnosticTarget = this; XSDParticle xsdParticle; if (getContainer() instanceof XSDParticle) { xsdParticle = (XSDParticle)getContainer(); if (xsdParticle.eContainmentFeature() == XSDPackage.Literals.XSD_COMPLEX_TYPE_DEFINITION__SYNTHETIC_PARTICLE) { diagnosticTarget = xsdParticle.getContainer(); } } else { xsdParticle = XSDFactory.eINSTANCE.createXSDParticle(); xsdParticle.setTerm(this); } XSDParticleImpl.XSDNFA dfa = (XSDParticleImpl.XSDNFA)xsdParticle.getDFA(); Collection<XSDDiagnostic> diagnostics = dfa.getDiagnostics(); if (!diagnostics.isEmpty()) { for (XSDDiagnostic xsdDiagnostic : diagnostics) { xsdDiagnostic.setPrimaryComponent(diagnosticTarget); xsdDiagnostic.setNode(diagnosticTarget.getElement()); } getDiagnostics().addAll(diagnostics); } }
public void validateRoot() { XSDConcreteComponent diagnosticTarget = this; XSDParticle xsdParticle; if (getContainer() instanceof XSDParticle) { xsdParticle = (XSDParticle)getContainer(); if (xsdParticle.eContainmentFeature() == XSDPackage.Literals.XSD_COMPLEX_TYPE_DEFINITION__SYNTHETIC_PARTICLE) { diagnosticTarget = xsdParticle.getContainer(); } } else { xsdParticle = XSDFactory.eINSTANCE.createXSDParticle(); xsdParticle.setTerm(this); } XSDParticleImpl.XSDNFA dfa = (XSDParticleImpl.XSDNFA)xsdParticle.getDFA(); Collection<XSDDiagnostic> diagnostics = dfa.getDiagnostics(); if (!diagnostics.isEmpty()) { for (XSDDiagnostic xsdDiagnostic : diagnostics) { xsdDiagnostic.setPrimaryComponent(diagnosticTarget); xsdDiagnostic.setNode(diagnosticTarget.getElement()); } getDiagnostics().addAll(diagnostics); } }
XSDParticle complexType = xsdComplexTypeDefinition.getComplexType(); boolean mixed = xsdComplexTypeDefinition.isMixed(); XSDParticle.DFA dfa = complexType.getDFA(); XSDParticle.DFA.State state = dfa.getInitialState(); XSDFactory xsdFactory = XSDPackage.eINSTANCE.getXSDFactory();
public boolean isSubset(XSDParticle otherParticle, boolean diagnose) XSDNFA superSet = (XSDNFA)otherParticle.getDFA();
XSDParticle.DFA dfa = complexType.getDFA(); XSDParticle.DFA.State state = dfa.getInitialState(); for (Node child = element.getFirstChild(); child != null; child = child.getNextSibling())
public boolean isSubset(XSDParticle otherParticle, boolean diagnose) XSDNFA superSet = (XSDNFA)otherParticle.getDFA();