Deploy to GitHub pages
[awesomized/libmemcached] / libmemcached / examples.html
index e8cf02167730586f6285fcf122d5d4b03b5ff60c..891e59ba6487fdf96596eee7839f7062d91bb5cf 100644 (file)
   
     
       <script type="text/javascript" id="documentation_options" data-url_root="../" src="../_static/documentation_options.js"></script>
-        <script src="../_static/jquery.js"></script>
-        <script src="../_static/underscore.js"></script>
-        <script src="../_static/doctools.js"></script>
-        <script src="../_static/language_data.js"></script>
+        <script type="text/javascript" src="../_static/jquery.js"></script>
+        <script type="text/javascript" src="../_static/underscore.js"></script>
+        <script type="text/javascript" src="../_static/doctools.js"></script>
+        <script type="text/javascript" src="../_static/language_data.js"></script>
     
     <script type="text/javascript" src="../_static/js/theme.js"></script>
 
               
             
             
-              <p class="caption"><span class="caption-text">libmemcached</span></p>
-<ul class="current">
+              <ul class="current">
 <li class="toctree-l1"><a class="reference internal" href="../libmemcached.html">Introduction</a></li>
 <li class="toctree-l1"><a class="reference internal" href="index.html">libmemcached API</a></li>
-<li class="toctree-l1 current"><a class="reference internal" href="index_misc.html">Misc</a><ul class="current">
+<li class="toctree-l1"><a class="reference internal" href="../libmemcachedutil/index.html">libmemcachedutil API</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../libhashkit/index.html">libhashkit API</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../bin/index.html">Client Applications</a></li>
+<li class="toctree-l1 current"><a class="reference internal" href="index_misc.html">Miscellaneous</a><ul class="current">
 <li class="toctree-l2"><a class="reference internal" href="configuration.html">Configuration</a></li>
 <li class="toctree-l2"><a class="reference internal" href="constants.html">Constants</a></li>
 <li class="toctree-l2 current"><a class="current reference internal" href="#">Examples</a></li>
 </ul>
 </li>
 </ul>
-<p class="caption"><span class="caption-text">libmemcachedutil</span></p>
-<ul>
-<li class="toctree-l1"><a class="reference internal" href="../libmemcachedutil.html">Introduction</a></li>
-<li class="toctree-l1"><a class="reference internal" href="../libmemcachedutil/index.html">libmemcachedutil API</a></li>
-</ul>
-<p class="caption"><span class="caption-text">libhashkit</span></p>
-<ul>
-<li class="toctree-l1"><a class="reference internal" href="../libhashkit.html">Introduction</a></li>
-<li class="toctree-l1"><a class="reference internal" href="../libhashkit/index.html">libhashkit API</a></li>
-</ul>
-<p class="caption"><span class="caption-text">Client Applications</span></p>
-<ul>
-<li class="toctree-l1"><a class="reference internal" href="../bin/index.html">Client Applications</a></li>
-</ul>
-<p class="caption"><span class="caption-text">Copyright</span></p>
 <ul>
+<li class="toctree-l1"><a class="reference internal" href="../changelogs.html">Change Logs</a></li>
 <li class="toctree-l1"><a class="reference internal" href="../copyright.html">Copyright</a></li>
 </ul>
 
     
       <li><a href="../index.html">Docs</a> &raquo;</li>
         
-          <li><a href="index_misc.html">Misc</a> &raquo;</li>
+          <li><a href="index_misc.html">Miscellaneous</a> &raquo;</li>
         
       <li>libmemcached Examples</li>
     
       <li class="wy-breadcrumbs-aside">
         
             
+            
+              <a href="https://github.com/m6w6/libmemcached/blob/v1.x/docs/source/libmemcached/examples.rst" class="fa fa-github"> Edit on GitHub</a>
+            
+          
         
       </li>
     
 <p>Examples for libmemcached</p>
 <div class="section" id="description">
 <h2>DESCRIPTION<a class="headerlink" href="#description" title="Permalink to this headline">¶</a></h2>
