• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Bear Bibeault
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Jj Roberts
  • Tim Holloway
  • Piet Souris
  • Himai Minh
  • Carey Brown
  • salvin francis

regardin ejbCreate()

Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all,
i have a doubt, no where in the enterprisebean/entity bean/session bean interface we find ejbCreate() method declaration even then the implementation of ejbcreate() is a must in the bean class why is it so?and where is this ejbcreate method present?
ok then thanks in advance
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ejbCreate() methods are similar to the constructors written by the Enterprise bean developer.
According to EJB 2.1 Specification, the session bean class must implement one or more ejbCreate() methods that corresponds to the create() method specified in the home interface. The method signature of ejbCreate() must follow rules such as
Method must be declared as public
Method must not be declared as final or static and so on�
More information can be obtained from EJB 2.1 Specification.
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
there's two ways that standarts can be made
1. using framworks
2. by contacts
in java pure java the way is with framworks using interfaces ,abstarcts classes and other utilities.
in j2ee it's with contacts(the specifications).
because j2ee is a java oriented parts of the standarts are using java style(interfaces) and parts are with contacts.
the ejbCreate methods are stadarts that uses contracts , you won't find this method in any interface , but the development tool(on asembly time) in validation time will check if you defined the ejbCreate methods(and the postCreate also). if you'll think about it there's no way you can define ejbCreate with interface because it's the bean provider decision witch "constractors" he want's to write !!
hope it helps you
Enjoy the full beauty of the english language. Embedded in this tiny ad:
Thread Boost feature
    Bookmark Topic Watch Topic
  • New Topic