Thursday, March 19, 2009

Castor - Open Source data binding framework for Java

You can use Castor java library to process WSDL files.
First you neet to download Castor library from

WSDLFactory wsdlFactory = WSDLFactory.newInstance();
WSDLReader wsdlReader = wsdlFactory.newWSDLReader();

Definition definition = wsdlReader.readWSDL("C:/Temp/order.wsdl");
if (definition == null)
System.err.println("definition element is null");
Map servicesMap = definition.getServices();