<divid="projectbrief">cpp_redis is a C++11 Asynchronous Multi-Platform Lightweight Redis Client, with support for synchronous operations and pipelining.</div>
<trclass="memdesc:a7f9e56873e5b96ad9cb2395dadae1a7a"><tdclass="mdescLeft"> </td><tdclass="mdescRight">connect handler, called whenever a new connection even occurred <br/></td></tr>
<trclass="memdesc:a5533ac876d3116911b54ff0dce28f61c"><tdclass="mdescLeft"> </td><tdclass="mdescRight">reply callback called whenever a reply is received, takes as parameter the received reply <br/></td></tr>
<trclass="memdesc:a6ae8134a9a9b31d6f2434ec4f6e86d3a"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Connect to redis server. <ahref="#a6ae8134a9a9b31d6f2434ec4f6e86d3a">More...</a><br/></td></tr>
<trclass="memdesc:a8fb77a44a1e1f0d99dec639658e2aa7e"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Connect to redis server. <ahref="#a8fb77a44a1e1f0d99dec639658e2aa7e">More...</a><br/></td></tr>
<trclass="memdesc:aad1d0c3c6edb1522eb7b1bdb64b4705d"><tdclass="mdescLeft"> </td><tdclass="mdescRight">disconnect from redis server <ahref="#aad1d0c3c6edb1522eb7b1bdb64b4705d">More...</a><br/></td></tr>
<trclass="memdesc:a8df4503f738566d2acab5f080cd44b53"><tdclass="mdescLeft"> </td><tdclass="mdescRight">determines if reconnect is in progress <ahref="#a8df4503f738566d2acab5f080cd44b53">More...</a><br/></td></tr>
<trclass="memdesc:ae93de179d6ea83ece59cf1a30493c3e9"><tdclass="mdescLeft"> </td><tdclass="mdescRight">stop any reconnect in progress <br/></td></tr>
<trclass="memdesc:a7b4564fc4dfe356b95aeae4fdb8071c9"><tdclass="mdescLeft"> </td><tdclass="mdescRight">ability to authenticate on the redis server if necessary this method should not be called repeatedly as the storage of reply_callback is NOT thread safe (only one reply callback is stored for the subscriber client) calling repeatedly <aclass="el" href="classcpp__redis_1_1subscriber.html#a7b4564fc4dfe356b95aeae4fdb8071c9" title="ability to authenticate on the redis server if necessary this method should not be called repeatedly ...">auth()</a> is undefined concerning the execution of the associated callbacks <ahref="#a7b4564fc4dfe356b95aeae4fdb8071c9">More...</a><br/></td></tr>
<divclass="textblock"><p>The <aclass="el" href="classcpp__redis_1_1subscriber.html">cpp_redis::subscriber</a> is meant to be used for PUB/SUB communication with the Redis server. Please do not use <aclass="el" href="classcpp__redis_1_1client.html">cpp_redis::client</a> to subscribe to some Redis channels as:</p><ul>
<li>the behavior is undefined</li>
<li><aclass="el" href="classcpp__redis_1_1client.html">cpp_redis::client</a> is not meant for that </li>
<p>acknowledgment callback called whenever a subscribe completes takes as parameter the int returned by the redis server (usually the number of channels you are subscribed to) </p>
<p>add a sentinel definition. Required for <aclass="el" href="classcpp__redis_1_1subscriber.html#a6ae8134a9a9b31d6f2434ec4f6e86d3a" title="Connect to redis server. ">connect()</a> or get_master_addr_by_name() when autoconnect is enabled.</p>
<p>ability to authenticate on the redis server if necessary this method should not be called repeatedly as the storage of reply_callback is NOT thread safe (only one reply callback is stored for the subscriber client) calling repeatedly <aclass="el" href="classcpp__redis_1_1subscriber.html#a7b4564fc4dfe356b95aeae4fdb8071c9" title="ability to authenticate on the redis server if necessary this method should not be called repeatedly ...">auth()</a> is undefined concerning the execution of the associated callbacks </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">password</td><td>password to be used for authentication </td></tr>
<tr><tdclass="paramname">reply_callback</td><td>callback to be called on auth completion (nullable) </td></tr>
<p>commit pipelined transaction that is, send to the network all commands pipelined by calling send() / <aclass="el" href="classcpp__redis_1_1subscriber.html#afee579c702182041645a3d3c55de4b9e">subscribe()</a> / ...</p>
<tr><tdclass="paramname">wait_for_removal</td><td>when set to true, disconnect blocks until the underlying TCP client has been effectively removed from the io_service and that all the underlying callbacks have completed. </td></tr>
<li>calls acknowledgement_callback once the server has acknowledged about the subscription.</li>
<li>calls read_callback each time a message is published on this channel. The command is not effectively sent immediately but stored in an internal buffer until <aclass="el" href="classcpp__redis_1_1subscriber.html#af78a5542315daac42998809eeec30eef">commit()</a> is called.</li>
</ul>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">pattern</td><td>pattern to psubscribe </td></tr>
<tr><tdclass="paramname">callback</td><td>callback to be called whenever a message is received for this pattern </td></tr>
<tr><tdclass="paramname">acknowledgement_callback</td><td>callback to be called on subscription completion (nullable) </td></tr>
<p>punsubscribe from the given pattern The command is not effectively sent immediately, but stored inside an internal buffer until <aclass="el" href="classcpp__redis_1_1subscriber.html#af78a5542315daac42998809eeec30eef">commit()</a> is called.</p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">pattern</td><td>pattern to punsubscribe from </td></tr>
<li>calls acknowledgement_callback once the server has acknowledged about the subscription.</li>
<li>calls read_callback each time a message is published on this channel. The command is not effectively sent immediately but stored in an internal buffer until <aclass="el" href="classcpp__redis_1_1subscriber.html#af78a5542315daac42998809eeec30eef">commit()</a> is called.</li>
</ul>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">channel</td><td>channel to subscribe </td></tr>
<tr><tdclass="paramname">callback</td><td>callback to be called whenever a message is received for this channel </td></tr>
<tr><tdclass="paramname">acknowledgement_callback</td><td>callback to be called on subscription completion (nullable) </td></tr>
<p>unsubscribe from the given channel The command is not effectively sent immediately, but stored inside an internal buffer until <aclass="el" href="classcpp__redis_1_1subscriber.html#af78a5542315daac42998809eeec30eef">commit()</a> is called.</p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">channel</td><td>channel to unsubscribe from </td></tr>