FileDocCategorySizeDatePackage
PersistentNonTransactional.javaAPI DocGlassfish v2 API4278Fri May 04 22:35:16 BST 2007com.sun.jdo.spi.persistence.support.sqlstore.state

PersistentNonTransactional

public class PersistentNonTransactional extends LifeCycleState

Fields Summary
private static final ResourceBundle
messages
I18N message handler
Constructors Summary
public PersistentNonTransactional()


      
        // these flags are set only in the constructor
        // and shouldn't be changed afterwards
        // (cannot make them final since they are declared in superclass
        // but their values are specific to subclasses)
        isPersistent = true;
        isPersistentInDataStore = true;
        isTransactional = false;
        isDirty = false;
        isNew = false;
        isDeleted = false;
        isNavigable = true;
        isRefreshable = false;
        isBeforeImageUpdatable = false;
        needsRegister = false;
        needsReload = false;
        needsRestoreOnRollback = false;
        updateAction = ActionDesc.LOG_NOOP;
        stateType = P_NON_TX;
    
Methods Summary
public booleanneedsReload(boolean optimistic, boolean nontransactionalRead, boolean transactionActive)

        //
        // Don't allow reload if the transaction is optimistic or not active
        //
        if (optimistic || !transactionActive) {
            return false;
        }

        return true;
    
public LifeCycleStatetransitionDeletePersistent()
Operations that cause life cycle state transitions

        return changeState(P_DELETED);
    
public LifeCycleStatetransitionReload(boolean transactionActive)

        if (!transactionActive) {
            return this;
        } else {
            return changeState(P_CLEAN);
        }
    
public LifeCycleStatetransitionWriteField(boolean transactionActive)

        if (transactionActive) {
            return changeState(P_DIRTY);
        } else {
            return this;
        }