Berkeley DB Reference Version 5.3.33

DB_MPOOLFILE->put()

#include <db.h>

int
DB_MPOOLFILE->put(DB_MPOOLFILE *mpf,
    void *pgaddr, DB_CACHE_PRIORITY priority, u_int32_t flags);  

The DB_MPOOLFILE->put() method returns a reference to a page in the cache, setting the priority of the page as specified by the priority parameter.

The DB_MPOOLFILE->put() method returns a non-zero error value on failure and 0 on success.

Parameters

pgaddr

The pgaddr parameter is the address of the page to be returned to the cache. The pgaddr parameter must be a value previously returned by the DB_MPOOLFILE->get() method.

priority

Set the page's priority as follows:

flags

The flags parameter is currently unused, and must be set to 0.

Errors

The DB_MPOOLFILE->put() method may fail and return one of the following non-zero errors:

EINVAL

An invalid flag value or parameter was specified.

Class

DB_ENV, DB_MPOOLFILE

See Also

Memory Pools and Related Methods