Hi. I'm facing several choices implementing entitybeans relationships in my application. I'll use two entitybeans, A and B, with a directed 1/1 relation from A to B, and one sessionbean C for accessing both ot them. APK and BPK are primary keys classes for A and B. For correct OO design, i assume it is more correct to have in A ejbCreate(B myB) rather than ejbCreate(BPK myBPK). But in a web client application, i can only use keys (strings or numeric) for forms data transmission. So, where is the best for converting keys to objects, in the client, or in the session bean used for accessing my entity beans ? In both case, i'll have to perform a home interface lookup for the key. But maybe it is costless within the EJB server rather from outside, so preferring the session bean solution. But in the same time, i dislike having get() methods that return objects, and set() methods that use keys. The same can also apply for find methods. If i have for A a findByB method(), i also prefer to have findByB(B myB) than findByB(BPK myBPK). Again, i'll have to translate somewhere the B key i'll retrieve from the client form... That's all for tonight :-) -- Guillaume Rousse Iremia - Universit� de la R�union Sleep doesn't exists. Just lack of cafeine. ---- To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "unsubscribe jonas-users". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".