-<p>For full examples, test cases are found in tests/*.c in the main
-distribution. These are always up to date, and are used for each test run of
-the library.</p>
+<p>For full examples, test cases are found in tests/*.c in the main distribution.
+These are always up to date, and are used for each test run of the library.</p>
 </div>
 <div class="section" id="connecting-to-servers">
 <h2>Connecting to servers<a class="headerlink" href="#connecting-to-servers" title="Permalink to this headline">¶</a></h2>
@@ -200,12 +191,15 @@ the library.</p>
  <span class="n">memcached_free</span><span class="p">(</span><span class="n">memc</span><span class="p">);</span>
 </pre></div>
 </div>
-<p>In the above code you create a <a class="reference internal" href="memcached_create.html#_CPPv412memcached_st" title="memcached_st"><code class="xref cpp cpp-type docutils literal notranslate"><span class="pre">memcached_st</span></code></a> object with three server
-by making use of <a class="reference internal" href="memcached_create.html#_CPPv416memcached_createP12memcached_st" title="memcached_create"><code class="xref cpp cpp-func docutils literal notranslate"><span class="pre">memcached_create()</span></code></a>.</p>
+<p>In the above code you create a <a class="reference internal" href="memcached_create.html#_CPPv412memcached_st" title="memcached_st"><code class="xref cpp cpp-any docutils literal notranslate"><span class="pre">memcached_st</span></code></a> object with three server by making
+use of <a class="reference internal" href="memcached_create.html#_CPPv416memcached_createP12memcached_st" title="memcached_create"><code class="xref cpp cpp-any docutils literal notranslate"><span class="pre">memcached_create()</span></code></a>.</p>
 </div>
 <div class="section" id="creating-a-pool-of-servers">
 <h2>Creating a pool of servers<a class="headerlink" href="#creating-a-pool-of-servers" title="Permalink to this headline">¶</a></h2>
-<div class="highlight-c notranslate"><div class="highlight"><pre><span></span><span class="k">const</span> <span class="kt">char</span> <span class="o">*</span><span class="n">config_string</span><span class="o">=</span> <span class="s">&quot;--SERVER=host10.example.com --SERVER=host11.example.com --SERVER=host10.example.com&quot;</span><span class="p">;</span>
+<div class="highlight-c notranslate"><div class="highlight"><pre><span></span><span class="k">const</span> <span class="kt">char</span> <span class="o">*</span><span class="n">config_string</span> <span class="o">=</span>
+  <span class="s">&quot;--SERVER=host10.example.com &quot;</span>
+  <span class="s">&quot;--SERVER=host11.example.com &quot;</span>
+  <span class="s">&quot;--SERVER=host10.example.com&quot;</span><span class="p">;</span>
 
 <span class="n">memcached_pool_st</span><span class="o">*</span> <span class="n">pool</span><span class="o">=</span> <span class="n">memcached_pool</span><span class="p">(</span><span class="n">config_string</span><span class="p">,</span> <span class="n">strlen</span><span class="p">(</span><span class="n">config_string</span><span class="p">));</span>
 
@@ -226,9 +220,9 @@ by making use of <a class="reference internal" href="memcached_create.html#_CPPv
 <span class="n">memcached_pool_destroy</span><span class="p">(</span><span class="n">pool</span><span class="p">);</span>
 </pre></div>
 </div>
-<p>In the above code you create a <a class="reference internal" href="../libmemcachedutil/memcached_pool.html#_CPPv417memcached_pool_st" title="memcached_pool_st"><code class="xref cpp cpp-type docutils literal notranslate"><span class="pre">memcached_pool_st</span></code></a> object with three
-server by making use of <a class="reference internal" href="../libmemcachedutil/memcached_pool.html#_CPPv414memcached_poolPKc6size_t" title="memcached_pool"><code class="xref cpp cpp-func docutils literal notranslate"><span class="pre">memcached_pool()</span></code></a>.</p>
-<p>When <a class="reference internal" href="../libmemcachedutil/memcached_pool.html#_CPPv422memcached_pool_destroyP17memcached_pool_st" title="memcached_pool_destroy"><code class="xref cpp cpp-func docutils literal notranslate"><span class="pre">memcached_pool_destroy()</span></code></a> all memory will be released that is associated
+<p>In the above code you create a <a class="reference internal" href="../libmemcachedutil/memcached_pool.html#_CPPv417memcached_pool_st" title="memcached_pool_st"><code class="xref cpp cpp-any docutils literal notranslate"><span class="pre">memcached_pool_st</span></code></a> object with three server by
+making use of <a class="reference internal" href="../libmemcachedutil/memcached_pool.html#_CPPv414memcached_poolPKc6size_t" title="memcached_pool"><code class="xref cpp cpp-any docutils literal notranslate"><span class="pre">memcached_pool()</span></code></a>.</p>
+<p>When <a class="reference internal" href="../libmemcachedutil/memcached_pool.html#_CPPv422memcached_pool_destroyP17memcached_pool_st" title="memcached_pool_destroy"><code class="xref cpp cpp-any docutils literal notranslate"><span class="pre">memcached_pool_destroy()</span></code></a> all memory will be released that is associated
 with the pool.</p>
 </div>
 <div class="section" id="adding-a-value-to-the-server">
@@ -281,8 +275,7 @@ with the pool.</p>
 <div class="section" id="see-also">
 <h2>SEE ALSO<a class="headerlink" href="#see-also" title="Permalink to this headline">¶</a></h2>
 <blockquote>
-<div><p><em class="manpage"><a class="manpage reference external" href="http://man7.org/linux/man-pages/man1/memcached.1.html">memcached(1)</a></em></p>
-</div></blockquote>
+<div><em class="manpage"><a class="manpage reference external" href="https://linux.die.net/man/1/memcached">memcached(1)</a></em></div></blockquote>
 </div>
 </div>