Hi Michael !

Yes, this is my case ! Exactly as you described. Could you give me
some information more on how to map it or how to try it in some way ?

What about the inheritance problems ?

Tks and regards,
Michel.

-----Mensagem original-----
De: michael simons [mailto:[EMAIL PROTECTED]
Enviada em: sexta-feira, 31 de outubro de 2003 17:53
Para: [EMAIL PROTECTED]
Assunto: Re: [castor-dev] Castor Mapping ...


At 08:40 31.10.2003 -0200, you wrote:
>Hi all !
>
>I have a kind of ecommerce and so it has an Order object. This object
>could have lots of itens stored in a collection property. My problem is
>that I can have different kinds of properties for my itens and so I cannot
>know the type of each item until I process it. In Java programming it's
>easy, but how can I map this using Castor ? Could you help me ?
>
>I have already read the documentation but I did not find any example or
>something to help me ( maybe it was not so clear to my eyes ).
>
>Any help would be very appreciated.
>
>Tks,
>Michel Bertrand.

Hi Michel,

I assume your model's somehow like this

class Order {
   private java.util.Collection  orderItems;
   ...
}

class OrderItem {
   private Order order;
}

class OrderSubItem_1 extends OrderItem {
...
}

class OrderSubItem_2 extends OrderItem {
...
}

The good news is You can do this with Castor.
The bad news is Castor's support of inheritance is insufficient.

Please let me know if You need more information.

Regards,
Michael

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to