Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- `
- String username = null;
- String password = null;
- messageFactory = MessageFactory.newInstance();
- input = httpRequest.getInputStream();
- soapMessage = messageFactory.createMessage(null,input);
- SOAPPart part = soapMessage.getSOAPPart();
- envelope = part.getEnvelope();
- header = envelope.getHeader();
- body = envelope.getBody();
- username= userIdNode.item(0).getChildNodes().item(0).getNodeValue();
- password= passwordNode.item(0).getChildNodes().item(0).getNodeValue();
- Authentication responseAuthentication = processUsernamePasswordAuthentication(httpResponse, username, password);
- if(responseAuthentication.isAuthenticated()){
- }`
- After here I have to make a call to my soap action. The interface is as follows :
- ` @WebMethod(operationName = "xxx", action = "YYYYY")
- @WebResult(name = "Reply", targetNamespace = "")
- @RequestWrapper(localName = "localname", targetNamespace = "", className = "")
- @ResponseWrapper(localName = "Response", targetNamespace = "", className = "")
- @Action(input = "input", output = "Response", fault = {
- @FaultAction(className = Fault_Exception.class, value = "Fault/Fault")
- })
- public Reply getDetails(
- @WebParam(name = "Request", targetNamespace = "")
- Request getDetailsRequest)throws Fault_Exception;`
Add Comment
Please, Sign In to add comment