| Modifier and Type | Field and Description |
|---|---|
| protected int | |
| protected LogicalUndo |
| Access | Constructor and Description |
|---|---|
| public | |
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| private BasePage | Returns: the compensation operation that will rollback this changethe transaction doing the compensating xact, LogicalUndo undo, LimitObjectInput optional input in)Find the page that the rollback operation should be applied to. |
| public Compensation | generateUndo(Transaction
the transaction doing the rollback xact, LimitObjectInput in)Implements org. Generate a Compensation (PageUndoOperation) that will rollback the changes of this page operation. |
| public ContainerHandle | getContainer()
Implements org. Return the container handle where the log operated on |
| public RecordHandle | getRecordHandle()
Implements org. Return the record handle that correspond to the record that was changed during roll forward. |
| public void | readExternal(ObjectInput
the stream to read data from in order to restore the object in)Overrides org. Implements java. Read this in |
| public void | reclaimPrepareLocks(Transaction t, LockingPolicy
The locking policy to use to claim the locks. locking_policy)Overrides org. Implements org. reclaim locks associated with the changes in this log record. |
| public void | resetRecordHandle(RecordHandle
the RecordHandle that represents the row's new location rh)Implements org. After the logical undo logic figures out where the real record that needs roll back is, reset this log operation to refer to that record |
| public abstract void | undoMe(Transaction
the Transaction doing the rollback xact, BasePage the page to rollback changes on undoPage, int the recordId to rollback changes on undoRecordId, LogInstant the log instant of this (PageUndo) operation CLRinstant, LimitObjectInput optional data for the rollback operation in)Undo the change indicated by this log operation and optional data. |
| public void | writeExternal(ObjectOutput
the stream to write the object to out)Overrides org. Implements java. The object implements the writeExternal method to save its contents by calling the methods of DataOutput for its primitive values or calling the writeObject method of ObjectOutput for objects, strings, and arrays. |
| recordId | back to summary |
|---|---|
| protected int recordId | |
| undo | back to summary |
|---|---|
| protected LogicalUndo undo | |
| LogicalPageOperation | back to summary |
|---|---|
| public LogicalPageOperation() | |
| LogicalPageOperation | back to summary |
|---|---|
| pack-priv LogicalPageOperation(BasePage page, LogicalUndo undo, int recordId) | |
| findLogicalPage | back to summary |
|---|---|
| private BasePage findLogicalPage(Transaction xact, LogicalUndo undo, LimitObjectInput in) throws StandardException, IOException Find the page that the rollback operation should be applied to. The actual logical log operation is expected to implement Undoable.generateUndo. This utility function findLogicalPage is provided for the common case scenario of using a LogicalUndo interface to find the undo page. The subclass that implements Undoable.generateUndo can use this function to find the logical page with its LogicalUndo callback function. This method can be used with the default releaseResource(). During recovery redo, the logging system is page oriented and will use the pageID stored in the PageUndoOperation to find the page. The page will be latched and released using the default findpage and releaseResource - this.releaseResource() will still be called so it has to know not to release any resource it did not acquire.
| |
| generateUndo | back to summary |
|---|---|
| public Compensation generateUndo(Transaction xact, LimitObjectInput in) throws StandardException, IOException Implements org. Generate a Compensation (PageUndoOperation) that will rollback the changes of this page operation. If this Page operation cannot or need not be rolled back (redo only), overwrite this function to return null.
| |
| getContainer | back to summary |
|---|---|
| public ContainerHandle getContainer() Implements org. Return the container handle where the log operated on | |
| getRecordHandle | back to summary |
|---|---|
| public RecordHandle getRecordHandle() Implements org. Return the record handle that correspond to the record that was changed during roll forward. This is used as a hint by logical undo as a good place to look for the record to apply the roll back. | |
| readExternal | back to summary |
|---|---|
| public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException Overrides org. Implements java. Read this in
| |
| reclaimPrepareLocks | back to summary |
|---|---|
| public void reclaimPrepareLocks(Transaction t, LockingPolicy locking_policy) throws StandardException Overrides org. Implements org. reclaim locks associated with the changes in this log record.
| |
| resetRecordHandle | back to summary |
|---|---|
| public void resetRecordHandle(RecordHandle rh) Implements org. After the logical undo logic figures out where the real record that needs roll back is, reset this log operation to refer to that record
| |
| undoMe | back to summary |
|---|---|
| public abstract void undoMe(Transaction xact, BasePage undoPage, int undoRecordId, LogInstant CLRinstant, LimitObjectInput in) throws StandardException, IOException Undo the change indicated by this log operation and optional data.
The undoPage and undoRecordId is the page, record the undo should apply to.
The undoRecorId differs from the roll forward recordId if the undoPage
differs from the page the roll forward operation was applied to, in
other words, the record moved to another page and the recordId changed.
The available() method of in indicates how much data can be read, i.e.
how much was originally written.
| |
| writeExternal | back to summary |
|---|---|
| public void writeExternal(ObjectOutput out) throws IOException Overrides org. Implements java. Doc from java. The object implements the writeExternal method to save its contents by calling the methods of DataOutput for its primitive values or calling the writeObject method of ObjectOutput for objects, strings, and arrays.
| |