aspose file tools*
The moose likes Web Services and the fly likes Returning an array with different classes inside Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Returning an array with different classes inside" Watch "Returning an array with different classes inside" New topic
Author

Returning an array with different classes inside

Peter Merker
Ranch Hand

Joined: Oct 18, 2003
Posts: 37
Hi,

I have a method which is returning an array of type BaseClass. Inside are objects of different SubClasses. The SOAP message generated by Axis 1.3 treats the objects in the array as if they were all of type BaseClass, but I need the attributes from the SubClasses, which are really inside the array.
Is there a way to do this somehow, either with Axis 1.3, another version, or another Web Services Library?
If this is not implemented yet, is it possible to fix the Axis code? In this case, where could this be done?

Thanks in advance for your help.
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12806
    
    5
I think you are trying to push SOAP well beyond what it is designed for. You should try to come up with a way to transfer the information using standard SOAP concepts.

For example can you reduce the specialized class attributes to a Map?

Bill
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Returning an array with different classes inside