Import BSDDB 4.7.25 (as of svn r89086)

This commit is contained in:
Zachary Ware
2017-09-04 13:40:25 -05:00
parent 4b29e0458f
commit 8f590873d0
4781 changed files with 2241032 additions and 6 deletions

View File

@@ -0,0 +1,4 @@
# $Id: Makefile,v 1.3 2004/08/13 03:38:56 bostic Exp $
CXX= except_class.html \
runrec_class.html

View File

@@ -0,0 +1,53 @@
m4_comment([$Id: except_class.so,v 10.38 2004/09/28 15:04:19 bostic Exp $])
define(M4PAGELOCAL,
[DbException, except_get_env, except_get_errno, except_what])
include(m4/m4.seealso)
m4_pf_header(m4_ref(DbException),
ifelse(M4API, CXX_API, [dnl
class DbException {
public:
int get_errno() const;
virtual const char *what() const;
DbEnv *get_env() const;
};
]))
m4_p([dnl
This information describes the m4_ref(DbException) class and how it is
used by the various m4_db classes.])
ifelse(M4API, CXX_API, [dnl
m4_p([dnl
Most methods in the m4_db classes return an int, but also throw an
exception. This allows for two different error behaviors. By default,
the m4_db C++ API is configured to throw an exception whenever a serious
error occurs. This generally allows for cleaner logic for transaction
processing because a try block can surround a single transaction.
Alternatively, m4_db can be configured to not throw exceptions, and
instead have the individual function return an error code, by setting
the m4_ref(DB_CXX_NO_EXCEPTIONS) for the m4_ref(Db) and m4_ref(DbEnv)
constructors.])
m4_p([dnl
A DbException object contains an informational string, an errno, and a
reference to the environment from which the exception was thrown. The
errno can be obtained by using m4_ref(except_get_errno), and can be
used, in standard cases, to determine the type of the exception. The
informational string can be obtained by using m4_ref(except_what). And,
the environment can be obtained using m4_ref(except_get_env).])
m4_p([dnl
We expect in the future that this class will inherit from the standard
class exception, but certain language implementation bugs currently
prevent this on some platforms.])])
m4_p([dnl
Some methods may return non-zero values without issuing an exception.
This occurs in situations that are not normally considered an error, but
when some informational status is returned. For example,
m4_ref(dbh_get) returns m4_ref(DB_NOTFOUND) when a requested key does
not appear in the database.])
m4_page_footer

View File

@@ -0,0 +1,27 @@
m4_comment([$Id: runrec_class.so,v 10.19 2004/08/13 03:38:56 bostic Exp $])
define(M4PAGELOCAL, DbRunRecoveryException)
include(m4/m4.seealso)
m4_pf_header(m4_ref(DbRunRecoveryException),
ifelse(M4API, C_API, [dnl
])
ifelse(M4API, CXX_API, [dnl
class DbRunRecoveryException : public DbException { ... };
]))
m4_p([dnl
This information describes the m4_ref(DbRunRecoveryException) class and
how it is used by the various m4_db classes.])
m4_p([dnl
Errors can occur in the m4_db library where the only solution is to shut
down the application and run recovery (for example, if m4_db is unable
to allocate heap memory). When a fatal error occurs in m4_db, methods
will throw a m4_ref(DbRunRecoveryException), at which point all
subsequent m4_db calls will also fail in the same way. When this
occurs, recovery should be performed.])
m4_p([dnl
The m4_ref(DbException) errno value is set to DB_RUNRECOVERY.])
m4_page_footer