tags:

views:

19

answers:

1

Hi I'm trying to use EasyWSDL but I can't read any file from the filesystem.

WSDLReader reader = WSDLFactory.newInstance().newWSDLReader();
Description desc = reader.read(???????);

Any ideas?

A: 

The WSDLReader.reader method uses URL. So if a file has to be parsed this can be used:

WSDLReader reader = WSDLFactory.newInstance().newWSDLReader();
Description desc = reader.read(new URI("file:///"+(new File(fileName)).getAbsolutePath()).toURL());
Federico