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

DbEnv.java

00001 /* ----------------------------------------------------------------------------
00002  * This file was automatically generated by SWIG (http://www.swig.org).
00003  * Version 1.3.25
00004  *
00005  * Do not make changes to this file unless you know what you are doing--modify
00006  * the SWIG interface file instead.
00007  * ----------------------------------------------------------------------------- */
00008 
00009 package com.sleepycat.db.internal;
00010 
00011 import com.sleepycat.db.*;
00012 import java.util.Comparator;
00013 
00014 public class DbEnv {
00015   private long swigCPtr;
00016   protected boolean swigCMemOwn;
00017 
00018   protected DbEnv(long cPtr, boolean cMemoryOwn) {
00019     swigCMemOwn = cMemoryOwn;
00020     swigCPtr = cPtr;
00021   }
00022 
00023   protected static long getCPtr(DbEnv obj) {
00024     return (obj == null) ? 0 : obj.swigCPtr;
00025   }
00026 
00027   /* package */ void delete() {
00028     if(swigCPtr != 0 && swigCMemOwn) {
00029       swigCMemOwn = false;
00030       throw new UnsupportedOperationException("C++ destructor does not have public access");
00031     }
00032     swigCPtr = 0;
00033   }
00034 
00035         /*
00036          * Internally, the JNI layer creates a global reference to each DbEnv,
00037          * which can potentially be different to this.  We keep a copy here so
00038          * we can clean up after destructors.
00039          */
00040         private long dbenv_ref;
00041         public Environment wrapper;
00042 
00043         private LogRecordHandler app_dispatch_handler;
00044         private FeedbackHandler env_feedback_handler;
00045         private ErrorHandler error_handler;
00046         private String errpfx;
00047         private MessageHandler message_handler;
00048         private PanicHandler panic_handler;
00049         private ReplicationTransport rep_transport_handler;
00050         private java.io.OutputStream error_stream;
00051         private java.io.OutputStream message_stream;
00052 
00053         public static class RepProcessMessage {
00054                 public int envid;
00055         }
00056 
00057         /*
00058          * Called by the public DbEnv constructor and for private environments
00059          * by the Db constructor.
00060          */
00061         void initialize() {
00062                 dbenv_ref = db_java.initDbEnvRef0(this, this);
00063                 /* Start with System.err as the default error stream. */
00064                 set_error_stream(System.err);
00065                 set_message_stream(System.out);
00066         }
00067 
00068         void cleanup() {
00069                 swigCPtr = 0;
00070                 db_java.deleteRef0(dbenv_ref);
00071                 dbenv_ref = 0L;
00072         }
00073 
00074         public synchronized void close(int flags) throws DatabaseException {
00075                 try {
00076                         close0(flags);
00077                 } finally {
00078                         cleanup();
00079                 }
00080         }
00081 
00082         private final int handle_app_dispatch(DatabaseEntry dbt,
00083                                               LogSequenceNumber lsn,
00084                                               int recops) {
00085                 return app_dispatch_handler.handleLogRecord(wrapper, dbt, lsn,
00086                     RecoveryOperation.fromFlag(recops));
00087         }
00088 
00089         public LogRecordHandler get_app_dispatch() throws com.sleepycat.db.DatabaseException {
00090                 return app_dispatch_handler;
00091         }
00092 
00093         private final void handle_env_feedback(int opcode, int percent) {
00094                 if (opcode == DbConstants.DB_RECOVER)
00095                         env_feedback_handler.recoveryFeedback(wrapper, percent);
00096                 /* No other environment feedback type supported. */
00097         }
00098 
00099         public FeedbackHandler get_feedback() throws com.sleepycat.db.DatabaseException {
00100                 return env_feedback_handler;
00101         }
00102 
00103         public void set_errpfx(String errpfx) /* no exception */ {
00104                 this.errpfx = errpfx;
00105         }
00106 
00107         public String get_errpfx() /* no exception */ {
00108                 return errpfx;
00109         }
00110 
00111         private final void handle_error(String msg) {
00112                 error_handler.error(wrapper, this.errpfx, msg);
00113         }
00114 
00115         public ErrorHandler get_errcall() /* no exception */ {
00116                 return error_handler;
00117         }
00118 
00119         private final void handle_message(String msg) {
00120                 message_handler.message(wrapper, msg);
00121         }
00122 
00123         public MessageHandler get_msgcall() /* no exception */ {
00124                 return message_handler;
00125         }
00126 
00127         private final void handle_panic(DatabaseException e) {
00128                 panic_handler.panic(wrapper, e);
00129         }
00130 
00131         public PanicHandler get_paniccall() throws com.sleepycat.db.DatabaseException {
00132                 return panic_handler;
00133         }
00134 
00135         private final int handle_rep_transport(DatabaseEntry control,
00136                                                DatabaseEntry rec,
00137                                                LogSequenceNumber lsn,
00138                                                int envid, int flags)
00139             throws DatabaseException {
00140                 return rep_transport_handler.send(wrapper,
00141                     control, rec, lsn, envid,
00142                     (flags & DbConstants.DB_REP_NOBUFFER) != 0,
00143                     (flags & DbConstants.DB_REP_PERMANENT) != 0,
00144                     (flags & DbConstants.DB_REP_ANYWHERE) != 0,
00145                     (flags & DbConstants.DB_REP_REREQUEST) != 0);
00146         }
00147 
00148         public void lock_vec(/*u_int32_t*/ int locker, int flags,
00149                              LockRequest[] list, int offset, int count)
00150             throws DatabaseException {
00151                 db_javaJNI.DbEnv_lock_vec(swigCPtr, locker, flags, list,
00152                     offset, count);
00153         }
00154 
00155         public synchronized void remove(String db_home, int flags)
00156             throws DatabaseException, java.io.FileNotFoundException {
00157                 try {
00158                         remove0(db_home, flags);
00159                 } finally {
00160                         cleanup();
00161                 }
00162         }
00163 
00164         public void set_error_stream(java.io.OutputStream stream) /* no exception */ {
00165                 error_stream = stream;
00166                 final java.io.PrintWriter pw = new java.io.PrintWriter(stream);
00167                 set_errcall(new ErrorHandler() {
00168                         public void error(Environment env,
00169                             String prefix, String buf) /* no exception */ {
00170                                 if (prefix != null)
00171                                         pw.print(prefix + ": ");
00172                                 pw.println(buf);
00173                                 pw.flush();
00174                         }
00175                 });
00176         }
00177 
00178         public java.io.OutputStream get_error_stream() /* no exception */ {
00179                 return error_stream;
00180         }
00181 
00182 
00183         public void set_message_stream(java.io.OutputStream stream) /* no exception */ {
00184                 message_stream = stream;
00185                 final java.io.PrintWriter pw = new java.io.PrintWriter(stream);
00186                 set_msgcall(new MessageHandler() {
00187                         public void message(Environment env, String msg) /* no exception */
00188                             /* no exception */ {
00189                                 pw.println(msg);
00190                                 pw.flush();
00191                         }
00192                 });
00193         }
00194 
00195         public java.io.OutputStream get_message_stream() /* no exception */ {
00196                 return message_stream;
00197         }
00198 
00199         public void set_tx_timestamp(java.util.Date timestamp) throws com.sleepycat.db.DatabaseException {
00200                 set_tx_timestamp0(timestamp.getTime()/1000);
00201         }
00202 
00203   public DbEnv(int flags) throws com.sleepycat.db.DatabaseException {
00204     this(db_javaJNI.new_DbEnv(flags), true);
00205     initialize();
00206   }
00207 
00208   /* package */ void close0(int flags) { db_javaJNI.DbEnv_close0(swigCPtr, flags); }
00209 
00210   public void dbremove(DbTxn txnid, String file, String database, int flags) throws com.sleepycat.db.DatabaseException, java.io.FileNotFoundException { db_javaJNI.DbEnv_dbremove(swigCPtr, DbTxn.getCPtr(txnid), file, database, flags); }
00211 
00212   public void dbrename(DbTxn txnid, String file, String database, String newname, int flags) throws com.sleepycat.db.DatabaseException, java.io.FileNotFoundException { db_javaJNI.DbEnv_dbrename(swigCPtr, DbTxn.getCPtr(txnid), file, database, newname, flags); }
00213 
00214   public void err(int error, String message) /* no exception */ {
00215     db_javaJNI.DbEnv_err(swigCPtr, error, message);
00216   }
00217 
00218   public void errx(String message) /* no exception */ {
00219     db_javaJNI.DbEnv_errx(swigCPtr, message);
00220   }
00221 
00222   public void fileid_reset(String file, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_fileid_reset(swigCPtr, file, flags); }
00223 
00224   public String[] get_data_dirs() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_data_dirs(swigCPtr); }
00225 
00226   public int get_encrypt_flags() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_encrypt_flags(swigCPtr); }
00227 
00228   public int get_flags() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_flags(swigCPtr); }
00229 
00230   public String get_home() throws com.sleepycat.db.DatabaseException {
00231     return db_javaJNI.DbEnv_get_home(swigCPtr);
00232   }
00233 
00234   public int get_open_flags() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_open_flags(swigCPtr); }
00235 
00236   public long get_shm_key() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_shm_key(swigCPtr); }
00237 
00238   public String get_tmp_dir() throws com.sleepycat.db.DatabaseException {
00239     return db_javaJNI.DbEnv_get_tmp_dir(swigCPtr);
00240   }
00241 
00242   public boolean get_verbose(int which) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_verbose(swigCPtr, which); }
00243 
00244   public boolean is_bigendian() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_is_bigendian(swigCPtr); }
00245 
00246   public void lsn_reset(String file, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_lsn_reset(swigCPtr, file, flags); }
00247 
00248   public void open(String db_home, int flags, int mode) throws com.sleepycat.db.DatabaseException, java.io.FileNotFoundException { db_javaJNI.DbEnv_open(swigCPtr, db_home, flags, mode); }
00249 
00250   /* package */ void remove0(String db_home, int flags) { db_javaJNI.DbEnv_remove0(swigCPtr, db_home, flags); }
00251 
00252   public void set_cachesize(long bytes, int ncache) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_cachesize(swigCPtr, bytes, ncache); }
00253 
00254   public void set_data_dir(String dir) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_data_dir(swigCPtr, dir); }
00255 
00256   public void set_intermediate_dir(int mode, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_intermediate_dir(swigCPtr, mode, flags); }
00257 
00258   public void set_encrypt(String passwd, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_encrypt(swigCPtr, passwd, flags); }
00259 
00260   public void set_errcall(com.sleepycat.db.ErrorHandler db_errcall_fcn) /* no exception */ {
00261     db_javaJNI.DbEnv_set_errcall(swigCPtr,  (error_handler = db_errcall_fcn) );
00262   }
00263 
00264   public void set_flags(int flags, boolean onoff) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_flags(swigCPtr, flags, onoff); }
00265 
00266   public void set_feedback(com.sleepycat.db.FeedbackHandler env_feedback_fcn) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_feedback(swigCPtr,  (env_feedback_handler = env_feedback_fcn) ); }
00267 
00268   public void set_mp_max_openfd(int maxopenfd) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_mp_max_openfd(swigCPtr, maxopenfd); }
00269 
00270   public void set_mp_max_write(int maxwrite, int maxwrite_sleep) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_mp_max_write(swigCPtr, maxwrite, maxwrite_sleep); }
00271 
00272   public void set_mp_mmapsize(long mp_mmapsize) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_mp_mmapsize(swigCPtr, mp_mmapsize); }
00273 
00274   public void set_msgcall(com.sleepycat.db.MessageHandler db_msgcall_fcn) /* no exception */ {
00275     db_javaJNI.DbEnv_set_msgcall(swigCPtr,  (message_handler = db_msgcall_fcn) );
00276   }
00277 
00278   public void set_paniccall(com.sleepycat.db.PanicHandler db_panic_fcn) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_paniccall(swigCPtr,  (panic_handler = db_panic_fcn) ); }
00279 
00280   public void set_rpc_server(DbClient client, String host, long cl_timeout, long sv_timeout, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_rpc_server(swigCPtr, client, host, cl_timeout, sv_timeout, flags); }
00281 
00282   public void set_shm_key(long shm_key) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_shm_key(swigCPtr, shm_key); }
00283 
00284   public void set_timeout(long timeout, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_timeout(swigCPtr, timeout, flags); }
00285 
00286   public void set_tmp_dir(String dir) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_tmp_dir(swigCPtr, dir); }
00287 
00288   public void set_tx_max(int max) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_tx_max(swigCPtr, max); }
00289 
00290   public void set_app_dispatch(com.sleepycat.db.LogRecordHandler tx_recover) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_app_dispatch(swigCPtr,  (app_dispatch_handler = tx_recover) ); }
00291 
00292   /* package */ void set_tx_timestamp0(long timestamp) { db_javaJNI.DbEnv_set_tx_timestamp0(swigCPtr, timestamp); }
00293 
00294   public void set_verbose(int which, boolean onoff) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_verbose(swigCPtr, which, onoff); }
00295 
00296   public byte[][] get_lk_conflicts() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lk_conflicts(swigCPtr); }
00297 
00298   public int get_lk_detect() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lk_detect(swigCPtr); }
00299 
00300   public int get_lk_max_locks() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lk_max_locks(swigCPtr); }
00301 
00302   public int get_lk_max_lockers() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lk_max_lockers(swigCPtr); }
00303 
00304   public int get_lk_max_objects() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lk_max_objects(swigCPtr); }
00305 
00306   public int lock_detect(int flags, int atype) throws com.sleepycat.db.DatabaseException {
00307     return db_javaJNI.DbEnv_lock_detect(swigCPtr, flags, atype);
00308   }
00309 
00310   public DbLock lock_get(int locker, int flags, com.sleepycat.db.DatabaseEntry object, int lock_mode) throws com.sleepycat.db.DatabaseException {
00311     long cPtr = db_javaJNI.DbEnv_lock_get(swigCPtr, locker, flags, object, lock_mode);
00312     return (cPtr == 0) ? null : new DbLock(cPtr, true);
00313   }
00314 
00315   public int lock_id() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_lock_id(swigCPtr); }
00316 
00317   public void lock_id_free(int id) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_lock_id_free(swigCPtr, id); }
00318 
00319   public void lock_put(DbLock lock) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_lock_put(swigCPtr, DbLock.getCPtr(lock)); }
00320 
00321   public com.sleepycat.db.LockStats lock_stat(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_lock_stat(swigCPtr, flags); }
00322 
00323   public void set_lk_conflicts(byte[][] conflicts) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lk_conflicts(swigCPtr, conflicts); }
00324 
00325   public void set_lk_detect(int detect) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lk_detect(swigCPtr, detect); }
00326 
00327   public void set_lk_max_lockers(int max) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lk_max_lockers(swigCPtr, max); }
00328 
00329   public void set_lk_max_locks(int max) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lk_max_locks(swigCPtr, max); }
00330 
00331   public void set_lk_max_objects(int max) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lk_max_objects(swigCPtr, max); }
00332 
00333   public int get_lg_bsize() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lg_bsize(swigCPtr); }
00334 
00335   public String get_lg_dir() throws com.sleepycat.db.DatabaseException {
00336     return db_javaJNI.DbEnv_get_lg_dir(swigCPtr);
00337   }
00338 
00339   public int get_lg_filemode() throws com.sleepycat.db.DatabaseException {
00340     return db_javaJNI.DbEnv_get_lg_filemode(swigCPtr);
00341   }
00342 
00343   public int get_lg_max() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lg_max(swigCPtr); }
00344 
00345   public int get_lg_regionmax() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_lg_regionmax(swigCPtr); }
00346 
00347   public String[] log_archive(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_log_archive(swigCPtr, flags); }
00348 
00349   public static int log_compare(com.sleepycat.db.LogSequenceNumber lsn0, com.sleepycat.db.LogSequenceNumber lsn1) /* no exception */ {
00350     return db_javaJNI.DbEnv_log_compare(lsn0, lsn1);
00351   }
00352 
00353   public DbLogc log_cursor(int flags) throws com.sleepycat.db.DatabaseException {
00354     long cPtr = db_javaJNI.DbEnv_log_cursor(swigCPtr, flags);
00355     return (cPtr == 0) ? null : new DbLogc(cPtr, true);
00356   }
00357 
00358   public String log_file(com.sleepycat.db.LogSequenceNumber lsn) throws com.sleepycat.db.DatabaseException {
00359     return db_javaJNI.DbEnv_log_file(swigCPtr, lsn);
00360   }
00361 
00362   public void log_flush(com.sleepycat.db.LogSequenceNumber lsn_or_null) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_log_flush(swigCPtr, lsn_or_null); }
00363 
00364   public void log_put(com.sleepycat.db.LogSequenceNumber lsn, com.sleepycat.db.DatabaseEntry data, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_log_put(swigCPtr, lsn, data, flags); }
00365 
00366   public void log_print(DbTxn txn, String msg) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_log_print(swigCPtr, DbTxn.getCPtr(txn), msg); }
00367 
00368   public com.sleepycat.db.LogStats log_stat(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_log_stat(swigCPtr, flags); }
00369 
00370   public void set_lg_bsize(int lg_bsize) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lg_bsize(swigCPtr, lg_bsize); }
00371 
00372   public void set_lg_dir(String dir) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lg_dir(swigCPtr, dir); }
00373 
00374   public void set_lg_filemode(int mode) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lg_filemode(swigCPtr, mode); }
00375 
00376   public void set_lg_max(int lg_max) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lg_max(swigCPtr, lg_max); }
00377 
00378   public void set_lg_regionmax(int lg_regionmax) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_lg_regionmax(swigCPtr, lg_regionmax); }
00379 
00380   public long get_cachesize() throws com.sleepycat.db.DatabaseException {
00381     return db_javaJNI.DbEnv_get_cachesize(swigCPtr);
00382   }
00383 
00384   public int get_cachesize_ncache() throws com.sleepycat.db.DatabaseException {
00385     return db_javaJNI.DbEnv_get_cachesize_ncache(swigCPtr);
00386   }
00387 
00388   public int get_mp_max_openfd() throws com.sleepycat.db.DatabaseException {
00389     return db_javaJNI.DbEnv_get_mp_max_openfd(swigCPtr);
00390   }
00391 
00392   public int get_mp_max_write() throws com.sleepycat.db.DatabaseException {
00393     return db_javaJNI.DbEnv_get_mp_max_write(swigCPtr);
00394   }
00395 
00396   public int get_mp_max_write_sleep() throws com.sleepycat.db.DatabaseException {
00397     return db_javaJNI.DbEnv_get_mp_max_write_sleep(swigCPtr);
00398   }
00399 
00400   public long get_mp_mmapsize() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_mp_mmapsize(swigCPtr); }
00401 
00402   public com.sleepycat.db.CacheStats memp_stat(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_memp_stat(swigCPtr, flags); }
00403 
00404   public com.sleepycat.db.CacheFileStats[] memp_fstat(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_memp_fstat(swigCPtr, flags); }
00405 
00406   public int memp_trickle(int percent) throws com.sleepycat.db.DatabaseException {
00407     return db_javaJNI.DbEnv_memp_trickle(swigCPtr, percent);
00408   }
00409 
00410   public int mutex_get_align() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_mutex_get_align(swigCPtr); }
00411 
00412   public int mutex_get_increment() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_mutex_get_increment(swigCPtr); }
00413 
00414   public int mutex_get_max() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_mutex_get_max(swigCPtr); }
00415 
00416   public int mutex_get_tas_spins() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_mutex_get_tas_spins(swigCPtr); }
00417 
00418   public void mutex_set_align(int align) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_mutex_set_align(swigCPtr, align); }
00419 
00420   public void mutex_set_increment(int increment) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_mutex_set_increment(swigCPtr, increment); }
00421 
00422   public void mutex_set_max(int mutex_max) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_mutex_set_max(swigCPtr, mutex_max); }
00423 
00424   public void mutex_set_tas_spins(int tas_spins) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_mutex_set_tas_spins(swigCPtr, tas_spins); }
00425 
00426   public com.sleepycat.db.MutexStats mutex_stat(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_mutex_stat(swigCPtr, flags); }
00427 
00428   public int get_tx_max() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_tx_max(swigCPtr); }
00429 
00430   public long get_tx_timestamp() throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_tx_timestamp(swigCPtr); }
00431 
00432   public long get_timeout(int flag) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_get_timeout(swigCPtr, flag); }
00433 
00434   public DbTxn txn_begin(DbTxn parent, int flags) throws com.sleepycat.db.DatabaseException {
00435     long cPtr = db_javaJNI.DbEnv_txn_begin(swigCPtr, DbTxn.getCPtr(parent), flags);
00436     return (cPtr == 0) ? null : new DbTxn(cPtr, false);
00437   }
00438 
00439   public void txn_checkpoint(int kbyte, int min, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_txn_checkpoint(swigCPtr, kbyte, min, flags); }
00440 
00441   public com.sleepycat.db.PreparedTransaction[] txn_recover(int count, int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_txn_recover(swigCPtr, count, flags); }
00442 
00443   public com.sleepycat.db.TransactionStats txn_stat(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_txn_stat(swigCPtr, flags); }
00444 
00445   public long get_rep_limit() throws com.sleepycat.db.DatabaseException {
00446     return db_javaJNI.DbEnv_get_rep_limit(swigCPtr);
00447   }
00448 
00449   public int rep_elect(int nsites, int nvotes, int priority, int timeout, int flags) throws com.sleepycat.db.DatabaseException {
00450     return db_javaJNI.DbEnv_rep_elect(swigCPtr, nsites, nvotes, priority, timeout, flags);
00451   }
00452 
00453   public int rep_process_message(com.sleepycat.db.DatabaseEntry control, com.sleepycat.db.DatabaseEntry rec, DbEnv.RepProcessMessage envid, com.sleepycat.db.LogSequenceNumber ret_lsn) /* no exception */ {
00454     return db_javaJNI.DbEnv_rep_process_message(swigCPtr, control, rec, envid, ret_lsn);
00455   }
00456 
00457   public void rep_flush() throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_rep_flush(swigCPtr); }
00458 
00459   public void rep_set_config(int which, boolean onoff) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_rep_set_config(swigCPtr, which, onoff); }
00460 
00461   public void rep_start(com.sleepycat.db.DatabaseEntry cdata, int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_rep_start(swigCPtr, cdata, flags); }
00462 
00463   public void rep_sync(int flags) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_rep_sync(swigCPtr, flags); }
00464 
00465   public boolean rep_get_config(int which) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_rep_get_config(swigCPtr, which); }
00466 
00467   public com.sleepycat.db.ReplicationStats rep_stat(int flags) throws com.sleepycat.db.DatabaseException { return db_javaJNI.DbEnv_rep_stat(swigCPtr, flags); }
00468 
00469   public void set_rep_limit(long bytes) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_rep_limit(swigCPtr, bytes); }
00470 
00471   public void set_rep_request(int min, int max) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_rep_request(swigCPtr, min, max); }
00472 
00473   public void set_rep_transport(int envid, com.sleepycat.db.ReplicationTransport send) throws com.sleepycat.db.DatabaseException { db_javaJNI.DbEnv_set_rep_transport(swigCPtr, envid,  (rep_transport_handler = send) ); }
00474 
00475   public static String strerror(int error) /* no exception */ {
00476     return db_javaJNI.DbEnv_strerror(error);
00477   }
00478 
00479   public static int get_version_major() /* no exception */ {
00480     return db_javaJNI.DbEnv_get_version_major();
00481   }
00482 
00483   public static int get_version_minor() /* no exception */ {
00484     return db_javaJNI.DbEnv_get_version_minor();
00485   }
00486 
00487   public static int get_version_patch() /* no exception */ {
00488     return db_javaJNI.DbEnv_get_version_patch();
00489   }
00490 
00491   public static String get_version_string() /* no exception */ {
00492     return db_javaJNI.DbEnv_get_version_string();
00493   }
00494 
00495 }

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