|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ow2.easybeans.examples.statefulbean.StatefulBean
public class StatefulBean
Simple stateful bean.
Constructor Summary | |
---|---|
StatefulBean()
Initialize the amounts for with and without Tx. |
Method Summary | |
---|---|
void |
afterBegin()
The afterBegin method notifies a session Bean instance that a new transaction has started, and that the subsequent business methods on the instance will be invoked in the context of the transaction. |
void |
afterCompletion(boolean committed)
The afterCompletion method notifies a session Bean instance that a transaction commit protocol has completed, and tells the instance whether the transaction has been committed or rolled back. |
void |
beforeCompletion()
The beforeCompletion method notifies a session Bean instance that a transaction is about to be committed. |
void |
buy(int s)
Business method implementation. |
int |
read()
Business method implementation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StatefulBean()
Method Detail |
---|
public void afterBegin() throws java.rmi.RemoteException
afterBegin
in interface SessionSynchronization
java.rmi.RemoteException
- - This exception is defined in the
method signature to provide backward compatibility for enterprise
beans written for the EJB 1.0 specification. Enterprise beans
written for the EJB 1.1 and higher specifications should throw
the javax.ejb.EJBException instead of this exception. Enterprise
beans written for the EJB 2.0 and higher specifications must not
throw the java.rmi.RemoteException.public void beforeCompletion() throws java.rmi.RemoteException
beforeCompletion
in interface SessionSynchronization
java.rmi.RemoteException
- - This exception is defined in the
method signature to provide backward compatibility for enterprise
beans written for the EJB 1.0 specification. Enterprise beans
written for the EJB 1.1 and higher specifications should throw
the javax.ejb.EJBException instead of this exception. Enterprise
beans written for the EJB 2.0 and higher specifications must not
throw the java.rmi.RemoteException.public void afterCompletion(boolean committed) throws java.rmi.RemoteException
afterCompletion
in interface SessionSynchronization
committed
- - True if the transaction has been committed, false if
is has been rolled back.
java.rmi.RemoteException
- - This exception is defined in the
method signature to provide backward compatibility for enterprise
beans written for the EJB 1.0 specification. Enterprise beans
written for the EJB 1.1 and higher specifications should throw
the javax.ejb.EJBException instead of this exception. Enterprise
beans written for the EJB 2.0 and higher specifications must not
throw the java.rmi.RemoteException.public void buy(int s)
buy
in interface StatefulRemote
s
- nb of shares to be boughtpublic int read()
read
in interface StatefulRemote
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |