<!--$Id: rep_nsites.so,v 1.2 2006/06/23 01:28:47 alanb Exp $--> <!--Copyright (c) 1997,2007 Oracle. All rights reserved.--> <!--See the file LICENSE for redistribution information.--> <html> <head> <title>Berkeley DB: DbEnv::rep_set_nsites</title> <meta name="description" content="Berkeley DB: An embedded database programmatic toolkit."> <meta name="keywords" content="embedded,database,programmatic,toolkit,btree,hash,hashing,transaction,transactions,locking,logging,access method,access methods,Java,C,C++"> </head> <body bgcolor=white> <table width="100%"><tr valign=top> <td> <h3>DbEnv::rep_set_nsites</h3> </td> <td align=right> <a href="../../db46-devel-4.6.21/api_cxx/api_core.html"><img src="../../db46-devel-4.6.21/images/api.gif" alt="API"></a> <a href="../../db46-devel-4.6.21/ref/toc.html"><img src="../../db46-devel-4.6.21/images/ref.gif" alt="Ref"></a></td> </tr></table> <hr size=1 noshade> <tt> <h3><pre> #include <db_cxx.h> <p> int DbEnv::rep_set_nsites(int nsites); <p> int DbEnv::rep_get_nsites(int *nsitesp); </pre></h3> <hr size=1 noshade> <h3>Description: DbEnv::rep_set_nsites</h3> <p>The DbEnv::rep_set_nsites method specifies the total number of sites in a replication group.</p> <p>The DbEnv::rep_set_nsites method is typically called by applications which use the Berkeley DB library "replication manager" support. (However, see also the <a href="../../db46-devel-4.6.21/api_cxx/rep_elect.html">DbEnv::rep_elect</a> man page, the description of the <b>nsites</b> parameter.)</p> <p>The DbEnv::rep_set_nsites method configures a database environment, not only operations performed using the specified <a href="../../db46-devel-4.6.21/api_cxx/env_class.html">DbEnv</a> handle.</p> <p>The DbEnv::rep_set_nsites method may be called at any time during the life of the application.</p> <p>The DbEnv::rep_set_nsites 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. </p> <h3>Parameters</h3> <dl compact> <dt><b>nsites</b><dd>A positive integer specifying the total number of sites in the replication group. </dl> <hr size=1 noshade> <h3>Description: DbEnv::rep_get_nsites</h3> <p>The DbEnv::rep_get_nsites method returns the total number of sites in the replication group.</p> <p>The DbEnv::rep_get_nsites method may be called at any time during the life of the application.</p> <p>The DbEnv::rep_get_nsites 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. </p> <h3>Parameters</h3> <dl compact> <dt><b>nsitesp</b><dd>The DbEnv::rep_get_nsites method returns the total number of sites in the replication group in <b>nsitesp</b>. </dl> <hr size=1 noshade> <h3>Class</h3> <a href="../../db46-devel-4.6.21/api_cxx/env_class.html">DbEnv</a> <h3>See Also</h3> <a href="../../db46-devel-4.6.21/api_cxx/rep_list.html">Replication and Related Methods</a> </tt> <table width="100%"><tr><td><br></td><td align=right> <a href="../../db46-devel-4.6.21/api_cxx/api_core.html"><img src="../../db46-devel-4.6.21/images/api.gif" alt="API"></a><a href="../../db46-devel-4.6.21/ref/toc.html"><img src="../../db46-devel-4.6.21/images/ref.gif" alt="Ref"></a> </td></tr></table> <p><font size=1>Copyright (c) 1996,2007 Oracle. All rights reserved.</font> </body> </html>