List<Header> headers = new ArrayList<Header>();
org.apache.helloWorldSoapHttpXmlbeans.xmlbeans.types.GreetMeDocument doc
= org.apache.helloWorldSoapHttpXmlbeans.xmlbeans.types.GreetMeDocument.Factory.newInstance();
doc.addNewGreetMe().setRequestType("doc format header");
Header head = new Header(new QName("", "doc"), doc,
client.getEndpoint().getService().getDataBinding());
headers.add(head);
org.apache.helloWorldSoapHttpXmlbeans.xmlbeans.types.GreetMeDocument.GreetMe gm
= org.apache.helloWorldSoapHttpXmlbeans.xmlbeans.types
.GreetMeDocument.GreetMe.Factory.newInstance();
gm.setRequestType("non-doc format header");
head = new Header(new QName("http://somenamespace.com", "nondocheader"), gm,
client.getEndpoint().getService().getDataBinding());
headers.add(head);
((BindingProvider)port).getRequestContext().put(Header.HEADER_LIST, headers);
String resp;