mnemosyne.core
Class PersistentContext

java.lang.Object
  |
  +--mnemosyne.core.PersistentContext

public class PersistentContext
extends java.lang.Object

The persistent context is a thread local that holds information about the transactional state of the current thread. Method in this class are protected (they are only called from within the core package) to prevent direct manipulation of transactions and versions.

Version:
$Id: PersistentContext.java,v 1.1.1.1 2004/08/07 06:41:05 charlesblaxland Exp $
See Also:
ThreadLocal

Constructor Summary
protected PersistentContext(Version currentVersion)
           
 
Method Summary
static PersistentContext get(VersionManager versionMgr)
           
 Transaction getTransaction()
           
 Version getVersion()
           
 boolean isInTransaction()
           
static PersistentContext reset(VersionManager versionMgr)
           
 void setTransaction(Transaction currentTransaction)
           
 void setVersion(Version version)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PersistentContext

protected PersistentContext(Version currentVersion)
Method Detail

getVersion

public Version getVersion()

setVersion

public void setVersion(Version version)

getTransaction

public Transaction getTransaction()

isInTransaction

public boolean isInTransaction()

setTransaction

public void setTransaction(Transaction currentTransaction)

get

public static final PersistentContext get(VersionManager versionMgr)

reset

public static final PersistentContext reset(VersionManager versionMgr)


Copyright © 2004 Charles Blaxland. All Rights Reserved.