/** * Apply the undo operation, in this implementation of the RawStore, it can only call the undoMe * method of undoOp * * @param xact the Transaction that is doing the rollback * @param instant the log instant of this undo operation * @param in optional data * @exception IOException Can be thrown by any of the methods of ObjectInput. * @exception StandardException Standard Derby policy. */ public final void doMe(Transaction xact, LogInstant instant, LimitObjectInput in) throws StandardException, IOException { long oldversion = 0; // sanity check LogInstant oldLogInstant = null; // sanity check if (SanityManager.DEBUG) { oldLogInstant = this.page.getLastLogInstant(); oldversion = this.page.getPageVersion(); SanityManager.ASSERT(oldversion == this.getPageVersion()); SanityManager.ASSERT( oldLogInstant == null || instant == null || oldLogInstant.lessThan(instant)); } // if this is called during runtime rollback, PageOp.generateUndo found // the page and have it latched there. // if this is called during recovery redo, this.needsRedo found the page and // have it latched here // // in either case, this.page is the correct page and is latched. // // recordId is generated by generateUndo and is stored here. If this // is a physical undo, recordId is identical to that which is stored in // undoOp. If this is logical undo, it will be different if this.page // is different from the undoOp's page (which is where the rollfoward // change went to, and the record might have moved by now). // undoOp.undoMe(xact, this.page, recordId, instant, in); if (SanityManager.DEBUG) { SanityManager.ASSERT(oldversion < this.page.getPageVersion()); SanityManager.ASSERT(instant == null || instant.equals(this.page.getLastLogInstant())); } releaseResource(xact); }