Created
February 1, 2012 20:33
-
-
Save kartikshah/1719145 to your computer and use it in GitHub Desktop.
Jaxb Unmarshal at WSDL input parameter level
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class JaxbUnmarshallerMethodInput{ | |
public static void main(String args[]){ | |
try{ | |
JAXBContext jc = JAXBContext.newInstance("com.kartikshah.api.account.wsdl"); | |
Unmarshaller u = jc.createUnmarshaller(); | |
JAXBElement element = (JAXBElement)u.unmarshal(JaxbUnmarshallerMethodInput.class.getResource("query.xml")); | |
MethodInput methodInput = (MethodInput)element.getValue(); | |
Account account = methodInput.getAccount(); | |
ServiceContext context = methodInput.getServiceContext(); | |
} | |
catch (Exception e){ | |
// Removed for brevity | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment