aspose file tools*
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes I have some doubts, anyone could me what's wrong Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "I have some doubts, anyone could me what Watch "I have some doubts, anyone could me what New topic
Author

I have some doubts, anyone could me what's wrong

Giovanni Zarc
Greenhorn

Joined: Dec 21, 2009
Posts: 5
Recently I bought a simulator test, but I found a couple questions where if is really the true answer:

1)A Department entity is in a one-to-many relationship withan Employee entity. A developer has been asked to write a Java Persistence query to update the set of employees who are in the departmen 'HR' by setting their department to null

Construct a query using Java PErsistence query language to perform this task.(this is a drag and dropp questions, each one should be drag and drop in the correct form)

____________ = long white space

Set ___________________e.department.name______('HR')
WHERE________________e.department____________=null
Employee e ____________UPDATE ____________ ___IN

the order of the answer simulator is that:

SET ___________________e.department___________________('HR')
=null ___________________Employee e___________________e.department.name
UPDATE___________________WHERE ___________________IN

I dont know which is the criteria for that question, anyone knows or give me an advice to understand if its correct or not? because I'm not sure that the answer above is the correct





Here it is another doubt, drag and drop too:
2)Place the ejb3.0 JMS Message-Driven class code snippets on their corresponding locations:

________________________________
public class BookingProcessorBean ___________________________
___________________________
//more code here...
}
}

the choices are:
@Stateless
@MessageDriven
@MDB
implements MessageDrivenBean{
implements BookingProccessorRemote{
implements MessageListener{
public void onMessage(Messasge message){
public static void onMessage(Messasge message){
public Message processMessage(Messasge message){


To me, the answer correct is:

@MessageDriven
public class BookingProcessorBean implements MessageListener{
public void onMessage(Messasge message){
//more code here...
}
}

but in the simulator is this one:

@Stateless
public class BookingProcessorBean @MDB
implements MessageListener{
//more code here...
}
}

The book ejb3 in action I didn't see anything about @MDB, or this is an special annotations?
Someone could me if the simulator is the correct answer or why my answer have a mistake?
thks
Jelle Victoor
Greenhorn

Joined: Feb 13, 2009
Posts: 5
The @MDB annotation does not exits, its not in the api. I think there are some bug's in your test exam...
Devaka Cooray
ExamLab Creator
Saloon Keeper

Joined: Jul 29, 2008
Posts: 2885
    
  13

Giovanni Ascarza wrote:Recently I bought a simulator test,...

Please QuoteYourSources


Author of ExamLab ExamLab - a free SCJP / OCPJP exam simulator
My Home Page -- Twitter Profile -- JavaRanch FAQ -- How to Ask a Question
 
Don't get me started about those stupid light bulbs.
 
subject: I have some doubts, anyone could me what's wrong
 
Similar Threads
accessing local session bean from a message driven bean
Strange behaviour of MDB and EJB
Setting JBoss JMS Queue size
com.ibm.ejs.container.EJBConfigurationException: NO_JCA_ADAPTER_BINDING found for MDB: ConsumerTest
MDB onMessage not invoked