--- Cedric Beust <[EMAIL PROTECTED]> wrote:
> > From: A mailing list for Enterprise JavaBeans
> development
> > [mailto:[EMAIL PROTECTED]]On Behalf Of Chris
> Harris
>
> > My question is this: since these methods are abstract,
> how
> > can I validate input coming in via a setXXX() method?
> Does
> > this approach mean I can no longer put logic in my
> entity
> > beans?
>
> Correct. The EJB 2.0 specification doesn't discuss any
> kind of interceptors for
> EJB's, which seems to be what you are looking for.
Cedric, Justin
I understand interceptors was one of the features "not
included in this release". I won't hold my breath for EJB
2.1 :-)
Validation in the value objects is something I had
considered but for my particular use-case wouldn't give me
any benefits (the validation is going to involve a remote
call if in the value object, or a local call if on the
server). I think for me Justin Couch's answer, of putting
validation calls directly into the remote, and logic into
bean class, would be better.
It's quite a big switch in the way of working - for EJB
1.1, the Bean class itself has most of the work in it and
the Remote is often nothing but an auto-generated view onto
the bean. For CMP 2.0 it seems that the Remote becomes much
more important and the Bean class becomes less so.
Thanks for your help.
c
__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".