How do you add a Soap Header defined in a wsdl to a web service client in CXF?
问题 I have a wsdl that defines a soap header that needs to be passed when calling the web service. The sample SOAP Header is: <soapenv:Header> <AuthenticationInfo> <userName>User</userName> <password/> </AuthenticationInfo> </soapenv:Header> CXF's wsdl2java generated an "AuthenticationInfo" java class that I can create and populate with a username and password, but I don't know the proper way to pass that to the CXF Client when calling the web service. 回答1: Well, the most simple way to do this