Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • 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 ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

EPractice Labs - Wrong answer????

 
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The following Question is in the Mock Exam-1 of EPractice Lab.

Q: Which of the following are valid methods of an entity bean?

Choices given:

ejbCreate()
ejbPostCreate()
ejbStore()
ejbRemove()
findByPrimaryKey()

Correct Answers(by EPractice) - ejbCreate(), ejbStore(), ejbRemove()

My Answer: ejbStore and ejbRemove.

If ejbCreate() is an valid ejb method of Entity bean, then all of the choices given are valid methods. Please correct me if I am wrong?


Thanks,
[ October 10, 2006: Message edited by: Makesh Kumar Ramakrishnan ]
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Could you please recheck the question with upper and lower cases?

Note that choice b is -->ejbPostcreate() not ejbPostCreate()

findByPrimaryKey() is part of home interface not bean class. Hence the choices A,C and D are correct.

~ Wlliam
 
Ranch Hand
Posts: 76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I agree with William. Howerever, the camelCase ejbPostCreate should be OK.
 
Makesh Kumar Ramakrishnan
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ejbCreate() is not part of EntityBean class. Please refer the Java API. But it's need to be defined in "implemented" entity bean class(ie.. Class implements EntityBean) for each create method in home interface.

Choice B is ejbPostCreate() - This method is not in EJBHome interface. But the "implemented" entity bean should have this method for each create method in Home interface.

findByPrimaryKey() is not part of EJBHome method. but it is mandatory to declare it in EJBHome of an entity bean.

Hence, ejbStore() and ejbRemove are the two correct choices for the given question. Please correct if I am wrong...


Thanks,
 
MyExamCloud Support
Posts: 264
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Makesh Kumar Ramakrishnan,

Please find the actual question (with proper cases)

Q: Which of the following are valid methods of an entity bean?

Choices given:

Choice A: ejbCreate()
Choice B: ejbPostcreate() (note that c is in small case)
Choice C: ejbStore()
Choice D: ejbRemove()
Choice E: findByPrimaryKey()

Choice A: ejbCreate() � correct
Choice B: ejbPostcreate() �incorrect, because c is in small case
Choice C: ejbStore() - correct
Choice D: ejbRemove()- correct
Choice E: findByPrimaryKey()-incorrect (not a EJB Bean class method)

Hence Choice A, Choice C and Choice D are correct answers.

Thanks for using SCEA Exam EPractize Labs for your preparation.

Please avoid posting direct questions from EPractize Labs in forums.

If you have any queries regading the contents feel free to contact our content support at scea1exam@epractizelabs.com or scea23exam@epractizelabs.com.
 
Makesh Kumar Ramakrishnan
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your reply Ganesan Ponnuswamy. I appologize for the direct Question post.
 
Ranch Hand
Posts: 208
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Makesh Kumar Ramakrishnan:
ejbCreate() is not part of EntityBean class. Please refer the Java API. But it's need to be defined in "implemented" entity bean class(ie.. Class implements EntityBean) for each create method in home interface.



ejbCreate is not part of the EntityBean interface. But, the question is not "methods defined by the EntityBean interface", it is "valid methods of an entity bean".
 
She said she got a brazillian. I think owning people is wrong. That is how I learned ... tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic