I have a university project. And they told me to send Java Objects (for example a JFrame or a JLabel or a JButton) using Axis2 and POJOs. No RPC, no CORBA..
That one must rank among the worst abuses of a web service (if in fact you have to send swing objects). They probably got the idea from something like this: Creating a Web services data model for Swing widgets
More realistic would be an updated version of Using Apache Axis version 1 to build Web Services were you also replace the bean serialization and de-serialization mechanism with JAXB 2.0. If you want to spice it up, use Java WebStart to keep the Swing client current with the capabilities of the web service.
Would you mind telling the best way to send Java Objects using Java Web Services??? I am lost and Axis2 doen't work. I am thinking of reading a CORBA book but I am not sure if it is the right idea. Any help will be appreciated. Thank you!!!
I talked to my teacher and I told him that Axis2 doesn't work. He replied telling me to build the web services in any way possible. So I am free now to choose the API and / or the protocols needed. HELP!!!
What do you mean by "Axis2 doesn't work"? What did you try to do that it couldn't handle?
If you (or rather, your professor) is absolutely set on sending GUI objects over a WS, then one way to do it would be to serialize the object to a byte[], then base64-encode that (so you get an ASCII representation), and then send that as a string over the WS.
Another option would be to use the java.beans.XMLEncoder/XMLDecoder classes to produce an XML representation, and send that directly.