* @param nameSpaceMap - The namespaceMap
*/
public static void addHTTPHeaderElements(OMFactory omFactory, ArrayList list, OMNamespace whttp,
OMElement element, Map nameSpaceMap) {
for (int i = 0; i < list.size(); i++) {
HTTPHeaderMessage httpHeaderMessage = (HTTPHeaderMessage) list.get(i);
OMElement httpHeaderElement =
omFactory.createOMElement(WSDL2Constants.ATTRIBUTE_HEADER, whttp);
httpHeaderElement.addAttribute(omFactory.createOMAttribute(
WSDL2Constants.ATTRIBUTE_NAME, null, httpHeaderMessage.getName()));
QName qName = httpHeaderMessage.getqName();
httpHeaderElement.addAttribute(omFactory.createOMAttribute(
WSDL2Constants.ATTRIBUTE_TYPE, null,
getPrefix(qName.getNamespaceURI(), nameSpaceMap) + ":" + qName.getLocalPart()));
httpHeaderElement.addAttribute(omFactory.createOMAttribute(
WSDL2Constants.ATTRIBUTE_REQUIRED, null,
Boolean.valueOf(httpHeaderMessage.isRequired()).toString()));
element.addChild(httpHeaderElement);
}
}