#include <db.h> void DB->msg(DB *db, const char *fmt, ...);
The
DB_ENV->msg()
and
DB->msg()
methods provide informational messaging functionality for
applications written using the Berkeley DB library.
The DB->msg()
and
DB_ENV->msg()
methods construct
an informational message consisting of the following elements:
An optional prefix string
If no informational callback function has been set using the DB_ENV->set_msgcall() method, any prefix string specified using the DB_ENV->set_msgpfx() method.
An optional printf-style message
The supplied message fmt, if non-NULL, in which the ANSI C X3.159-1989 (ANSI C) printf function specifies how subsequent parameters are converted for output.
This constructed informational message is then handled as follows:
If an informational callback function has been set (see DB->set_msgcall() and DB_ENV->set_msgcall() ), that function is called with two parameters: any prefix string specified (see DB->set_msgpfx() and DB_ENV->set_msgpfx() ) and the informational message.
If a C library FILE * has been set (see DB->set_msgfile() and DB_ENV->set_msgfile() ), the informational message is written to that output stream.
If none of these output options have been configured, the informational message is written to stdout, the standard output stream.
The total length of the message written by this method, including the prefix string, can be no longer than 4096.