Problem with publishing subclasses by AWS API specification


#1

Hi,

I’m quite new to Rails and have a problem with the use of AWS.

The Problem is, that I have a class which provides some basic attributes
and some subclasses of this with more specific attributes. I want to
send objects of those classes through SOAP by a remote client, but if I
specify just the base class in the method signature of my API definition
the generated WSDL file will just include the attributes of the base
class.

Is there any way to change this behavior? Because it is possible. The
Apache AXIS tools for example will generate a WSDL containing the class
inheritance so that remote callers are aware of this feature.

Thanks for your help.

Dirk


Here is an example of what I mean for better illustration:

class Shape < ActionWebService::Struct
member :color, :string
end

class Square < Shape
member :length, :int
end

class Circle < Shape
member :radius, :int
end

class Rectangle < Square
member :height, :int
end

class ShapeApi < ActionWebService::API::Base
api_method :store_shape,
:expects => [Shape]
end

WSDL:


<xsd:complexType name=“Shape”>
xsd:all
<xsd:element name=“color_id” type=“xsd:string”/>
</xsd:all>
</xsd:complexType>