Package net.sf.saxon.query

Examples of net.sf.saxon.query.QueryParser$Import


            if (result == null)
                result = defaultCase(theEObject);
            return result;
        }
        case Bpmn2Package.IMPORT: {
            Import import_ = (Import) theEObject;
            T result = caseImport(import_);
            if (result == null)
                result = defaultCase(theEObject);
            return result;
        }
View Full Code Here


            URI referencedURI = ImportHelper.makeURICanonical(referenced.getURI());

            Definitions importedDef = ImportHelper.getDefinitions(referenced);
            // only handle BPMN imports (with declared target namespace)
            if (importedDef != null && importedDef.getTargetNamespace() != null) {
                Import newImport = Bpmn2Factory.eINSTANCE.createImport();
                newImport.setImportType(NamespaceHelper.xmiToXsdNamespaceUri(Bpmn2Package.eNS_URI));
                newImport.setNamespace(importedDef.getTargetNamespace());
                // Counterpart: location.resolve(referencingURI) == referencedURI !
                newImport.setLocation(referencedURI.deresolve(referencingURI).toString());
                definitions.getImports().add(newImport);
            }
        }
    }
View Full Code Here

         */
        public URI getPathForPrefix(String prefix) {
            String ns = this.getNamespaceURI(prefix == null ? XMLConstants.DEFAULT_NS_PREFIX
                    : prefix);
            if (ns != null) {
                Import imp = ImportHelper.findImportForNamespace(getDefinitions(), ns);
                if (imp != null)
                    return URI.createURI(imp.getLocation()).resolve(
                            ImportHelper.makeURICanonical(getResource().getURI()));
                else {
                    return URI.createURI(ns);
                }
            }
View Full Code Here

            URI relativeToThis = referencedAbs.deresolve(thisAbs);
            if (relativeToThis.isEmpty())
                // reference to local element
                ns = getDefinitions().getTargetNamespace();
            else {
                Import impForRef = ImportHelper.findImportForLocation(getDefinitions(), referenced);
                if (impForRef != null)
                    ns = impForRef.getNamespace();
            }
            if (ns != null) {
                prefix = getPrefixDuringSave(ns);
            }
            return prefix;
View Full Code Here

     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->
     * @generated
     */
    public void setImport(Import newImport) {
        Import oldImport = import_;
        import_ = newImport;
        if (eNotificationRequired())
            eNotify(new ENotificationImpl(this, Notification.SET,
                    Bpmn2Package.ITEM_DEFINITION__IMPORT, oldImport, import_));
    }
View Full Code Here

                        ItemDefinition def = ((DataObject) child).getItemSubjectRef();
                        if (def != null) {
                            if (def.eResource() == null) {
                                ((Definitions) rootLevelProcess.eContainer()).getRootElements().add(0, def);
                            }
                            Import imported = def.getImport();
                            if (imported != null && imported.eResource() == null) {
                                ((Definitions) rootLevelProcess.eContainer()).getImports().add(0, imported);
                            }
                        }
                       
                    } else {
View Full Code Here

                ItemDefinition def = ((DataObject) node).getItemSubjectRef();
                if (def != null) {
                    if (def.eResource() == null) {
                        ((Definitions) process.eContainer()).getRootElements().add(0, ((DataObject) node).getItemSubjectRef());
                    }
                    Import imported = def.getImport();
                    if (imported != null && imported.eResource() == null) {
                        ((Definitions) process.eContainer()).getImports().add(0, ((DataObject) node).getItemSubjectRef().getImport());
                    }
                }
            }
        }
View Full Code Here

TOP

Related Classes of net.sf.saxon.query.QueryParser$Import

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.