java.lang.Object
java.io.OutputStream
de.grogra.util.OutputQueue
de.grogra.util.HierarchicalQueue
de.grogra.persistence.XAQueue
de.grogra.persistence.Transaction
- All Implemented Interfaces:
PersistenceOutput,Closeable,DataOutput,Flushable,ObjectOutput,AutoCloseable
- Direct Known Subclasses:
GraphTransaction
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfacestatic final classstatic interfacestatic final classclassNested classes/interfaces inherited from class de.grogra.util.HierarchicalQueue
HierarchicalQueue.Cursor -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class de.grogra.util.HierarchicalQueue
BEGIN_LEVEL, IS_FINISHED, ITEM_AND_BITS_MASK, ITEM_MASK, MAX_UNUSED_BIT, MIN_UNUSED_BIT, NEXT_EXISTS, out -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbegin(boolean readOnly) voidvoidclose()voidcommit()final voidprotected Transaction.Dataabstract Transaction.ReadervoidendApply()voidvoidfinishSet(XAQueue.Reader reader) voidfireSharedObjectModified(Shareable object) intfinal longgetId()final Transaction.KeygetKey()final longbooleanbooleanisActive()static booleanprotected booleanbooleanisModified(Object object, PersistenceField field, int[] indices) static booleanvoidlogInsertBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean newValue) voidlogInsertByte(PersistenceCapable o, PersistenceField field, int[] indices, byte newValue) voidlogInsertChar(PersistenceCapable o, PersistenceField field, int[] indices, char newValue) voidlogInsertDouble(PersistenceCapable o, PersistenceField field, int[] indices, double newValue) voidlogInsertFloat(PersistenceCapable o, PersistenceField field, int[] indices, float newValue) voidlogInsertInt(PersistenceCapable o, PersistenceField field, int[] indices, int newValue) voidlogInsertLong(PersistenceCapable o, PersistenceField field, int[] indices, long newValue) voidlogInsertObject(PersistenceCapable o, PersistenceField field, int[] indices, Object newValue) voidlogInsertShort(PersistenceCapable o, PersistenceField field, int[] indices, short newValue) voidvoidvoidlogReadData(PersistenceCapable o, boolean onRollback) voidvoidlogRemoveBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean oldValue) voidlogRemoveByte(PersistenceCapable o, PersistenceField field, int[] indices, byte oldValue) voidlogRemoveChar(PersistenceCapable o, PersistenceField field, int[] indices, char oldValue) voidlogRemoveDouble(PersistenceCapable o, PersistenceField field, int[] indices, double oldValue) voidlogRemoveFloat(PersistenceCapable o, PersistenceField field, int[] indices, float oldValue) voidlogRemoveInt(PersistenceCapable o, PersistenceField field, int[] indices, int oldValue) voidlogRemoveLong(PersistenceCapable o, PersistenceField field, int[] indices, long oldValue) voidlogRemoveObject(PersistenceCapable o, PersistenceField field, int[] indices, Object oldValue) voidlogRemoveShort(PersistenceCapable o, PersistenceField field, int[] indices, short oldValue) voidlogSetBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean oldValue, boolean newValue) voidlogSetByte(PersistenceCapable o, PersistenceField field, int[] indices, byte oldValue, byte newValue) voidlogSetChar(PersistenceCapable o, PersistenceField field, int[] indices, char oldValue, char newValue) voidlogSetDouble(PersistenceCapable o, PersistenceField field, int[] indices, double oldValue, double newValue) voidlogSetFloat(PersistenceCapable o, PersistenceField field, int[] indices, float oldValue, float newValue) voidlogSetInt(PersistenceCapable o, PersistenceField field, int[] indices, int oldValue, int newValue) voidlogSetLong(PersistenceCapable o, PersistenceField field, int[] indices, long oldValue, long newValue) voidlogSetObject(PersistenceCapable o, PersistenceField field, int[] indices, Object oldValue, Object newValue) voidlogSetShort(PersistenceCapable o, PersistenceField field, int[] indices, short oldValue, short newValue) voidvoidmarkModified(Object object, PersistenceField field, int[] indices) voidprepareLogSetBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean oldValue) voidprepareLogSetByte(PersistenceCapable o, PersistenceField field, int[] indices, byte oldValue) voidprepareLogSetChar(PersistenceCapable o, PersistenceField field, int[] indices, char oldValue) voidprepareLogSetDouble(PersistenceCapable o, PersistenceField field, int[] indices, double oldValue) voidprepareLogSetFloat(PersistenceCapable o, PersistenceField field, int[] indices, float oldValue) voidprepareLogSetInt(PersistenceCapable o, PersistenceField field, int[] indices, int oldValue) voidprepareLogSetLong(PersistenceCapable o, PersistenceField field, int[] indices, long oldValue) voidprepareLogSetObject(PersistenceCapable o, PersistenceField field, int[] indices, Object oldValue) voidprepareLogSetShort(PersistenceCapable o, PersistenceField field, int[] indices, short oldValue) voidprepareSetBoolean(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetByte(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetChar(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetDouble(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetFloat(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetInt(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetLong(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetObject(PersistenceCapable pc, PersistenceField field, int[] indices) voidprepareSetShort(PersistenceCapable pc, PersistenceField field, int[] indices) final voidvoidvoidrollback()final voidprotected voidfinal voidfinal voidsetUserId(long userId) final voidvoidMethods inherited from class de.grogra.persistence.XAQueue
beginArray, beginField, beginFields, beginManaged, clear, endArray, endField, endFields, endManaged, getPersistenceManager, setNested, writeComponentSeparator, writeLibraryObjectReference, writeName, writeNullObject, writeObject, writePersistentObjectReference, writeSharedObjectReference, writeString, writeStringObjectMethods inherited from class de.grogra.util.HierarchicalQueue
beginLevel, beginSkipBlock, cloneData, discardLevel, endLevel, endSkipBlock, getCursor, getData, hasItems, hasItemsInCurrentLevel, moveTo, setItemSize, writeItem, writeObject, writeObjectInStreamMethods inherited from class de.grogra.util.OutputQueue
dump, flush, write, write, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeObjectInQueue, writeShort, writeUTFMethods inherited from class java.io.OutputStream
nullOutputStreamMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.io.DataOutput
writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTFMethods inherited from interface java.io.ObjectOutput
flush, write, write, writeMethods inherited from interface de.grogra.persistence.PersistenceOutput
writeBoolean, writeByte, writeChar, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeStatic
-
Field Details
-
SET_BOOLEAN
public static final int SET_BOOLEAN- See Also:
-
INSERT_BOOLEAN
public static final int INSERT_BOOLEAN- See Also:
-
REMOVE_BOOLEAN
public static final int REMOVE_BOOLEAN- See Also:
-
SET_BYTE
public static final int SET_BYTE- See Also:
-
INSERT_BYTE
public static final int INSERT_BYTE- See Also:
-
REMOVE_BYTE
public static final int REMOVE_BYTE- See Also:
-
SET_SHORT
public static final int SET_SHORT- See Also:
-
INSERT_SHORT
public static final int INSERT_SHORT- See Also:
-
REMOVE_SHORT
public static final int REMOVE_SHORT- See Also:
-
SET_CHAR
public static final int SET_CHAR- See Also:
-
INSERT_CHAR
public static final int INSERT_CHAR- See Also:
-
REMOVE_CHAR
public static final int REMOVE_CHAR- See Also:
-
SET_INT
public static final int SET_INT- See Also:
-
INSERT_INT
public static final int INSERT_INT- See Also:
-
REMOVE_INT
public static final int REMOVE_INT- See Also:
-
SET_LONG
public static final int SET_LONG- See Also:
-
INSERT_LONG
public static final int INSERT_LONG- See Also:
-
REMOVE_LONG
public static final int REMOVE_LONG- See Also:
-
SET_FLOAT
public static final int SET_FLOAT- See Also:
-
INSERT_FLOAT
public static final int INSERT_FLOAT- See Also:
-
REMOVE_FLOAT
public static final int REMOVE_FLOAT- See Also:
-
SET_DOUBLE
public static final int SET_DOUBLE- See Also:
-
INSERT_DOUBLE
public static final int INSERT_DOUBLE- See Also:
-
REMOVE_DOUBLE
public static final int REMOVE_DOUBLE- See Also:
-
SET_OBJECT
public static final int SET_OBJECT- See Also:
-
INSERT_OBJECT
public static final int INSERT_OBJECT- See Also:
-
REMOVE_OBJECT
public static final int REMOVE_OBJECT- See Also:
-
UNDO_TRANSACTION
public static final int UNDO_TRANSACTION- See Also:
-
REDO_TRANSACTION
public static final int REDO_TRANSACTION- See Also:
-
MAKE_PERSISTENT
public static final int MAKE_PERSISTENT- See Also:
-
MAKE_TRANSIENT
public static final int MAKE_TRANSIENT- See Also:
-
READ_DATA
public static final int READ_DATA- See Also:
-
MIN_UNUSED_ITEM
public static final int MIN_UNUSED_ITEM- See Also:
-
-
Constructor Details
-
Transaction
-
-
Method Details
-
createData
- Overrides:
createDatain classXAQueue
-
isLoggingSuppressed
protected boolean isLoggingSuppressed() -
logSetBoolean
public void logSetBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean oldValue, boolean newValue) -
prepareLogSetBoolean
public void prepareLogSetBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean oldValue) -
logInsertBoolean
public void logInsertBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean newValue) -
logRemoveBoolean
public void logRemoveBoolean(PersistenceCapable o, PersistenceField field, int[] indices, boolean oldValue) -
logSetByte
public void logSetByte(PersistenceCapable o, PersistenceField field, int[] indices, byte oldValue, byte newValue) -
prepareLogSetByte
public void prepareLogSetByte(PersistenceCapable o, PersistenceField field, int[] indices, byte oldValue) -
logInsertByte
public void logInsertByte(PersistenceCapable o, PersistenceField field, int[] indices, byte newValue) -
logRemoveByte
public void logRemoveByte(PersistenceCapable o, PersistenceField field, int[] indices, byte oldValue) -
logSetShort
public void logSetShort(PersistenceCapable o, PersistenceField field, int[] indices, short oldValue, short newValue) -
prepareLogSetShort
public void prepareLogSetShort(PersistenceCapable o, PersistenceField field, int[] indices, short oldValue) -
logInsertShort
public void logInsertShort(PersistenceCapable o, PersistenceField field, int[] indices, short newValue) -
logRemoveShort
public void logRemoveShort(PersistenceCapable o, PersistenceField field, int[] indices, short oldValue) -
logSetChar
public void logSetChar(PersistenceCapable o, PersistenceField field, int[] indices, char oldValue, char newValue) -
prepareLogSetChar
public void prepareLogSetChar(PersistenceCapable o, PersistenceField field, int[] indices, char oldValue) -
logInsertChar
public void logInsertChar(PersistenceCapable o, PersistenceField field, int[] indices, char newValue) -
logRemoveChar
public void logRemoveChar(PersistenceCapable o, PersistenceField field, int[] indices, char oldValue) -
logSetInt
public void logSetInt(PersistenceCapable o, PersistenceField field, int[] indices, int oldValue, int newValue) -
prepareLogSetInt
public void prepareLogSetInt(PersistenceCapable o, PersistenceField field, int[] indices, int oldValue) -
logInsertInt
-
logRemoveInt
-
logSetLong
public void logSetLong(PersistenceCapable o, PersistenceField field, int[] indices, long oldValue, long newValue) -
prepareLogSetLong
public void prepareLogSetLong(PersistenceCapable o, PersistenceField field, int[] indices, long oldValue) -
logInsertLong
public void logInsertLong(PersistenceCapable o, PersistenceField field, int[] indices, long newValue) -
logRemoveLong
public void logRemoveLong(PersistenceCapable o, PersistenceField field, int[] indices, long oldValue) -
logSetFloat
public void logSetFloat(PersistenceCapable o, PersistenceField field, int[] indices, float oldValue, float newValue) -
prepareLogSetFloat
public void prepareLogSetFloat(PersistenceCapable o, PersistenceField field, int[] indices, float oldValue) -
logInsertFloat
public void logInsertFloat(PersistenceCapable o, PersistenceField field, int[] indices, float newValue) -
logRemoveFloat
public void logRemoveFloat(PersistenceCapable o, PersistenceField field, int[] indices, float oldValue) -
logSetDouble
public void logSetDouble(PersistenceCapable o, PersistenceField field, int[] indices, double oldValue, double newValue) -
prepareLogSetDouble
public void prepareLogSetDouble(PersistenceCapable o, PersistenceField field, int[] indices, double oldValue) -
logInsertDouble
public void logInsertDouble(PersistenceCapable o, PersistenceField field, int[] indices, double newValue) -
logRemoveDouble
public void logRemoveDouble(PersistenceCapable o, PersistenceField field, int[] indices, double oldValue) -
logSetObject
public void logSetObject(PersistenceCapable o, PersistenceField field, int[] indices, Object oldValue, Object newValue) -
prepareLogSetObject
public void prepareLogSetObject(PersistenceCapable o, PersistenceField field, int[] indices, Object oldValue) -
logInsertObject
public void logInsertObject(PersistenceCapable o, PersistenceField field, int[] indices, Object newValue) -
logRemoveObject
public void logRemoveObject(PersistenceCapable o, PersistenceField field, int[] indices, Object oldValue) -
logUndo
-
logRedo
-
logMakePersistent
-
logMakeTransient
-
logReadData
-
setReadOnly
public final void setReadOnly() -
getUserId
public final long getUserId() -
setUserId
public final void setUserId(long userId) -
createReader
-
setModified
protected void setModified() -
hasModified
public boolean hasModified() -
begin
public void begin(boolean readOnly) -
commit
public void commit() -
rollback
public void rollback() -
commitAll
public final void commitAll() -
rollbackAll
public final void rollbackAll() -
undo
- Throws:
IOException
-
redo
- Throws:
IOException
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceObjectOutput- Overrides:
closein classOutputQueue
-
isActive
public boolean isActive() -
getActiveCount
public int getActiveCount() -
getId
public final long getId() -
getKey
-
isApplying
-
isNotApplying
-
beginApply
public void beginApply() -
endApply
public void endApply() -
restore
- Overrides:
restorein classHierarchicalQueue
-
prepareSetBoolean
-
prepareSetByte
-
prepareSetShort
-
prepareSetChar
-
prepareSetInt
-
prepareSetLong
-
prepareSetFloat
-
prepareSetDouble
-
prepareSetObject
-
finishSet
public void finishSet() -
finishSet
-
makeActive
-
markModified
-
unmarkModified
public void unmarkModified() -
isModified
-