Examples of Part


Examples of javax.wsdl.Part

    private void generateFault(JavaMethod method, Operation operation) {
        for (org.objectweb.celtix.tools.common.model.WSDLException exception : method.getWSDLExceptions()) {
            String exceptionName = exception.getExcpetionClass().getSimpleName();
            Message msg = definition.createMessage();
            msg.setQName(new QName(wmodel.getTargetNameSpace(), exceptionName));
            Part part = definition.createPart();
            part.setName(exception.getDetailType().getSimpleName());
            part.setElementName(exception.getDetailTypeReference().tagName);
            msg.addPart(part);
            msg.setUndefined(false);
            definition.addMessage(msg);
            Fault fault = definition.createFault();
            fault.setMessage(msg);
View Full Code Here

Examples of javax.wsdl.Part

    private void addPartByElementName(Message message, String partName, QName partElementName) {
        if (partName == null) {
            return;
        }
        Part part = definition.createPart();
        part.setName(partName);
        part.setElementName(partElementName);
        message.addPart(part);
    }
View Full Code Here

Examples of javax.wsdl.Part

        part.setElementName(partElementName);
        message.addPart(part);
    }

    private void addPartByTypeName(Message message, String partName, QName typeName) {
        Part part = definition.createPart();
        part.setName(partName);
        part.setTypeName(typeName);
        message.addPart(part);
    }
View Full Code Here

Examples of javax.wsdl.Part

                Operation op = (Operation)it.next();
                Input input = op.getInput();
                if (input != null && input.getMessage() != null) {
                    Iterator itParts = input.getMessage().getParts().values().iterator();
                    while (itParts.hasNext()) {
                        Part part = (Part)itParts.next();
                        if (part.getTypeName() == null || "".equals(part.getTypeName().toString())) {
                            Message msg = new Message("RPC_PART_ILLEGAL", LOG, new Object[] {part.getName()});
                            throw new ToolException(msg);
                        }
                    }
                }
                Output output = op.getOutput();
                if (output != null && output.getMessage() != null) {
                    Iterator itParts = output.getMessage().getParts().values().iterator();
                    while (itParts.hasNext()) {
                        Part part = (Part)itParts.next();
                        if (part.getTypeName() == null || "".equals(part.getTypeName().toString())) {
                            Message msg = new Message("RPC_PART_ILLEGAL", LOG, new Object[] {part.getName()});
                            throw new ToolException(msg);
                        }
                    }
                }
            }
View Full Code Here

Examples of javax.wsdl.Part

        //
        // RULE No.2:
        // The input message part refers to a global element decalration whose localname
        // is equal to the operation name
        //
        Part inputPart = null;
        if (inputParts.size() == 1) {
            inputPart = inputParts.values().iterator().next();
            if (inputPart != null) {
                QName inputElement = inputPart.getElementName();
                if (inputElement == null) {
                    return false;
                } else if (!operation.getName().equals(inputElement.getLocalPart())) {
                    return false;
                }
            }
        }
        //
        // RULE No.3:
        // The output message part refers to a global element decalration
        //
        Part outputPart = null;
        if (outputParts.size() == 1) {
            outputPart = outputParts.values().iterator().next();
            if (outputPart != null) {
                QName outputElement = outputPart.getElementName();
                if (outputElement == null) {
                    return false;
                }
            }
        }
View Full Code Here

Examples of javax.wsdl.Part

        // RULE No.2:
        // The input message part refers to a global element decalration whose
        // localname
        // is equal to the operation name
        //
        Part inputPart = null;
        if (inputParts.size() == 1) {
            inputPart = inputParts.values().iterator().next();
            if (inputPart != null) {
                QName inputElement = inputPart.getElementName();
                if (inputElement == null) {
                    return false;
                } else if (!operation.getName().equals(inputElement.getLocalPart())) {
                    return false;
                }
            }
        }
        //
        // RULE No.3:
        // The output message part refers to a global element decalration
        //
        Part outputPart = null;
        if (outputParts.size() == 1) {
            outputPart = outputParts.values().iterator().next();
            if (outputPart != null) {
                QName outputElement = outputPart.getElementName();
                if (outputElement == null) {
                    return false;
                }
            }
        }
View Full Code Here

Examples of javax.wsdl.Part

            processInput(method, inputMessage);
            return;
        } else if (inputParts.isEmpty()) {
            return;
        }
        Part part = inputParts.iterator().next();

        List<? extends Property> block = ProcessorUtil.getBlock(part, env);
        if (block != null) {
            if (block.size() == 0) {
                // complete
View Full Code Here

Examples of javax.wsdl.Part

        // figure out output parts that are not present in input parts
        List<Part> outParts = new ArrayList<Part>();
        if (isRequestResponse) {

            for (Part outpart : outputParts) {
                Part inpart = inputPartsMap.get(outpart.getName());
                if (inpart == null) {
                    outParts.add(outpart);
                    continue;
                } else if (isSamePart(inpart, outpart)) {
                    addParameter(method, getParameterFromPart(method, outpart, JavaType.Style.INOUT));
View Full Code Here

Examples of javax.wsdl.Part

        if (inputPartsMap.size() > 1 || outputPartsMap.size() > 1) {
            processOutput(method, inputMessage, outputMessage, isRequestResponse);
            return;
        }

        Part inputPart = inputParts.iterator().next();
        Part outputPart = outputParts.iterator().next();
        List<? extends Property> inputBlock = ProcessorUtil.getBlock(inputPart, env);
        List<? extends Property> outputBlock = ProcessorUtil.getBlock(outputPart, env);

        if (outputBlock == null || outputBlock.size() == 0) {
            addVoidReturn(method);
View Full Code Here

Examples of javax.wsdl.Part

        }

        if (isRequestResponse) {
            for (Part part : outputParts) {
                if (!parameterList.contains(part.getName())) {
                    Part inpart = inputMessage.getPart(part.getName());
                    if (inpart == null || (inpart != null && !isSamePart(inpart, part))) {
                        outputUnlistedParts.add(part);
                    }
                }
            }

            if (outputUnlistedParts.size() == 1) {
                processReturn(method, outputUnlistedParts.get(0));
                outputPartsMap.remove(outputUnlistedParts.get(0));
                outputUnlistedParts.clear();
            } else {
                processReturn(method, null);
            }
        }

        // now create list of paramModel with parts
        // first for the ordered list
        int index = 0;
        int size = parameterList.size();
        while (index < size) {
            String partName = parameterList.get(index);
            Part part = inputPartsMap.get(partName);
            JavaType.Style style = JavaType.Style.IN;
            if (part == null) {
                part = outputPartsMap.get(partName);
                style = JavaType.Style.OUT;
            } else if (outputPartsMap.get(partName) != null
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.