On 7/26/06, Jacek Prucia <[EMAIL PROTECTED]> wrote:
Quite recently I found interesting feature in XML-RPC 3, but I'm not sure how to use it correctly. My XML-RPC service transforms an POJO into multilevel struct/array thing. Right now this involves manual build of Map's and List's, so they are correctly translated to standard XML-RPC data types. However, this as you might imagine is a bit annoying. Ideally, I would like to simply return object and have XML-RPC transform it into multilevel struct/array for me. It apears, that I just need to implement TypeSerializer interface. The question however remains: how to dynamically register it with XML-RPC server? Do I have to create my own TypeFactory implementation? If so, how to associate it with XmlRpcServer?
Yes, you have to derive a subclass of TypeFactoryImpl. See the org.apache.xmlrpc.jaxb package for an example. Your custom type factory must simply be configured with the respective property of XmlRpcClient or XmlRpcServer object. Jochen -- Whenever you find yourself on the side of the majority, it is time to pause and reflect. (Mark Twain) --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]