@Override public void startElement(String uri, String localName, String name, Attributes attributes) throws SAXException { if (documentRoot != null) { EObject eObject = objects.peekEObject(); if (eObject == documentRoot && (extendedMetaData == null || extendedMetaData.isDocumentRoot(eObject.eClass()))) { types.pop(); objects.pop(); mixedTargets.pop(); documentRoot= null; } } super.startElement(uri, localName, name, attributes); } } // XMIHandler
@Override public void startElement(String uri, String localName, String name, Attributes attributes) throws SAXException { if (documentRoot != null) { EObject eObject = objects.peekEObject(); if (eObject == documentRoot && (extendedMetaData == null || extendedMetaData.isDocumentRoot(eObject.eClass()))) { types.pop(); objects.pop(); mixedTargets.pop(); documentRoot= null; } } super.startElement(uri, localName, name, attributes); } } // XMIHandler
if (text != null) setValueFromId(objects.peekEObject(), (EReference)type, text.toString()); text = null; if (eObject == null) eObject = objects.peekEObject();
EObject peekObject = objects.peekEObject(); EObject childObject = objects.peekEObject(); if (childObject != null)
EObject peekObject = objects.peekEObject(); if (!(peekObject instanceof AnyType)) AnyType anyType = getExtension(objects.peekEObject()); EStructuralFeature entryFeature = extendedMetaData.demandFeature(extendedMetaData.getNamespace(feature), extendedMetaData.getName(feature), true); String name = extendedMetaData.getName(feature); EStructuralFeature wildcardFeature = extendedMetaData.getElementWildcardAffiliation((objects.peekEObject()).eClass(), namespace, name); if (wildcardFeature != null) result = createObjectFromFactory(factory, typeName); EObject peekObject = objects.peekEObject(); if (!(peekObject instanceof AnyType)) String name = extendedMetaData.getName(feature); EStructuralFeature wildcardFeature = extendedMetaData.getElementWildcardAffiliation((objects.peekEObject()).eClass(), namespace, name); if (wildcardFeature != null)
EObject peekObject = objects.peekEObject(); EObject childObject = objects.peekEObject(); if (childObject != null)
EObject peekObject = objects.peekEObject(); if (!(peekObject instanceof AnyType)) AnyType anyType = getExtension(objects.peekEObject()); EStructuralFeature entryFeature = extendedMetaData.demandFeature(extendedMetaData.getNamespace(feature), extendedMetaData.getName(feature), true); String name = extendedMetaData.getName(feature); EStructuralFeature wildcardFeature = extendedMetaData.getElementWildcardAffiliation((objects.peekEObject()).eClass(), namespace, name); if (wildcardFeature != null) result = createObjectFromFactory(factory, typeName); EObject peekObject = objects.peekEObject(); if (!(peekObject instanceof AnyType)) String name = extendedMetaData.getName(feature); EStructuralFeature wildcardFeature = extendedMetaData.getElementWildcardAffiliation((objects.peekEObject()).eClass(), namespace, name); if (wildcardFeature != null)
if (text != null) setValueFromId(objects.peekEObject(), (EReference)type, text.toString()); text = null; if (eObject == null) eObject = objects.peekEObject();
String name = extendedMetaData.getName(contextFeature); EStructuralFeature wildcardFeature = extendedMetaData.getElementWildcardAffiliation((objects.peekEObject()).eClass(), namespace, name); if (wildcardFeature != null)
String name = extendedMetaData.getName(contextFeature); EStructuralFeature wildcardFeature = extendedMetaData.getElementWildcardAffiliation((objects.peekEObject()).eClass(), namespace, name); if (wildcardFeature != null)
@Override protected void handleFeature(String prefix, String name) { super.handleFeature(prefix, name); // Interpret the body of a nested ownedComment as a comment-type and assign it as the EAnnotation.source of the parent. // if (EMOFExtendedMetaData.EMOF_OWNED_COMMENT.equals(name) && objects.peekEObject() instanceof EAnnotation) { EAnnotation annotation = (EAnnotation)objects.peekEObject(); EObject container = annotation.eContainer(); if (container instanceof EAnnotation) { EAnnotation parentAnnotation = (EAnnotation)container; parentAnnotation.setSource(annotation.getDetails().get(EMOFExtendedMetaData.EMOF_COMMENT_BODY)); parentAnnotation.getEAnnotations().remove(annotation); } } }
@Override protected void handleFeature(String prefix, String name) { super.handleFeature(prefix, name); // Interpret the body of a nested ownedComment as a comment-type and assign it as the EAnnotation.source of the parent. // if (EMOFExtendedMetaData.EMOF_OWNED_COMMENT.equals(name) && objects.peekEObject() instanceof EAnnotation) { EAnnotation annotation = (EAnnotation)objects.peekEObject(); EObject container = annotation.eContainer(); if (container instanceof EAnnotation) { EAnnotation parentAnnotation = (EAnnotation)container; parentAnnotation.setSource(annotation.getDetails().get(EMOFExtendedMetaData.EMOF_COMMENT_BODY)); parentAnnotation.getEAnnotations().remove(annotation); } } }