1 21 22 package org.apache.derby.impl.store.raw.xact; 23 24 import org.apache.derby.iapi.services.locks.LockFactory; 25 import org.apache.derby.iapi.services.locks.C_LockFactory; 26 import org.apache.derby.iapi.services.locks.Latch; 27 28 import org.apache.derby.iapi.services.sanity.SanityManager; 29 30 import org.apache.derby.iapi.store.raw.ContainerHandle; 31 import org.apache.derby.iapi.store.raw.ContainerLock; 32 import org.apache.derby.iapi.store.raw.LockingPolicy; 33 import org.apache.derby.iapi.store.raw.RecordHandle; 34 import org.apache.derby.iapi.store.raw.RowLock; 35 import org.apache.derby.iapi.store.raw.Transaction; 36 37 import org.apache.derby.iapi.error.StandardException; 38 39 40 50 public class RowLocking2nohold extends RowLocking2 51 { 52 protected RowLocking2nohold(LockFactory lf) 53 { 54 super(lf); 55 } 56 57 75 public boolean lockRecordForRead( 76 Transaction t, 77 ContainerHandle container_handle, 78 RecordHandle record, 79 boolean waitForLock, 80 boolean forUpdate) 81 throws StandardException 82 { 83 if (SanityManager.DEBUG) 86 { 87 SanityManager.ASSERT(!forUpdate); 88 } 89 90 return(lf.zeroDurationlockObject( 91 t.getCompatibilitySpace(), 92 record, 93 (forUpdate ? RowLock.RU2 : RowLock.RS2), 94 waitForLock ? 95 C_LockFactory.TIMED_WAIT : C_LockFactory.NO_WAIT)); 96 } 97 98 public void unlockRecordAfterRead( 99 Transaction t, 100 ContainerHandle container_handle, 101 RecordHandle record, 102 boolean forUpdate, 103 boolean row_qualified) 104 { 105 return; 106 } 107 } 108 | Popular Tags |