Package javax.wsdl.extensions.schema

Examples of javax.wsdl.extensions.schema.Schema


            final String serviceName = serviceClass.getSimpleName();
            final Element operationElement = getElementByAttribute(
                    definition,
                    NAME,
                    operationName);
            final Schema operationSchema = Axis2ClientUtils.getElementSchemaByAttribute(
                    definition,
                    NAME,
                    operationName);
            if (operationSchema != null)
            {
View Full Code Here


        final Collection<Object> evaluatingBeans)
    {
        final String componentElementName = componentElement != null ? componentElement.getAttribute(NAME) : null;
        if (StringUtils.isNotBlank(componentElementName))
        {
            final Schema currentSchema = Axis2ClientUtils.getElementSchemaByAttribute(
                    definition,
                    NAME,
                    componentElementName);
            if (currentSchema != null)
            {
View Full Code Here

            for (final Iterator iterator = elements.iterator(); iterator.hasNext();)
            {
                final Object object = iterator.next();
                if (object instanceof Schema)
                {
                    final Schema schema = (Schema)object;
                    element =
                        getElementByAttribute(
                            schema.getElement(),
                            attribute,
                            value);
                    if (element != null)
                    {
                        break;
View Full Code Here

        final String attribute,
        final String value)
    {
        final Types types = definition.getTypes();
        final Collection elements = types.getExtensibilityElements();
        Schema schema = null;
        for (final Iterator iterator = elements.iterator(); iterator.hasNext();)
        {
            final Object object = iterator.next();
            if (object instanceof Schema)
            {
View Full Code Here

        }

        Types types = definition.createTypes();

        try {
            Schema schema;

            schema = (Schema)extensionRegistry.createExtension(Types.class,
                                                               new QName("http://www.w3.org/2001/XMLSchema",
                                                                         "schema"));

            DocumentBuilder docBuilder;
            docBuilder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
            Document doc = docBuilder.newDocument();
            Element element = doc.createElement("xsd:schema");
            Map<String, String> schemafileMap = wmodel.getSchemaNSFileMap();

            Set<Map.Entry<String, String>> entryset = schemafileMap.entrySet();
            Iterator<Map.Entry<String, String>> ite = entryset.iterator();
            while (ite.hasNext()) {
                Map.Entry<String, String> entry = (Map.Entry<String, String>)ite.next();
                Element importelement = doc.createElement("xsd:import");
                importelement.setAttribute("namespace", entry.getKey());
                importelement.setAttribute("schemaLocation", entry.getValue());
                element.appendChild(importelement);
            }
            schema.setElement(element);
            types.addExtensibilityElement(schema);
            definition.setTypes(types);
        } catch (Exception e) {
            throw new ToolException(msg, e);
        }
View Full Code Here

        if (typesElement != null) {
            Iterator ite = typesElement.getExtensibilityElements().iterator();
            while (ite.hasNext()) {
                Object obj = ite.next();
                if (obj instanceof Schema) {
                    Schema schema = (Schema)obj;
                    addSchema(schema);
                }
            }
        }
    }
View Full Code Here

            Collection<String> importKeys = imports.keySet();
            for (String importNamespace : importKeys) {
                if (!isSchemaParsed(importNamespace + "?file=" + schema.getDocumentBaseURI())) {
                    List<SchemaImport> schemaImports = imports.get(importNamespace);
                    for (SchemaImport schemaImport : schemaImports) {
                        Schema tempImport = schemaImport.getReferencedSchema();
                        if (tempImport != null && !isSchemaImported(tempImport)) {
                            addSchema(tempImport);
                        }
                    }
                }
View Full Code Here

        if (types != null) {
            List schemas = types.getExtensibilityElements();
            for (Iterator iterator = schemas.iterator(); iterator.hasNext();) {
                Object o = iterator.next();
                if (o instanceof Schema) {
                    Schema unknownExtensibilityElement = (Schema) o;
                    QName elementType = unknownExtensibilityElement.getElementType();
                    if (new QName("http://www.w3.org/2001/XMLSchema", "schema").equals(elementType)) {
                        Element element = unknownExtensibilityElement.getElement();
                        addSchemaElement(element, namespaceMap, schemaList);
                    }
                } else if (o instanceof UnknownExtensibilityElement) {
                    //This is allegedly obsolete as of axis-wsdl4j-1.2-RC3.jar which includes the Schema extension above.
                    //The change notes imply that imported schemas should end up in Schema elements.  They don't, so this is still needed.
                    UnknownExtensibilityElement unknownExtensibilityElement = (UnknownExtensibilityElement) o;
                    Element element = unknownExtensibilityElement.getElement();
                    String elementNamespace = element.getNamespaceURI();
                    String elementLocalName = element.getNodeName();
                    if ("http://www.w3.org/2001/XMLSchema".equals(elementNamespace) && "schema".equals(elementLocalName)) {
                        addSchemaElement(element, namespaceMap, schemaList);
                    }
View Full Code Here

            Iterator ite = typesElement.getExtensibilityElements().iterator();
            while (ite.hasNext()) {
                Object obj = ite.next();
                org.w3c.dom.Element schemaElem = null;
                if (obj instanceof Schema) {
                    Schema schema = (Schema) obj;
                    addSchema(schema);
                    schemaElem = schema.getElement();
                } else if (obj instanceof UnknownExtensibilityElement) {
                    org.w3c.dom.Element elem = ((UnknownExtensibilityElement) obj).getElement();
                    if (elem.getLocalName().equals("schema")) {
                        schemaElem = elem;
                    }
View Full Code Here

            Collection<String> importKeys = imports.keySet();
            for (String importNamespace : importKeys) {
                if (!isSchemaParsed(importNamespace + "?file=" + schema.getDocumentBaseURI())) {
                    List<SchemaImport> schemaImports = imports.get(importNamespace);
                    for (SchemaImport schemaImport : schemaImports) {
                        Schema tempImport = schemaImport.getReferencedSchema();
                        if (tempImport != null && !isSchemaImported(tempImport)) {
                            addSchema(tempImport);
                        }
                    }
                }
View Full Code Here

TOP

Related Classes of javax.wsdl.extensions.schema.Schema

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.