1/*- 2 * See the file LICENSE for redistribution information. 3 * 4 * Copyright (c) 1997-2009 Oracle. All rights reserved. 5 * 6 * $Id$ 7 */ 8package com.sleepycat.db; 9 10/** 11An interface specifying a callback function to be called to display 12informational messages. 13*/ 14public interface MessageHandler { 15 /** 16 A callback function to be called to display informational messages. 17 <p> 18 There are interfaces in the Berkeley DB library which either directly 19 output informational messages or statistical information, or configure 20 the library to output such messages when performing other operations, 21 {@link com.sleepycat.db.EnvironmentConfig#setVerboseDeadlock EnvironmentConfig.setVerboseDeadlock} for example. 22 <p> 23 The {@link com.sleepycat.db.EnvironmentConfig#setMessageHandler EnvironmentConfig.setMessageHandler} and 24 {@link com.sleepycat.db.DatabaseConfig#setMessageHandler DatabaseConfig.setMessageHandler} methods are used to 25 display these messages for the application. 26 <p> 27 @param environment 28 The enclosing database environment handle. 29 <p> 30 @param message 31 An informational message string. 32 */ 33 void message(Environment environment, String message); 34} 35