add doc: array comparisons

This commit is contained in:
Bolero-MURAKAMI 2013-08-29 22:39:54 +09:00
parent ed85c56acc
commit 4b21f64ea9
30 changed files with 1839 additions and 95 deletions

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-equal_to:
###############################################################################
operator==
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator==(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the containers are equivalent, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
static_assert(x == y, "x is equal to y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-greater:
###############################################################################
operator>
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator>(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically greater than the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(y > x, "y is greater than x.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-greater_equal:
###############################################################################
operator>=
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator>=(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically greater than or equal the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(y >= x, "y is greater than or equal to x.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-less:
###############################################################################
operator<
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator<(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically less than the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(x < y, "x is less than y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-less_equal:
###############################################################################
operator<=
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator<=(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically less than or equal the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(x <= y, "x is less than or equal to y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-not_equal_to:
###############################################################################
operator!=
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator!=(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the containers are not equivalent, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(x != y, "x is not equal to y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,49 @@
.. _sprout-array-array-swap-global:
###############################################################################
swap
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline void
swap(sprout::array<T, N>& lhs, sprout::array<T, N>& rhs)
SPROUT_NOEXCEPT_EXPR(SPROUT_NOEXCEPT_EXPR(lhs.swap(rhs)));
Effects
========================================
| ``lhs.swap(y)``.
Throws
========================================
| Nothing unless ``lhs.swap(y)`` throws an exception.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
#include <sprout/assert.hpp>
using namespace sprout;
auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
swap(x, y);
SPROUT_ASSERT_MSG(x[0] = 10 && y[0] == 1, "each element are swapped.");
Complexity
========================================
| linear in N.
| Recursive function invocations in *O(1)* (constant) depth.
Header
========================================
| ``sprout/array/array.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -9,7 +9,7 @@ Interface
void swap(array& y) SPROUT_NOEXCEPT_EXPR(SPROUT_NOEXCEPT_EXPR(std::swap(std::declval<T&>(), std::declval<T&>())));
Returns
Effects
========================================
| ``swap_ranges(begin(), end(), y.begin())``.
@ -35,7 +35,7 @@ Examples
Complexity
========================================
| Linear.
| linear in N.
| Recursive function invocations in *O(1)* (constant) depth.
Header

View file

@ -7,6 +7,13 @@ Sprout.Array
:hidden:
array/index
array/swap-global
array/operator-equal_to
array/operator-not_equal_to
array/operator-less
array/operator-greater
array/operator-less_equal
array/operator-greater_equal
to_array
make_array
make_common_array
@ -26,17 +33,6 @@ class
Non-member functions
----------------------------------------
array generators
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
============================================================ ===============================================================================
function
============================================================ ===============================================================================
:doc:`to_array <./to_array>`
:doc:`make_array <./make_array>`
:doc:`make_common_array <./make_common_array>`
============================================================ ===============================================================================
specialized algorithms
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@ -60,6 +56,17 @@ function
:doc:`operator= <./array/operator-greater_equal>`
============================================================ ===============================================================================
array generators
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
============================================================ ===============================================================================
function
============================================================ ===============================================================================
:doc:`to_array <./to_array>`
:doc:`make_array <./make_array>`
:doc:`make_common_array <./make_common_array>`
============================================================ ===============================================================================
Tuple interface
----------------------------------------

View file

@ -21,7 +21,7 @@
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="array" href="index.html" />
<link rel="next" title="to_array" href="../to_array.html" />
<link rel="next" title="swap" href="swap-global.html" />
<link rel="prev" title="back" href="data.html" />
</head>
<body>
@ -32,7 +32,7 @@
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="../to_array.html" title="to_array"
<a href="swap-global.html" title="swap"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="data.html" title="back"
@ -62,8 +62,8 @@
<p class="topless"><a href="data.html"
title="previous chapter">back</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="../to_array.html"
title="next chapter">to_array</a></p>
<p class="topless"><a href="swap-global.html"
title="next chapter">swap</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/c_array.txt"
@ -144,7 +144,7 @@
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="../to_array.html" title="to_array"
<a href="swap-global.html" title="swap"
>next</a> |</li>
<li class="right" >
<a href="data.html" title="back"

View file

@ -0,0 +1,163 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>operator== &mdash; Sprout v1.0 documentation</title>
<link rel="stylesheet" href="../../../../_static/sphinxdoc.css" type="text/css" />
<link rel="stylesheet" href="../../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../../',
VERSION: '1.0',
COLLAPSE_MODINDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="Sprout.Array" href="../index.html" />
<link rel="next" title="operator!=" href="operator-not_equal_to.html" />
<link rel="prev" title="swap" href="swap-global.html" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="operator-not_equal_to.html" title="operator!="
accesskey="N">next</a> |</li>
<li class="right" >
<a href="swap-global.html" title="swap"
accesskey="P">previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" accesskey="U">Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../../../../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference external" href="#">operator==</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#returns">Returns</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
<li><a class="reference external" href="#header">Header</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="swap-global.html"
title="previous chapter">swap</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="operator-not_equal_to.html"
title="next chapter">operator!=</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/operator-equal_to.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="../../../../search.html" method="get">
<input type="text" name="q" size="18" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="operator">
<h1>operator==<a class="headerlink" href="#operator" title="Permalink to this headline"></a></h1>
<div class="section" id="interface">
<h2>Interface<a class="headerlink" href="#interface" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">T</span><span class="p">,</span> <span class="n">std</span><span class="o">::</span><span class="n">size_t</span> <span class="n">N</span><span class="o">&gt;</span>
<span class="kr">inline</span> <span class="n">SPROUT_CONSTEXPR</span> <span class="kt">bool</span>
<span class="k">operator</span><span class="o">==</span><span class="p">(</span><span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">lhs</span><span class="p">,</span> <span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">rhs</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="returns">
<h2>Returns<a class="headerlink" href="#returns" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">true if the contents of the containers are equivalent, false otherwise.</div>
</div>
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="cp">#include &lt;sprout/array.hpp&gt;</span>
<span class="k">using</span> <span class="k">namespace</span> <span class="n">sprout</span><span class="p">;</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">x</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">y</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="n">static_assert</span><span class="p">(</span><span class="n">x</span> <span class="o">==</span> <span class="n">y</span><span class="p">,</span> <span class="s">&quot;x is equal to y.&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Recursive function invocations in <em>O(logN)</em> (logarithmic) depth.</div>
</div>
</div>
<div class="section" id="header">
<h2>Header<a class="headerlink" href="#header" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">sprout/array/comparison.hpp</span></tt></div>
<div class="line">Convenience header: <tt class="docutils literal"><span class="pre">sprout/array.hpp</span></tt></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="operator-not_equal_to.html" title="operator!="
>next</a> |</li>
<li class="right" >
<a href="swap-global.html" title="swap"
>previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" >Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; Copyright 2013, Bolero MURAKAMI.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.4.
</div>
</body>
</html>

View file

@ -0,0 +1,163 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>operator> &mdash; Sprout v1.0 documentation</title>
<link rel="stylesheet" href="../../../../_static/sphinxdoc.css" type="text/css" />
<link rel="stylesheet" href="../../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../../',
VERSION: '1.0',
COLLAPSE_MODINDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="Sprout.Array" href="../index.html" />
<link rel="next" title="operator<=" href="operator-less_equal.html" />
<link rel="prev" title="operator<" href="operator-less.html" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="operator-less_equal.html" title="operator<="
accesskey="N">next</a> |</li>
<li class="right" >
<a href="operator-less.html" title="operator<"
accesskey="P">previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" accesskey="U">Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../../../../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference external" href="#">operator&gt;</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#returns">Returns</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
<li><a class="reference external" href="#header">Header</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="operator-less.html"
title="previous chapter">operator&lt;</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="operator-less_equal.html"
title="next chapter">operator&lt;=</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/operator-greater.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="../../../../search.html" method="get">
<input type="text" name="q" size="18" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="operator">
<h1>operator&gt;<a class="headerlink" href="#operator" title="Permalink to this headline"></a></h1>
<div class="section" id="interface">
<h2>Interface<a class="headerlink" href="#interface" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">T</span><span class="p">,</span> <span class="n">std</span><span class="o">::</span><span class="n">size_t</span> <span class="n">N</span><span class="o">&gt;</span>
<span class="kr">inline</span> <span class="n">SPROUT_CONSTEXPR</span> <span class="kt">bool</span>
<span class="k">operator</span><span class="o">&gt;</span><span class="p">(</span><span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">lhs</span><span class="p">,</span> <span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">rhs</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="returns">
<h2>Returns<a class="headerlink" href="#returns" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">true if the contents of the lhs are lexicographically greater than the contents of rhs, false otherwise.</div>
</div>
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="cp">#include &lt;sprout/array.hpp&gt;</span>
<span class="k">using</span> <span class="k">namespace</span> <span class="n">sprout</span><span class="p">;</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">x</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">y</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">10</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">1</span><span class="p">}};</span>
<span class="n">static_assert</span><span class="p">(</span><span class="n">y</span> <span class="o">&gt;</span> <span class="n">x</span><span class="p">,</span> <span class="s">&quot;y is greater than x.&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Recursive function invocations in <em>O(logN)</em> (logarithmic) depth.</div>
</div>
</div>
<div class="section" id="header">
<h2>Header<a class="headerlink" href="#header" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">sprout/array/comparison.hpp</span></tt></div>
<div class="line">Convenience header: <tt class="docutils literal"><span class="pre">sprout/array.hpp</span></tt></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="operator-less_equal.html" title="operator<="
>next</a> |</li>
<li class="right" >
<a href="operator-less.html" title="operator<"
>previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" >Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; Copyright 2013, Bolero MURAKAMI.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.4.
</div>
</body>
</html>

View file

@ -0,0 +1,163 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>operator>= &mdash; Sprout v1.0 documentation</title>
<link rel="stylesheet" href="../../../../_static/sphinxdoc.css" type="text/css" />
<link rel="stylesheet" href="../../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../../',
VERSION: '1.0',
COLLAPSE_MODINDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="Sprout.Array" href="../index.html" />
<link rel="next" title="to_array" href="../to_array.html" />
<link rel="prev" title="operator<=" href="operator-less_equal.html" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="../to_array.html" title="to_array"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="operator-less_equal.html" title="operator<="
accesskey="P">previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" accesskey="U">Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../../../../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference external" href="#">operator&gt;=</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#returns">Returns</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
<li><a class="reference external" href="#header">Header</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="operator-less_equal.html"
title="previous chapter">operator&lt;=</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="../to_array.html"
title="next chapter">to_array</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/operator-greater_equal.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="../../../../search.html" method="get">
<input type="text" name="q" size="18" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="operator">
<h1>operator&gt;=<a class="headerlink" href="#operator" title="Permalink to this headline"></a></h1>
<div class="section" id="interface">
<h2>Interface<a class="headerlink" href="#interface" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">T</span><span class="p">,</span> <span class="n">std</span><span class="o">::</span><span class="n">size_t</span> <span class="n">N</span><span class="o">&gt;</span>
<span class="kr">inline</span> <span class="n">SPROUT_CONSTEXPR</span> <span class="kt">bool</span>
<span class="k">operator</span><span class="o">&gt;=</span><span class="p">(</span><span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">lhs</span><span class="p">,</span> <span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">rhs</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="returns">
<h2>Returns<a class="headerlink" href="#returns" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">true if the contents of the lhs are lexicographically greater than or equal the contents of rhs, false otherwise.</div>
</div>
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="cp">#include &lt;sprout/array.hpp&gt;</span>
<span class="k">using</span> <span class="k">namespace</span> <span class="n">sprout</span><span class="p">;</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">x</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">y</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">10</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">1</span><span class="p">}};</span>
<span class="n">static_assert</span><span class="p">(</span><span class="n">y</span> <span class="o">&gt;=</span> <span class="n">x</span><span class="p">,</span> <span class="s">&quot;y is greater than or equal to x.&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Recursive function invocations in <em>O(logN)</em> (logarithmic) depth.</div>
</div>
</div>
<div class="section" id="header">
<h2>Header<a class="headerlink" href="#header" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">sprout/array/comparison.hpp</span></tt></div>
<div class="line">Convenience header: <tt class="docutils literal"><span class="pre">sprout/array.hpp</span></tt></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="../to_array.html" title="to_array"
>next</a> |</li>
<li class="right" >
<a href="operator-less_equal.html" title="operator<="
>previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" >Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; Copyright 2013, Bolero MURAKAMI.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.4.
</div>
</body>
</html>

View file

@ -0,0 +1,163 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>operator< &mdash; Sprout v1.0 documentation</title>
<link rel="stylesheet" href="../../../../_static/sphinxdoc.css" type="text/css" />
<link rel="stylesheet" href="../../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../../',
VERSION: '1.0',
COLLAPSE_MODINDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="Sprout.Array" href="../index.html" />
<link rel="next" title="operator>" href="operator-greater.html" />
<link rel="prev" title="operator!=" href="operator-not_equal_to.html" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="operator-greater.html" title="operator>"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="operator-not_equal_to.html" title="operator!="
accesskey="P">previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" accesskey="U">Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../../../../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference external" href="#">operator&lt;</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#returns">Returns</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
<li><a class="reference external" href="#header">Header</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="operator-not_equal_to.html"
title="previous chapter">operator!=</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="operator-greater.html"
title="next chapter">operator&gt;</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/operator-less.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="../../../../search.html" method="get">
<input type="text" name="q" size="18" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="operator">
<h1>operator&lt;<a class="headerlink" href="#operator" title="Permalink to this headline"></a></h1>
<div class="section" id="interface">
<h2>Interface<a class="headerlink" href="#interface" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">T</span><span class="p">,</span> <span class="n">std</span><span class="o">::</span><span class="n">size_t</span> <span class="n">N</span><span class="o">&gt;</span>
<span class="kr">inline</span> <span class="n">SPROUT_CONSTEXPR</span> <span class="kt">bool</span>
<span class="k">operator</span><span class="o">&lt;</span><span class="p">(</span><span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">lhs</span><span class="p">,</span> <span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">rhs</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="returns">
<h2>Returns<a class="headerlink" href="#returns" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">true if the contents of the lhs are lexicographically less than the contents of rhs, false otherwise.</div>
</div>
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="cp">#include &lt;sprout/array.hpp&gt;</span>
<span class="k">using</span> <span class="k">namespace</span> <span class="n">sprout</span><span class="p">;</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">x</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">y</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">10</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">1</span><span class="p">}};</span>
<span class="n">static_assert</span><span class="p">(</span><span class="n">x</span> <span class="o">&lt;</span> <span class="n">y</span><span class="p">,</span> <span class="s">&quot;x is less than y.&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Recursive function invocations in <em>O(logN)</em> (logarithmic) depth.</div>
</div>
</div>
<div class="section" id="header">
<h2>Header<a class="headerlink" href="#header" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">sprout/array/comparison.hpp</span></tt></div>
<div class="line">Convenience header: <tt class="docutils literal"><span class="pre">sprout/array.hpp</span></tt></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="operator-greater.html" title="operator>"
>next</a> |</li>
<li class="right" >
<a href="operator-not_equal_to.html" title="operator!="
>previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" >Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; Copyright 2013, Bolero MURAKAMI.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.4.
</div>
</body>
</html>

View file

@ -0,0 +1,163 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>operator<= &mdash; Sprout v1.0 documentation</title>
<link rel="stylesheet" href="../../../../_static/sphinxdoc.css" type="text/css" />
<link rel="stylesheet" href="../../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../../',
VERSION: '1.0',
COLLAPSE_MODINDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="Sprout.Array" href="../index.html" />
<link rel="next" title="operator>=" href="operator-greater_equal.html" />
<link rel="prev" title="operator>" href="operator-greater.html" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="operator-greater_equal.html" title="operator>="
accesskey="N">next</a> |</li>
<li class="right" >
<a href="operator-greater.html" title="operator>"
accesskey="P">previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" accesskey="U">Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../../../../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference external" href="#">operator&lt;=</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#returns">Returns</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
<li><a class="reference external" href="#header">Header</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="operator-greater.html"
title="previous chapter">operator&gt;</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="operator-greater_equal.html"
title="next chapter">operator&gt;=</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/operator-less_equal.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="../../../../search.html" method="get">
<input type="text" name="q" size="18" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="operator">
<h1>operator&lt;=<a class="headerlink" href="#operator" title="Permalink to this headline"></a></h1>
<div class="section" id="interface">
<h2>Interface<a class="headerlink" href="#interface" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">T</span><span class="p">,</span> <span class="n">std</span><span class="o">::</span><span class="n">size_t</span> <span class="n">N</span><span class="o">&gt;</span>
<span class="kr">inline</span> <span class="n">SPROUT_CONSTEXPR</span> <span class="kt">bool</span>
<span class="k">operator</span><span class="o">&lt;=</span><span class="p">(</span><span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">lhs</span><span class="p">,</span> <span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">rhs</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="returns">
<h2>Returns<a class="headerlink" href="#returns" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">true if the contents of the lhs are lexicographically less than or equal the contents of rhs, false otherwise.</div>
</div>
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="cp">#include &lt;sprout/array.hpp&gt;</span>
<span class="k">using</span> <span class="k">namespace</span> <span class="n">sprout</span><span class="p">;</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">x</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">y</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">10</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">1</span><span class="p">}};</span>
<span class="n">static_assert</span><span class="p">(</span><span class="n">x</span> <span class="o">&lt;=</span> <span class="n">y</span><span class="p">,</span> <span class="s">&quot;x is less than or equal to y.&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Recursive function invocations in <em>O(logN)</em> (logarithmic) depth.</div>
</div>
</div>
<div class="section" id="header">
<h2>Header<a class="headerlink" href="#header" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">sprout/array/comparison.hpp</span></tt></div>
<div class="line">Convenience header: <tt class="docutils literal"><span class="pre">sprout/array.hpp</span></tt></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="operator-greater_equal.html" title="operator>="
>next</a> |</li>
<li class="right" >
<a href="operator-greater.html" title="operator>"
>previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" >Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; Copyright 2013, Bolero MURAKAMI.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.4.
</div>
</body>
</html>

View file

@ -0,0 +1,163 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>operator!= &mdash; Sprout v1.0 documentation</title>
<link rel="stylesheet" href="../../../../_static/sphinxdoc.css" type="text/css" />
<link rel="stylesheet" href="../../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../../',
VERSION: '1.0',
COLLAPSE_MODINDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="Sprout.Array" href="../index.html" />
<link rel="next" title="operator<" href="operator-less.html" />
<link rel="prev" title="operator==" href="operator-equal_to.html" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="operator-less.html" title="operator<"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="operator-equal_to.html" title="operator=="
accesskey="P">previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" accesskey="U">Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../../../../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference external" href="#">operator!=</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#returns">Returns</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
<li><a class="reference external" href="#header">Header</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="operator-equal_to.html"
title="previous chapter">operator==</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="operator-less.html"
title="next chapter">operator&lt;</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/operator-not_equal_to.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="../../../../search.html" method="get">
<input type="text" name="q" size="18" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="operator">
<h1>operator!=<a class="headerlink" href="#operator" title="Permalink to this headline"></a></h1>
<div class="section" id="interface">
<h2>Interface<a class="headerlink" href="#interface" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">T</span><span class="p">,</span> <span class="n">std</span><span class="o">::</span><span class="n">size_t</span> <span class="n">N</span><span class="o">&gt;</span>
<span class="kr">inline</span> <span class="n">SPROUT_CONSTEXPR</span> <span class="kt">bool</span>
<span class="k">operator</span><span class="o">!=</span><span class="p">(</span><span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">lhs</span><span class="p">,</span> <span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;</span> <span class="k">const</span><span class="o">&amp;</span> <span class="n">rhs</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="returns">
<h2>Returns<a class="headerlink" href="#returns" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">true if the contents of the containers are not equivalent, false otherwise.</div>
</div>
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="cp">#include &lt;sprout/array.hpp&gt;</span>
<span class="k">using</span> <span class="k">namespace</span> <span class="n">sprout</span><span class="p">;</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">x</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="n">SPROUT_STATIC_CONSTEXPR</span> <span class="k">auto</span> <span class="n">y</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">10</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">1</span><span class="p">}};</span>
<span class="n">static_assert</span><span class="p">(</span><span class="n">x</span> <span class="o">!=</span> <span class="n">y</span><span class="p">,</span> <span class="s">&quot;x is not equal to y.&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Recursive function invocations in <em>O(logN)</em> (logarithmic) depth.</div>
</div>
</div>
<div class="section" id="header">
<h2>Header<a class="headerlink" href="#header" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">sprout/array/comparison.hpp</span></tt></div>
<div class="line">Convenience header: <tt class="docutils literal"><span class="pre">sprout/array.hpp</span></tt></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="operator-less.html" title="operator<"
>next</a> |</li>
<li class="right" >
<a href="operator-equal_to.html" title="operator=="
>previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" >Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; Copyright 2013, Bolero MURAKAMI.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.4.
</div>
</body>
</html>

View file

@ -0,0 +1,174 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>swap &mdash; Sprout v1.0 documentation</title>
<link rel="stylesheet" href="../../../../_static/sphinxdoc.css" type="text/css" />
<link rel="stylesheet" href="../../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../../',
VERSION: '1.0',
COLLAPSE_MODINDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../../_static/doctools.js"></script>
<link rel="top" title="Sprout v1.0 documentation" href="../../../../index.html" />
<link rel="up" title="Sprout.Array" href="../index.html" />
<link rel="next" title="operator==" href="operator-equal_to.html" />
<link rel="prev" title="back" href="c_array.html" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="operator-equal_to.html" title="operator=="
accesskey="N">next</a> |</li>
<li class="right" >
<a href="c_array.html" title="back"
accesskey="P">previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" accesskey="U">Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../../../../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference external" href="#">swap</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#effects">Effects</a></li>
<li><a class="reference external" href="#throws">Throws</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
<li><a class="reference external" href="#header">Header</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="c_array.html"
title="previous chapter">back</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="operator-equal_to.html"
title="next chapter">operator==</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../../../_sources/libs/sprout/array/array/swap-global.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="../../../../search.html" method="get">
<input type="text" name="q" size="18" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="swap">
<h1>swap<a class="headerlink" href="#swap" title="Permalink to this headline"></a></h1>
<div class="section" id="interface">
<h2>Interface<a class="headerlink" href="#interface" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">T</span><span class="p">,</span> <span class="n">std</span><span class="o">::</span><span class="n">size_t</span> <span class="n">N</span><span class="o">&gt;</span>
<span class="kr">inline</span> <span class="kt">void</span>
<span class="n">swap</span><span class="p">(</span><span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;&amp;</span> <span class="n">lhs</span><span class="p">,</span> <span class="n">sprout</span><span class="o">::</span><span class="n">array</span><span class="o">&lt;</span><span class="n">T</span><span class="p">,</span> <span class="n">N</span><span class="o">&gt;&amp;</span> <span class="n">rhs</span><span class="p">)</span>
<span class="n">SPROUT_NOEXCEPT_EXPR</span><span class="p">(</span><span class="n">SPROUT_NOEXCEPT_EXPR</span><span class="p">(</span><span class="n">lhs</span><span class="p">.</span><span class="n">swap</span><span class="p">(</span><span class="n">rhs</span><span class="p">)));</span>
</pre></div>
</div>
</div>
<div class="section" id="effects">
<h2>Effects<a class="headerlink" href="#effects" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">lhs.swap(y)</span></tt>.</div>
</div>
</div>
<div class="section" id="throws">
<h2>Throws<a class="headerlink" href="#throws" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Nothing unless <tt class="docutils literal"><span class="pre">lhs.swap(y)</span></tt> throws an exception.</div>
</div>
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-c++"><div class="highlight"><pre><span class="cp">#include &lt;sprout/array.hpp&gt;</span>
<span class="cp">#include &lt;sprout/assert.hpp&gt;</span>
<span class="k">using</span> <span class="k">namespace</span> <span class="n">sprout</span><span class="p">;</span>
<span class="k">auto</span> <span class="n">x</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">10</span><span class="p">}};</span>
<span class="k">auto</span> <span class="n">y</span> <span class="o">=</span> <span class="n">array</span><span class="o">&lt;</span><span class="kt">int</span><span class="p">,</span> <span class="mi">10</span><span class="o">&gt;</span><span class="p">{{</span><span class="mi">10</span><span class="p">,</span> <span class="mi">9</span><span class="p">,</span> <span class="mi">8</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">4</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">1</span><span class="p">}};</span>
<span class="n">swap</span><span class="p">(</span><span class="n">x</span><span class="p">,</span> <span class="n">y</span><span class="p">);</span>
<span class="n">SPROUT_ASSERT_MSG</span><span class="p">(</span><span class="n">x</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">=</span> <span class="mi">10</span> <span class="o">&amp;&amp;</span> <span class="n">y</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">==</span> <span class="mi">1</span><span class="p">,</span> <span class="s">&quot;each element are swapped.&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">linear in N.</div>
<div class="line">Recursive function invocations in <em>O(1)</em> (constant) depth.</div>
</div>
</div>
<div class="section" id="header">
<h2>Header<a class="headerlink" href="#header" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">sprout/array/array.hpp</span></tt></div>
<div class="line">Convenience header: <tt class="docutils literal"><span class="pre">sprout/array.hpp</span></tt></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="operator-equal_to.html" title="operator=="
>next</a> |</li>
<li class="right" >
<a href="c_array.html" title="back"
>previous</a> |</li>
<li><a href="../../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
<li><a href="../../../libraries.html" >Libraries</a> &raquo;</li>
<li><a href="../index.html" >Sprout.Array</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; Copyright 2013, Bolero MURAKAMI.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.4.
</div>
</body>
</html>

View file

@ -50,7 +50,7 @@
<ul>
<li><a class="reference external" href="#">swap</a><ul>
<li><a class="reference external" href="#interface">Interface</a></li>
<li><a class="reference external" href="#returns">Returns</a></li>
<li><a class="reference external" href="#effects">Effects</a></li>
<li><a class="reference external" href="#throws">Throws</a></li>
<li><a class="reference external" href="#examples">Examples</a></li>
<li><a class="reference external" href="#complexity">Complexity</a></li>
@ -99,8 +99,8 @@
</pre></div>
</div>
</div>
<div class="section" id="returns">
<h2>Returns<a class="headerlink" href="#returns" title="Permalink to this headline"></a></h2>
<div class="section" id="effects">
<h2>Effects<a class="headerlink" href="#effects" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line"><tt class="docutils literal"><span class="pre">swap_ranges(begin(),</span> <span class="pre">end(),</span> <span class="pre">y.begin())</span></tt>.</div>
</div>
@ -127,7 +127,7 @@
<div class="section" id="complexity">
<h2>Complexity<a class="headerlink" href="#complexity" title="Permalink to this headline"></a></h2>
<div class="line-block">
<div class="line">Linear.</div>
<div class="line">linear in N.</div>
<div class="line">Recursive function invocations in <em>O(1)</em> (constant) depth.</div>
</div>
</div>

View file

@ -50,9 +50,9 @@
<li><a class="reference external" href="#description">Description</a><ul>
<li><a class="reference external" href="#classes">Classes</a></li>
<li><a class="reference external" href="#non-member-functions">Non-member functions</a><ul>
<li><a class="reference external" href="#array-generators">array generators</a></li>
<li><a class="reference external" href="#specialized-algorithms">specialized algorithms</a></li>
<li><a class="reference external" href="#comparisons">comparisons</a></li>
<li><a class="reference external" href="#array-generators">array generators</a></li>
</ul>
</li>
<li><a class="reference external" href="#tuple-interface">Tuple interface</a></li>
@ -121,6 +121,59 @@
</div>
<div class="section" id="non-member-functions">
<h3>Non-member functions<a class="headerlink" href="#non-member-functions" title="Permalink to this headline"></a></h3>
<div class="section" id="specialized-algorithms">
<h4>specialized algorithms<a class="headerlink" href="#specialized-algorithms" title="Permalink to this headline"></a></h4>
<table border="1" class="docutils">
<colgroup>
<col width="34%" />
<col width="66%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">function</th>
<th class="head">&nbsp;</th>
</tr>
</thead>
<tbody valign="top">
<tr><td><a class="reference external" href="array/swap-global.html"><em>swap</em></a></td>
<td>&nbsp;</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="comparisons">
<h4>comparisons<a class="headerlink" href="#comparisons" title="Permalink to this headline"></a></h4>
<table border="1" class="docutils">
<colgroup>
<col width="43%" />
<col width="57%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">function</th>
<th class="head">&nbsp;</th>
</tr>
</thead>
<tbody valign="top">
<tr><td><a class="reference external" href="array/operator-equal_to.html"><em>operator==</em></a></td>
<td>&nbsp;</td>
</tr>
<tr><td><a class="reference external" href="array/operator-not_equal_to.html"><em>operator!=</em></a></td>
<td>&nbsp;</td>
</tr>
<tr><td><a class="reference external" href="array/operator-less.html"><em>operator</em></a></td>
<td>&nbsp;</td>
</tr>
<tr><td><a class="reference external" href="array/operator-greater.html"><em>operator</em></a></td>
<td>&nbsp;</td>
</tr>
<tr><td><a class="reference external" href="array/operator-less_equal.html"><em>operator=</em></a></td>
<td>&nbsp;</td>
</tr>
<tr><td><a class="reference external" href="array/operator-greater_equal.html"><em>operator=</em></a></td>
<td>&nbsp;</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="array-generators">
<h4>array generators<a class="headerlink" href="#array-generators" title="Permalink to this headline"></a></h4>
<table border="1" class="docutils">
@ -146,59 +199,6 @@
</tbody>
</table>
</div>
<div class="section" id="specialized-algorithms">
<h4>specialized algorithms<a class="headerlink" href="#specialized-algorithms" title="Permalink to this headline"></a></h4>
<table border="1" class="docutils">
<colgroup>
<col width="34%" />
<col width="66%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">function</th>
<th class="head">&nbsp;</th>
</tr>
</thead>
<tbody valign="top">
<tr><td><tt class="xref docutils literal"><span class="pre">swap</span></tt></td>
<td>&nbsp;</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="comparisons">
<h4>comparisons<a class="headerlink" href="#comparisons" title="Permalink to this headline"></a></h4>
<table border="1" class="docutils">
<colgroup>
<col width="43%" />
<col width="57%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">function</th>
<th class="head">&nbsp;</th>
</tr>
</thead>
<tbody valign="top">
<tr><td><tt class="xref docutils literal"><span class="pre">operator==</span></tt></td>
<td>&nbsp;</td>
</tr>
<tr><td><tt class="xref docutils literal"><span class="pre">operator!=</span></tt></td>
<td>&nbsp;</td>
</tr>
<tr><td><tt class="xref docutils literal"><span class="pre">operator</span></tt></td>
<td>&nbsp;</td>
</tr>
<tr><td><tt class="xref docutils literal"><span class="pre">operator</span></tt></td>
<td>&nbsp;</td>
</tr>
<tr><td><tt class="xref docutils literal"><span class="pre">operator=</span></tt></td>
<td>&nbsp;</td>
</tr>
<tr><td><tt class="xref docutils literal"><span class="pre">operator=</span></tt></td>
<td>&nbsp;</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="tuple-interface">
<h3>Tuple interface<a class="headerlink" href="#tuple-interface" title="Permalink to this headline"></a></h3>

View file

@ -22,7 +22,7 @@
<link rel="top" title="Sprout v1.0 documentation" href="../../../index.html" />
<link rel="up" title="Sprout.Array" href="index.html" />
<link rel="next" title="make_array" href="make_array.html" />
<link rel="prev" title="back" href="array/c_array.html" />
<link rel="prev" title="operator>=" href="array/operator-greater_equal.html" />
</head>
<body>
<div class="related">
@ -35,7 +35,7 @@
<a href="make_array.html" title="make_array"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="array/c_array.html" title="back"
<a href="array/operator-greater_equal.html" title="operator>="
accesskey="P">previous</a> |</li>
<li><a href="../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../index.html" >Sprout C++ Libraries</a> &raquo;</li>
@ -58,8 +58,8 @@
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="array/c_array.html"
title="previous chapter">back</a></p>
<p class="topless"><a href="array/operator-greater_equal.html"
title="previous chapter">operator&gt;=</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="make_array.html"
title="next chapter">make_array</a></p>
@ -146,7 +146,7 @@
<a href="make_array.html" title="make_array"
>next</a> |</li>
<li class="right" >
<a href="array/c_array.html" title="back"
<a href="array/operator-greater_equal.html" title="operator>="
>previous</a> |</li>
<li><a href="../../../index.html">Sprout v1.0 documentation</a> &raquo;</li>
<li><a href="../../index.html" >Sprout C++ Libraries</a> &raquo;</li>

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-equal_to:
###############################################################################
operator==
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator==(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the containers are equivalent, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
static_assert(x == y, "x is equal to y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-greater:
###############################################################################
operator>
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator>(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically greater than the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(y > x, "y is greater than x.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-greater_equal:
###############################################################################
operator>=
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator>=(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically greater than or equal the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(y >= x, "y is greater than or equal to x.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-less:
###############################################################################
operator<
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator<(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically less than the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(x < y, "x is less than y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-less_equal:
###############################################################################
operator<=
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator<=(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the lhs are lexicographically less than or equal the contents of rhs, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(x <= y, "x is less than or equal to y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,40 @@
.. _sprout-array-array-operator-not_equal_to:
###############################################################################
operator!=
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline SPROUT_CONSTEXPR bool
operator!=(sprout::array<T, N> const& lhs, sprout::array<T, N> const& rhs);
Returns
========================================
| true if the contents of the containers are not equivalent, false otherwise.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
using namespace sprout;
SPROUT_STATIC_CONSTEXPR auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
SPROUT_STATIC_CONSTEXPR auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
static_assert(x != y, "x is not equal to y.");
Complexity
========================================
| Recursive function invocations in *O(logN)* (logarithmic) depth.
Header
========================================
| ``sprout/array/comparison.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -0,0 +1,49 @@
.. _sprout-array-array-swap-global:
###############################################################################
swap
###############################################################################
Interface
========================================
.. sourcecode:: c++
template<typename T, std::size_t N>
inline void
swap(sprout::array<T, N>& lhs, sprout::array<T, N>& rhs)
SPROUT_NOEXCEPT_EXPR(SPROUT_NOEXCEPT_EXPR(lhs.swap(rhs)));
Effects
========================================
| ``lhs.swap(y)``.
Throws
========================================
| Nothing unless ``lhs.swap(y)`` throws an exception.
Examples
========================================
.. sourcecode:: c++
#include <sprout/array.hpp>
#include <sprout/assert.hpp>
using namespace sprout;
auto x = array<int, 10>{{1, 2, 3, 4, 5, 6, 7, 8, 9, 10}};
auto y = array<int, 10>{{10, 9, 8, 7, 6, 5, 4, 3, 2, 1}};
swap(x, y);
SPROUT_ASSERT_MSG(x[0] = 10 && y[0] == 1, "each element are swapped.");
Complexity
========================================
| linear in N.
| Recursive function invocations in *O(1)* (constant) depth.
Header
========================================
| ``sprout/array/array.hpp``
| Convenience header: ``sprout/array.hpp``

View file

@ -9,7 +9,7 @@ Interface
void swap(array& y) SPROUT_NOEXCEPT_EXPR(SPROUT_NOEXCEPT_EXPR(std::swap(std::declval<T&>(), std::declval<T&>())));
Returns
Effects
========================================
| ``swap_ranges(begin(), end(), y.begin())``.
@ -35,7 +35,7 @@ Examples
Complexity
========================================
| Linear.
| linear in N.
| Recursive function invocations in *O(1)* (constant) depth.
Header

View file

@ -7,6 +7,13 @@ Sprout.Array
:hidden:
array/index
array/swap-global
array/operator-equal_to
array/operator-not_equal_to
array/operator-less
array/operator-greater
array/operator-less_equal
array/operator-greater_equal
to_array
make_array
make_common_array
@ -26,17 +33,6 @@ class
Non-member functions
----------------------------------------
array generators
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
============================================================ ===============================================================================
function
============================================================ ===============================================================================
:doc:`to_array <./to_array>`
:doc:`make_array <./make_array>`
:doc:`make_common_array <./make_common_array>`
============================================================ ===============================================================================
specialized algorithms
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@ -60,6 +56,17 @@ function
:doc:`operator= <./array/operator-greater_equal>`
============================================================ ===============================================================================
array generators
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
============================================================ ===============================================================================
function
============================================================ ===============================================================================
:doc:`to_array <./to_array>`
:doc:`make_array <./make_array>`
:doc:`make_common_array <./make_common_array>`
============================================================ ===============================================================================
Tuple interface
----------------------------------------