问题描述
Whichofthefollowingstatementsregardingthelifecycleofasessionbeanarecorrect? 1.java.lang.IllegalStateExceptionisthrownifSessionContext.getEJBObject()isinvokedwhenastatefulsessionbeaninstanceispassivated. 2.SessionContext.getRollbackOnly()doesnotthrowanexceptionwhenasessionbeanwithbean-managedtransactiondemarcationisactivated. 3.AnexceptionisnotthrownwhenSessionContext.getUserTransaction()iscalledintheafterBeginmethodofabeanwithcontainer-managedtransactions. 4.JNDIaccesstojava:comp/envispermittedinalltheSessionSynchronizationmethodsofastatefulsessionbeanwithcontainer-managedtransactiondemarcation. 5.AccessingresourcemanagersintheSessionSynchronization.afterBeginmethodofastatefulsessionbeanwithbean-managedtransactiondoesnotthrowanexception.该选择哪一个呢