com.sleepycat.je.utilint
Class DatabaseUtil

java.lang.Object
  extended by com.sleepycat.je.utilint.DatabaseUtil

public class DatabaseUtil
extends Object

Utils for use in the db package.


Constructor Summary
DatabaseUtil()
           
 
Method Summary
static void checkForNullDbt(DatabaseEntry entry, String name, boolean checkData)
          Throw an exception if the entry is null or the data field is not set.
static void checkForNullParam(Object param, String name)
          Throw an exception if the parameter is null.
static void checkForPartialKey(DatabaseEntry entry)
          Throw an exception if the key entry has the partial flag set.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DatabaseUtil

public DatabaseUtil()
Method Detail

checkForNullParam

public static void checkForNullParam(Object param,
                                     String name)
Throw an exception if the parameter is null.

Throws:
IllegalArgumentException - via any API method

checkForNullDbt

public static void checkForNullDbt(DatabaseEntry entry,
                                   String name,
                                   boolean checkData)
Throw an exception if the entry is null or the data field is not set.

Throws:
IllegalArgumentException - via any API method that takes a required DatabaseEntry param

checkForPartialKey

public static void checkForPartialKey(DatabaseEntry entry)
Throw an exception if the key entry has the partial flag set. This method should be called for all put() operations.

Throws:
IllegalArgumentException - via put methodx


Copyright (c) 2004-2010 Oracle. All rights reserved.