if (header.isMustUnderstand()) { addAttribute(doc, "mustUnderstand", "true", param);
/** * Adds a soap header element to a given OMElement * @param omFactory - An OMFactory * @param list - The arraylist of soapHeaderMessages * @param wsoap - The WSDL 2.0 SOAP namespace * @param element - The element that the header should be added to * @param nameSpaceMap - The namespaceMap */ public static void addSOAPHeaderElements(OMFactory omFactory, ArrayList list, OMNamespace wsoap, OMElement element, Map nameSpaceMap) { for (int i = 0; i < list.size(); i++) { SOAPHeaderMessage soapHeaderMessage = (SOAPHeaderMessage) list.get(i); OMElement soapHeaderElement = omFactory.createOMElement(WSDL2Constants.ATTRIBUTE_HEADER, wsoap); QName qName = soapHeaderMessage.getElement(); soapHeaderElement.addAttribute(omFactory.createOMAttribute( WSDL2Constants.ATTRIBUTE_ELEMENT, null, getPrefix(qName.getNamespaceURI(), nameSpaceMap) + ":" + qName.getLocalPart())); soapHeaderElement.addAttribute(omFactory.createOMAttribute( WSDL2Constants.ATTRIBUTE_MUST_UNDERSTAND, null, Boolean.toString(soapHeaderMessage.isMustUnderstand()))); soapHeaderElement.addAttribute(omFactory.createOMAttribute( WSDL2Constants.ATTRIBUTE_REQUIRED, null, Boolean.toString(soapHeaderMessage.isRequired()))); element.addChild(soapHeaderElement); } }
/** * Adds a soap header element to a given OMElement * @param omFactory - An OMFactory * @param list - The arraylist of soapHeaderMessages * @param wsoap - The WSDL 2.0 SOAP namespace * @param element - The element that the header should be added to * @param nameSpaceMap - The namespaceMap */ public static void addSOAPHeaderElements(OMFactory omFactory, ArrayList list, OMNamespace wsoap, OMElement element, Map nameSpaceMap) { for (int i = 0; i < list.size(); i++) { SOAPHeaderMessage soapHeaderMessage = (SOAPHeaderMessage) list.get(i); OMElement soapHeaderElement = omFactory.createOMElement(WSDL2Constants.ATTRIBUTE_HEADER, wsoap); QName qName = soapHeaderMessage.getElement(); soapHeaderElement.addAttribute(omFactory.createOMAttribute( WSDL2Constants.ATTRIBUTE_ELEMENT, null, getPrefix(qName.getNamespaceURI(), nameSpaceMap) + ":" + qName.getLocalPart())); soapHeaderElement.addAttribute(omFactory.createOMAttribute( WSDL2Constants.ATTRIBUTE_MUST_UNDERSTAND, null, Boolean.toString(soapHeaderMessage.isMustUnderstand()))); soapHeaderElement.addAttribute(omFactory.createOMAttribute( WSDL2Constants.ATTRIBUTE_REQUIRED, null, Boolean.toString(soapHeaderMessage.isRequired()))); element.addChild(soapHeaderElement); } }
if (header.isMustUnderstand()) { addAttribute(doc, "mustUnderstand", "true", param);