DbMpoolFile::put |

`

    #include <db_cxx.h>

    int
    DbMpoolFile::put(void *pgaddr, DB_CACHE_PRIORITY priority, u_int32_t flags);

Description: DbMpoolFile::put

The DbMpoolFile::put method returns a reference to a page in the cache, setting the priority of the page as specified by the priority parameter.

The DbMpoolFile::put method either returns a non-zero error value or throws an exception that encapsulates a non-zero error value on failure, and returns 0 on success.

Parameters
flags

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

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 DbMpoolFile::get method.

priority

- Set the page's priority as follows:
  DB_PRIORITY_UNCHANGED
  - The priority is unchanged.
  DB_PRIORITY_VERY_LOW
  - The lowest priority: pages are the most likely to be discarded.
  DB_PRIORITY_LOW
  - The next lowest priority.
  DB_PRIORITY_DEFAULT
  - The default priority.
  DB_PRIORITY_HIGH
  - The next highest priority.
  DB_PRIORITY_VERY_HIGH
  - The highest priority: pages are the least likely to be discarded.

Errors

The DbMpoolFile::put method may fail and throw DbException, encapsulating one of the following non-zero errors, or return one of the following non-zero errors:

EINVAL

- An invalid flag value or parameter was specified.

Class DbEnv, DbMpoolFile
See Also Memory Pools and Related Methods`

Copyright (c) 1996,2008 Oracle. All rights reserved.