Package javax.wsdl

Examples of javax.wsdl.Part


        if (input != null) {
            Message msg = input.getMessage();
            Iterator i = msg.getOrderedParts(null).iterator();
            while (i.hasNext()) {
                Part part = (Part) i.next();
                XmlSchemaType schemaType = null;
                schemaType = lookUpType(part, xmlSchemaList);
                if (part.getElementName() != null) {
                    // its an anonymous type
                    if (schemaType instanceof XmlSchemaComplexType
                            && schemaType.getName() == null) {
                        Iterator it = getSchemaIterator(schemaType);
                        Iterator iter = getSchemaIterator(schemaType);
                        addParams(wsdlToCorbaBinding, inputs, it, iter);
                    } else {
                        XmlSchemaElement el = getElement(part, xmlSchemaList);
                        if (schemaType == null) {
                            addParam(wsdlToCorbaBinding, schemaType, part
                                    .getName(), el.getSchemaTypeName(), el
                                    .isNillable(), inputs);
                        } else {
                            addParam(wsdlToCorbaBinding, schemaType, part
                                    .getName(), part.getElementName(), el
                                    .isNillable(), inputs);
                        }
                    }
                } else {
                    if (part.getTypeName() != null) {
                        addParam(wsdlToCorbaBinding, schemaType,
                                part.getName(), part.getTypeName(), false,
                                inputs);
                    }
                }
            }
        }
View Full Code Here


        if (input != null) {
            Message msg = input.getMessage();
            Iterator i = msg.getOrderedParts(null).iterator();
            while (i.hasNext()) {
                Part part = (Part) i.next();
                XmlSchemaType schemaType = null;
                schemaType = lookUpType(part, xmlSchemaList);
                if (part.getElementName() != null) {
                    XmlSchemaElement el = getElement(part, xmlSchemaList);
                    addParam(wsdlToCorbaBinding, schemaType, part.getName(),
                            part.getElementName(), el.isNillable(), inputs);
                } else if (part.getTypeName() != null) {
                    addParam(wsdlToCorbaBinding, schemaType, part.getName(),
                            part.getTypeName(), false, inputs);
                }
            }
        }
    }
View Full Code Here

        if (output != null) {
            Message msg = output.getMessage();
            Iterator i = msg.getOrderedParts(null).iterator();
            while (i.hasNext()) {
                Part part = (Part) i.next();
                XmlSchemaType schemaType = null;
                schemaType = lookUpType(part, xmlSchemaList);

                // check if in input list
                if (part.getElementName() != null) {
                    if (schemaType instanceof XmlSchemaComplexType
                            && schemaType.getName() == null) {
                        Iterator it = getSchemaIterator(schemaType);
                        Iterator iter = getSchemaIterator(schemaType);
                        updateLists(wsdlToCorbaBinding, inputs, outputs, it,
                                iter);
                    } else {
                        XmlSchemaElement el = getElement(part, xmlSchemaList);
                        if (schemaType == null) {
                            updateList(wsdlToCorbaBinding, schemaType, part
                                    .getName(), el.getSchemaTypeName(), inputs,
                                    outputs, el.isNillable());
                        } else {
                            updateList(wsdlToCorbaBinding, schemaType, part
                                    .getName(), part.getElementName(), inputs,
                                    outputs, el.isNillable());
                        }
                    }
                } else {
                    if (part.getTypeName() != null) {
                        updateList(wsdlToCorbaBinding, schemaType, part
                                .getName(), part.getTypeName(), inputs,
                                outputs, false);
                    }
                }
            }
        }
View Full Code Here

        if (output != null) {
            Message msg = output.getMessage();
            Iterator i = msg.getOrderedParts(null).iterator();
            while (i.hasNext()) {
                Part part = (Part) i.next();
                XmlSchemaType schemaType = null;
                schemaType = lookUpType(part, xmlSchemaList);

                // check if in input list
                String mode = "out";
                ParamType paramtype = null;
                for (int x = 0; x < inputs.size(); x++) {
                    paramtype = null;
                    ParamType d2 = (ParamType) inputs.get(x);

                    if (part.getName() != null
                            && d2.getName().equals(part.getName())) {
                        inputs.remove(x);
                        if (part.getElementName() != null) {
                            XmlSchemaElement el = getElement(part,
                                    xmlSchemaList);
                            paramtype = createParam(wsdlToCorbaBinding,
                                    "inout", schemaType, part.getName(), part
                                            .getElementName(), el.isNillable());
                        } else {
                            paramtype = createParam(wsdlToCorbaBinding,
                                    "inout", schemaType, part.getName(), part
                                            .getTypeName(), false);
                        }
                        inputs.add(paramtype);
                    }
                }
                if (paramtype == null) {
                    if (part.getElementName() != null) {
                        XmlSchemaElement el = getElement(part, xmlSchemaList);
                        paramtype = createParam(wsdlToCorbaBinding, mode,
                                schemaType, part.getName(), part
                                        .getElementName(), el.isNillable());
                    } else {
                        paramtype = createParam(wsdlToCorbaBinding, mode,
                                schemaType, part.getName(), part.getTypeName(),
                                false);
                    }
                    if (paramtype != null) {
                        outputs.add(paramtype);
                    }
View Full Code Here

            if (msg.getParts().size() == 0) {
                return false;
            }

            Part part = (Part) i.next();

            if (i.hasNext()) {
                return true;
            }

            schemaType = lookUpType(part, xmlSchemaList);
            if (!(part.getName().equals(opName))) {
                return true;
            }

            if (!(schemaType instanceof XmlSchemaComplexType)) {
                return true;
View Full Code Here

            if (msg.getParts().size() == 0) {
                return false;
            }

            Part part = (Part) i.next();

            if (i.hasNext()) {
                return true;
            }

            schemaType = lookUpType(part, xmlSchemaList);
            if (!part.getName().equals(opName)) {
                return true;
            }

            if (!(schemaType instanceof XmlSchemaComplexType)) {
                return true;
View Full Code Here

       
        return result;
    }
   
    private Message generateMessage(XmlSchemaElement element, String name) {
        Part part = definition.createPart();
        part.setName(PART_NAME);
        part.setElementName(element.getQName());
       
        Message result = definition.createMessage();
        result.setQName(new QName(definition.getTargetNamespace(), name));
        result.addPart(part);
        result.setUndefined(false);
View Full Code Here

        return msg;
    }
   
    private Part generateInputPart(Message inputMessage, XmlSchemaElement element) {
        // message - part
        Part part = definition.createPart();
        part.setName(IN_PARAMETER);
        part.setElementName(element.getQName());
        inputMessage.addPart(part);
        return part;       
    }
View Full Code Here

        return part;       
    }

    private Part generateOutputPart(Message outputMessage, XmlSchemaElement element) {
        // message - part
        Part part = definition.createPart();
        part.setName(OUT_PARAMETER);
        part.setElementName(element.getQName());
        outputMessage.addPart(part);
        return part;
    }
View Full Code Here

        Message faultMsg = definition.createMessage();
        faultMsg.setQName(new QName(definition.getTargetNamespace(), exceptionName));
        faultMsg.setUndefined(false);

        // message - part
        Part part = definition.createPart();
        part.setName("exception");
        // REVISIT: should be reading QName from exception XmlSchemaElement
        // part.setElementName(element.getQName());
        part.setElementName(new QName(definition.getTargetNamespace(), exceptionName));
        faultMsg.addPart(part);

        // porttype - operation - fault
        Fault fault = definition.createFault();
        fault.setMessage(faultMsg);
View Full Code Here

TOP

Related Classes of javax.wsdl.Part

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.