| java.lang.Object org.objectweb.jonas_ejb.container.JEntitySwitch org.objectweb.jonas_ejb.container.JEntitySwitchCST org.objectweb.jonas_ejb.container.JEntitySwitchCRW
JEntitySwitchCRW | public class JEntitySwitchCRW extends JEntitySwitchCST (Code) | | Container Optimistic lock-policy.
Only 1 thread can write. All other threads can read, without
waiting for a committed state. There is no wait.
This policy cannot be used with shared=true.
This policy is only possible for CMP2 entitybeans.
author: Philippe Durieux |
JEntitySwitchCRW | public JEntitySwitchCRW()(Code) | | empty constructor. Object is initialized via init() because it is
implemented differently according to jorm mappers.
|
mapICtx | public synchronized JEntityContext mapICtx(Transaction tx, JEntityContext bctx, boolean forced, boolean holdit, boolean notused)(Code) | | Map a context and its instance.
Could use the inherited method here. This is just a simplified
version for performances.
Parameters: tx - - the Transaction object Parameters: bctx - - the JEntityContext to bind if not null Parameters: forced - - force to take this context. (case of create) Parameters: holdit - - increment count to hold it, a release will be calledlater. JEntityContext actually mapped |
waitmyturn | public void waitmyturn(Transaction tx)(Code) | | Wait until I'm allowed to work on this instance.
Transaction isolation may be done here, depending on lock-policy.
Parameters: tx - Transaction |
Methods inherited from org.objectweb.jonas_ejb.container.JEntitySwitch | public void bindICtx(Transaction tx, JEntityContext bctx)(Code)(Java Doc) protected void detachPk()(Code)(Java Doc) protected void discardContext(Transaction tx, boolean forgetpk, boolean pool)(Code)(Java Doc) abstract public void endIH()(Code)(Java Doc) public synchronized void forceDiscardICtx(Transaction tx)(Code)(Java Doc) public JFactory getBeanFactory()(Code)(Java Doc) public Transaction getBlockingTx(Transaction testedtx)(Code)(Java Doc) abstract JEntityContext getContext4Tx(Transaction tx)(Code)(Java Doc) public TimerService getEntityTimerService()(Code)(Java Doc) public JEntityContext getICtx(Transaction tx, JEntityContext newctx)(Code)(Java Doc) public JEntityContext getICtx(Transaction tx, boolean checkr)(Code)(Java Doc) public JEntityLocal getLocal()(Code)(Java Doc) public int getPolicy()(Code)(Java Doc) public Object getPrimaryKey()(Code)(Java Doc) public JEntityRemote getRemote()(Code)(Java Doc) abstract public int getState()(Code)(Java Doc) public void init(JEntityFactory bf, Object pk)(Code)(Java Doc) abstract protected void initpolicy(JEntityFactory bf)(Code)(Java Doc) public boolean lazyRegistering()(Code)(Java Doc) public synchronized JEntityContext mapICtx(Transaction tx, JEntityContext bctx, boolean forced, boolean holdit, boolean checkreentrance)(Code)(Java Doc) public void notifyTimeout(Timer timer)(Code)(Java Doc) public synchronized void notifyWriting(Transaction tx, JEntityContext bctx)(Code)(Java Doc) abstract public int passivateIH(boolean store, boolean passivate)(Code)(Java Doc) protected void registerCtx(Transaction tx, JEntityContext bctx)(Code)(Java Doc) public synchronized void releaseICtx(Transaction tx, boolean discard)(Code)(Java Doc) abstract void removeContext4Tx(Transaction tx)(Code)(Java Doc) abstract void setContext4Tx(Transaction tx, JEntityContext ctx)(Code)(Java Doc) public synchronized boolean terminate(Transaction tx)(Code)(Java Doc) public synchronized boolean tryBindICtx(Transaction tx, JEntityContext bctx, boolean simple) throws ObjectNotFoundException(Code)(Java Doc) public synchronized void txCompleted(Transaction tx, boolean committed)(Code)(Java Doc) abstract void waitmyturn(Transaction tx)(Code)(Java Doc)
|
|
|