Skip to main content

JAX-WS - Custom exception class not generated in wsdl...

No replies
petertaps
Offline
Joined: 2010-07-22
Points: 0

Folks,

Here is my simple case.

@WebFault
class MyException extends Exception {
...
public int getErrorNum() {...}
}

interface MyManagement {
String DoSomething() throws MyException;
}

class MyManagementImpl implements MyManagement {
....
}

static void main() {
EndPoint ep = EndPoint.create(new MyManagementImpl());
ep.publish("http://localhost:2000/");
}

When I browse to http://localhost:2000/?wsdl, I see the generated wsdl. The generated definition does mention:
...

However, there is no definition for the class "MyException" and the methods it contains (such as getErrorNum).

Can someone please tell me what else I need to do to generate proper wsdl for MyException as well?

Thank you in advance for your help.

Regards,
Peter