Main Page | Class Hierarchy | Data Structures | Directories | File List | Data Fields | Related Pages

LockNotGrantedException.java

00001 /*-
00002  * See the file LICENSE for redistribution information.
00003  *
00004  * Copyright (c) 1997-2005
00005  *      Sleepycat Software.  All rights reserved.
00006  *
00007  * $Id: LockNotGrantedException.java,v 12.1 2005/06/16 20:23:02 bostic Exp $
00008  */
00009 package com.sleepycat.db;
00010 
00011 import com.sleepycat.db.internal.DbConstants;
00012 import com.sleepycat.db.internal.DbEnv;
00013 import com.sleepycat.db.internal.DbLock;
00014 
00015 public class LockNotGrantedException extends DeadlockException {
00016     private int index;
00017     private Lock lock;
00018     private int mode;
00019     private DatabaseEntry obj;
00020     private int op;
00021 
00022     protected LockNotGrantedException(final String message,
00023                                       final int op,
00024                                       final int mode,
00025                                       final DatabaseEntry obj,
00026                                       final DbLock lock,
00027                                       final int index,
00028                                       final DbEnv dbenv) {
00029         super(message, DbConstants.DB_LOCK_NOTGRANTED, dbenv);
00030         this.op = op;
00031         this.mode = mode;
00032         this.obj = obj;
00033         this.lock = (lock == null) ? null : lock.wrapper;
00034         this.index = index;
00035     }
00036 
00037     public int getIndex() {
00038         return index;
00039     }
00040 
00041     public Lock getLock() {
00042         return lock;
00043     }
00044 
00045     public int getMode() {
00046         return mode;
00047     }
00048 
00049     public DatabaseEntry getObj() {
00050         return obj;
00051     }
00052 
00053     public int getOp() {
00054         return op;
00055     }
00056 }

Generated on Sun Dec 25 12:14:33 2005 for Berkeley DB 4.4.16 by  doxygen 1.4.2