Urgent EJB help
Hello Java Gurus,
i have some questions, please some help :)
1. What is the difference between ejbCreate() found in the Bean class & the create() method found in the Home object. (Is there a difference in functionality ? )
2. I hear some developers say the "EJB class", do they mean the Bean class ?
3. SessionContext , can we use it to get & set attributes as the regular Session object that we create in a servlet or in a jsp ? Or is there a difference
Thanks in advance :)
[524 byte] By [
basharfa] at [2007-11-26 16:39:39]

# 1
> Hello Java Gurus,
>
> i have some questions, please some help :)
>
> 1. What is the difference between ejbCreate() found
> in the Bean class & the create() method found in
> the Home object. (Is there a difference in
> functionality ? )
The Home.create() is the client-visible API. ejbCreate is the implementation
of that method on the bean class which is invoked by the ejb container.
>
> 2. I hear some developers say the "EJB class", do
> they mean the Bean class ?
Yes.
>
> 3. SessionContext , can we use it to get & set
> attributes as the regular Session object that we
> create in a servlet or in a jsp ? Or is there a
> difference
No, SessionContext is a special object only usable within a session bean.
It's a special API between the bean class code and the ejb container.
E.g. if a bean uses container-managed transactions it can set the
transaction for rollback-only using SessionContext.
--ken
>
> Thanks in advance :)