views:

5

answers:

0

Imagine a SOAP RPC method getBill that returns an instance of this class:

class Bill:
    customer = String
    total = Double

Now, assume that the Bill class and the getBill method are defined in two different namespaces, foo:getBill and bar:Bill

What should be the namespace of the accessor element of the response message? The namespace of the class, like this:

<foo:getBillResponse>
    <bar:retval>
        <customer>Mr. Bill</customer>
        <total>100.0</total>
    </bar:retval>
</foo:getBillResponse>

or, the namespace of the method, like this:

<foo:getBillResponse>
    <foo:retval>
        <customer>Mr. Bill</customer>
        <total>100.0</total>
    </foo:retval>
</foo:getBillResponse>

Furthermore, if there is a nested class that contains items in the bill class:

class BillItem:
    name = String
    price = Double

class Bill:
    items = BillItem[]

and the Bill class contains a field that is a list of items. Should the items element that contains the items have the namespace of the Bill class, or the BillItem class?