Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > c74ab286c3d46f9b82671d206e43a74b > files > 484

libstdc++-docs-4.6.3-2.fc15.i686.rpm

<!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/xhtml;charset=UTF-8"/>
<title>libstdc++: std::function&lt; _Res(_ArgTypes...)&gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript">
$(document).ready(initResizable);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.7.4 -->
<div id="top">
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">libstdc++</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
  initNavTree('a00478.html','');
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-types">Private Types</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="#pri-static-attribs">Static Private Attributes</a>  </div>
  <div class="headertitle">
<div class="title">std::function&lt; _Res(_ArgTypes...)&gt; Class Template Reference<div class="ingroups"><a class="el" href="a01193.html">Function Objects</a></div></div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="std::function&lt; _Res(_ArgTypes...)&gt;" --><!-- doxytag: inherits="_Maybe_unary_or_binary_function&lt; _Res, _ArgTypes...&gt;,std::_Function_base" -->
<p>Primary class template for std::function.Polymorphic function wrapper.  
 <a href="a00478.html#details">More...</a></p>
<div class="dynheader">
Inheritance diagram for std::function&lt; _Res(_ArgTypes...)&gt;:</div>
<div class="dyncontent">
<div class="center"><img src="a02020.png" border="0" usemap="#std_1_1function_3_01___res_07___arg_types_8_8_8_08_4_inherit__map" alt="Inheritance graph"/></div>
<map name="std_1_1function_3_01___res_07___arg_types_8_8_8_08_4_inherit__map" id="std_1_1function_3_01___res_07___arg_types_8_8_8_08_4_inherit__map">
<area shape="rect" id="node2" href="a00238.html" title="std::_Maybe_unary_or_binary_function\&lt; _Res, _ArgTypes...\&gt;" alt="" coords="5,101,360,131"/><area shape="rect" id="node4" href="a00238.html" title="std::_Maybe_unary_or_binary_function\&lt; _Res, _ArgTypes \&gt;" alt="" coords="8,5,357,35"/><area shape="rect" id="node6" href="a00321.html" title="Base class of all polymorphic function object wrappers." alt="" coords="384,101,515,131"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>

<p><a href="a02021.html">List of all members.</a></p>
<h2><a name="pub-types"></a>
Public Types</h2>
<ul>
<li><a class="anchor" id="a81dd2ae5fb6d9bfb9fe84fdc2c741b20"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::result_type" ref="a81dd2ae5fb6d9bfb9fe84fdc2c741b20" args="" -->
typedef _Res <b>result_type</b>
</ul>
<h2><a name="pub-methods"></a>
Public Member Functions</h2>
<ul>
<li><a class="el" href="a00478.html#af6be5fe890ef1283903d26d3ab314995">function</a> ()
<li><a class="el" href="a00478.html#a3ba292105d8b130daf1f645f00d756da">function</a> (nullptr_t)
<li><a class="el" href="a00478.html#adae21cbabc722f1919974767cd2e97b5">function</a> (function &amp;&amp;__x)
<li>template&lt;typename _Functor &gt; <a class="el" href="a00478.html#a94c773f1583605042fdece8a49d6325b">function</a> (_Functor __f, typename <a class="el" href="a00255.html">enable_if</a>&lt; !<a class="el" href="a00549.html">is_integral</a>&lt; _Functor &gt;::value, _Useless &gt;::type=_Useless())
<li><a class="el" href="a00478.html#a8869fed86e489fcedbf59cd814f440b3">function</a> (const function &amp;__x)
<li><a class="el" href="a00478.html#a894c0d8716aeda6370db417317d899c1">operator bool</a> () const 
<li>_Res <a class="el" href="a00478.html#a8679700c9c0654b0104ae3d4a285ab8d">operator()</a> (_ArgTypes...__args) const 
<li>function &amp; <a class="el" href="a00478.html#a298583547a0091449a5ea8cba01d5490">operator=</a> (nullptr_t)
<li>template&lt;typename _Functor &gt; <a class="el" href="a00255.html">enable_if</a>&lt;!<a class="el" href="a00549.html">is_integral</a><br class="typebreak"/>
&lt; _Functor &gt;::value, function &amp; &gt;<br class="typebreak"/>
::type <a class="el" href="a00478.html#a4695ac70856182b47dca06f272dc339f">operator=</a> (_Functor &amp;&amp;__f)
<li>template&lt;typename _Functor &gt; <a class="el" href="a00255.html">enable_if</a>&lt;!<a class="el" href="a00549.html">is_integral</a><br class="typebreak"/>
&lt; _Functor &gt;::value, function &amp; &gt;<br class="typebreak"/>
::type <a class="el" href="a00478.html#aaee10be326112cabdb9f0e8c5f845ce0">operator=</a> (<a class="el" href="a00681.html">reference_wrapper</a>&lt; _Functor &gt; __f)
<li>function &amp; <a class="el" href="a00478.html#aef5e5902a947935662963c9b53d5b383">operator=</a> (function &amp;&amp;__x)
<li>function &amp; <a class="el" href="a00478.html#a698ecd83665a25c0c1f9cbe2ea85c2a0">operator=</a> (const function &amp;__x)
<li>void <a class="el" href="a00478.html#a6bcb2484183496e238f5da4e87d7e4e5">swap</a> (function &amp;__x)
<li>template&lt;typename _Functor &gt; _Functor * <a class="el" href="a00478.html#ad18f38e9df30b14eeb42aebaa4bf2d4d">target</a> ()
<li>template&lt;typename _Functor &gt; const _Functor * <a class="el" href="a00478.html#aea904c980fa5469cfa7276b6466b7054">target</a> () const 
<li>const <a class="el" href="a00722.html">type_info</a> &amp; <a class="el" href="a00478.html#aa05de936db3bc6945194de5fe001d63d">target_type</a> () const 
</ul>
<h2><a name="pri-types"></a>
Private Types</h2>
<ul>
<li><a class="anchor" id="a788e685d80e783bf76d877380ad9b140"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::_Manager_type" ref="a788e685d80e783bf76d877380ad9b140" args=")(_Any_data &amp;, const _Any_data &amp;, _Manager_operation)" -->
typedef bool(* <b>_Manager_type</b> )(_Any_data &amp;, const _Any_data &amp;, _Manager_operation)
</ul>
<h2><a name="pri-methods"></a>
Private Member Functions</h2>
<ul>
<li><a class="anchor" id="a0297ea8e2f5e7f30bc74362e5ee09ec7"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::_M_empty" ref="a0297ea8e2f5e7f30bc74362e5ee09ec7" args="() const " -->
bool <b>_M_empty</b> () const 
</ul>
<h2><a name="pri-attribs"></a>
Private Attributes</h2>
<ul>
<li><a class="anchor" id="a2e96e5cb42609bb4e5d96f351ed14f01"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::_M_functor" ref="a2e96e5cb42609bb4e5d96f351ed14f01" args="" -->
_Any_data <b>_M_functor</b>
<li><a class="anchor" id="a3bf92d62608dfa3feb8ec1ab2951e72b"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::_M_manager" ref="a3bf92d62608dfa3feb8ec1ab2951e72b" args="" -->
_Manager_type <b>_M_manager</b>
</ul>
<h2><a name="pri-static-attribs"></a>
Static Private Attributes</h2>
<ul>
<li><a class="anchor" id="ac5166832f25a05f78ccd303e8c6e5609"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::_M_max_align" ref="ac5166832f25a05f78ccd303e8c6e5609" args="" -->
static const std::size_t <b>_M_max_align</b>
<li><a class="anchor" id="aabe5249f1ddb3ebdd1b64f26b4f4eb92"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::_M_max_size" ref="aabe5249f1ddb3ebdd1b64f26b4f4eb92" args="" -->
static const std::size_t <b>_M_max_size</b>
</ul>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><h3>template&lt;typename _Res, typename... _ArgTypes&gt;<br/>
class std::function&lt; _Res(_ArgTypes...)&gt;</h3>

<p>Primary class template for std::function.</p>
<p>Polymorphic function wrapper. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l01877">1877</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="af6be5fe890ef1283903d26d3ab314995"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::function" ref="af6be5fe890ef1283903d26d3ab314995" args="()" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">std::function&lt; _Res(_ArgTypes...)&gt;::function </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Default construct creates an empty function call wrapper. </p>
<dl class="post"><dt><b>Postcondition:</b></dt><dd><code>!</code>(bool)*this </dd></dl>

<p>Definition at line <a class="el" href="a00884_source.html#l01894">1894</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a3ba292105d8b130daf1f645f00d756da"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::function" ref="a3ba292105d8b130daf1f645f00d756da" args="(nullptr_t)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">std::function&lt; _Res(_ArgTypes...)&gt;::function </td>
          <td>(</td>
          <td class="paramtype">nullptr_t&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Creates an empty function call wrapper. </p>
<dl class="post"><dt><b>Postcondition:</b></dt><dd><code>!</code>(bool)*this </dd></dl>

<p>Definition at line <a class="el" href="a00884_source.html#l01900">1900</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a8869fed86e489fcedbf59cd814f440b3"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::function" ref="a8869fed86e489fcedbf59cd814f440b3" args="(const function &amp;__x)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">std::function&lt; _Res(_ArgTypes...)&gt;::function </td>
          <td>(</td>
          <td class="paramtype">const function&lt; _Res(_ArgTypes...)&gt; &amp;&#160;</td>
          <td class="paramname"><em>__x</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Function copy constructor. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>A function object with identical call signature. </td></tr>
  </table>
  </dd>
</dl>
<dl class="post"><dt><b>Postcondition:</b></dt><dd><code></code>(bool)*this == (bool)x</dd></dl>
<p>The newly-created function contains a copy of the target of <em>x</em> (if it has one). </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02125">2125</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="adae21cbabc722f1919974767cd2e97b5"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::function" ref="adae21cbabc722f1919974767cd2e97b5" args="(function &amp;&amp;__x)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">std::function&lt; _Res(_ArgTypes...)&gt;::function </td>
          <td>(</td>
          <td class="paramtype">function&lt; _Res(_ArgTypes...)&gt; &amp;&amp;&#160;</td>
          <td class="paramname"><em>__x</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Function move constructor. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>A function object rvalue with identical call signature.</td></tr>
  </table>
  </dd>
</dl>
<p>The newly-created function contains the target of <em>x</em> (if it has one). </p>

<p>Definition at line <a class="el" href="a00884_source.html#l01919">1919</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a94c773f1583605042fdece8a49d6325b"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::function" ref="a94c773f1583605042fdece8a49d6325b" args="(_Functor __f, typename enable_if&lt; !is_integral&lt; _Functor &gt;::value, _Useless &gt;::type=_Useless())" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
<div class="memtemplate">
template&lt;typename _Functor &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">std::function&lt; _Res(_ArgTypes...)&gt;::function </td>
          <td>(</td>
          <td class="paramtype">_Functor&#160;</td>
          <td class="paramname"><em>__f</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">typename <a class="el" href="a00255.html">enable_if</a>&lt; !<a class="el" href="a00549.html">is_integral</a>&lt; _Functor &gt;::value, _Useless &gt;::type&#160;</td>
          <td class="paramname"> = <code>_Useless()</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Builds a function that targets a copy of the incoming function object. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">f</td><td>A function object that is callable with parameters of type <code>T1</code>, <code>T2</code>, ..., <code>TN</code> and returns a value convertible to <code>Res</code>.</td></tr>
  </table>
  </dd>
</dl>
<p>The newly-created function object will target a copy of <em>f</em>. If <em>f</em> is <code>reference_wrapper&lt;F&gt;</code>, then this function object will contain a reference to the function object <code>f.get()</code>. If <em>f</em> is a NULL function pointer or NULL pointer-to-member, the newly-created object will be empty.</p>
<p>If <em>f</em> is a non-NULL function pointer or an object of type <code>reference_wrapper&lt;F&gt;</code>, this function will not throw. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02139">2139</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a894c0d8716aeda6370db417317d899c1"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::operator bool" ref="a894c0d8716aeda6370db417317d899c1" args="() const " -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">std::function&lt; _Res(_ArgTypes...)&gt;::operator bool </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline, explicit]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Determine if the function wrapper has a target. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd><code>true</code> when this function object contains a target, or <code>false</code> when it is empty.</dd></dl>
<p>This function will not throw an exception. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02074">2074</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a8679700c9c0654b0104ae3d4a285ab8d"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::operator()" ref="a8679700c9c0654b0104ae3d4a285ab8d" args="(_ArgTypes...__args) const " -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">_Res std::function&lt; _Res(_ArgTypes...)&gt;::operator() </td>
          <td>(</td>
          <td class="paramtype">_ArgTypes...&#160;</td>
          <td class="paramname"><em>__args</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Invokes the function targeted by <code>*this</code>. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>the result of the target. </dd></dl>
<dl><dt><b>Exceptions:</b></dt><dd>
  <table class="exception">
    <tr><td class="paramname"><a class="el" href="a00392.html" title="Exception class thrown when class template function&#39;s operator() is called with an empty target...">bad_function_call</a></td><td>when <code>!</code>(bool)*this</td></tr>
  </table>
  </dd>
</dl>
<p>The function call operator invokes the target function object stored by <code>this</code>. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02157">2157</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="aef5e5902a947935662963c9b53d5b383"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::operator=" ref="aef5e5902a947935662963c9b53d5b383" args="(function &amp;&amp;__x)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">function&amp; std::function&lt; _Res(_ArgTypes...)&gt;::operator= </td>
          <td>(</td>
          <td class="paramtype">function&lt; _Res(_ArgTypes...)&gt; &amp;&amp;&#160;</td>
          <td class="paramname"><em>__x</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Function move-assignment operator. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>A function rvalue with identical call signature. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd><code>*this</code> </dd></dl>
<p>The target of <em>x</em> is moved to <code>*this</code>. If <em>x</em> has no target, then <code>*this</code> will be empty.</p>
<p>If <em>x</em> targets a function pointer or a reference to a function object, then this operation will not throw an exception. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l01979">1979</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a4695ac70856182b47dca06f272dc339f"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::operator=" ref="a4695ac70856182b47dca06f272dc339f" args="(_Functor &amp;&amp;__f)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
<div class="memtemplate">
template&lt;typename _Functor &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="a00255.html">enable_if</a>&lt;!<a class="el" href="a00549.html">is_integral</a>&lt;_Functor&gt;::value, function&amp;&gt;::type std::function&lt; _Res(_ArgTypes...)&gt;::operator= </td>
          <td>(</td>
          <td class="paramtype">_Functor &amp;&amp;&#160;</td>
          <td class="paramname"><em>__f</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Function assignment to a new target. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">f</td><td>A function object that is callable with parameters of type <code>T1</code>, <code>T2</code>, ..., <code>TN</code> and returns a value convertible to <code>Res</code>. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd><code>*this</code> </dd></dl>
<p>This function object wrapper will target a copy of <em>f</em>. If <em>f</em> is <code>reference_wrapper&lt;F&gt;</code>, then this function object will contain a reference to the function object <code>f.get()</code>. If <em>f</em> is a NULL function pointer or NULL pointer-to-member, <code>this</code> object will be empty.</p>
<p>If <em>f</em> is a non-NULL function pointer or an object of type <code>reference_wrapper&lt;F&gt;</code>, this function will not throw. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02022">2022</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="aaee10be326112cabdb9f0e8c5f845ce0"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::operator=" ref="aaee10be326112cabdb9f0e8c5f845ce0" args="(reference_wrapper&lt; _Functor &gt; __f)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
<div class="memtemplate">
template&lt;typename _Functor &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="a00255.html">enable_if</a>&lt;!<a class="el" href="a00549.html">is_integral</a>&lt;_Functor&gt;::value, function&amp;&gt;::type std::function&lt; _Res(_ArgTypes...)&gt;::operator= </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="a00681.html">reference_wrapper</a>&lt; _Functor &gt;&#160;</td>
          <td class="paramname"><em>__f</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02031">2031</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a298583547a0091449a5ea8cba01d5490"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::operator=" ref="a298583547a0091449a5ea8cba01d5490" args="(nullptr_t)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">function&amp; std::function&lt; _Res(_ArgTypes...)&gt;::operator= </td>
          <td>(</td>
          <td class="paramtype">nullptr_t&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Function assignment to zero. </p>
<dl class="post"><dt><b>Postcondition:</b></dt><dd><code>!</code>(bool)*this </dd></dl>
<dl class="return"><dt><b>Returns:</b></dt><dd><code>*this</code> </dd></dl>
<p>The target of <code>*this</code> is deallocated, leaving it empty. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l01993">1993</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a698ecd83665a25c0c1f9cbe2ea85c2a0"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::operator=" ref="a698ecd83665a25c0c1f9cbe2ea85c2a0" args="(const function &amp;__x)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">function&amp; std::function&lt; _Res(_ArgTypes...)&gt;::operator= </td>
          <td>(</td>
          <td class="paramtype">const function&lt; _Res(_ArgTypes...)&gt; &amp;&#160;</td>
          <td class="paramname"><em>__x</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Function assignment operator. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>A function with identical call signature. </td></tr>
  </table>
  </dd>
</dl>
<dl class="post"><dt><b>Postcondition:</b></dt><dd><code></code>(bool)*this == (bool)x </dd></dl>
<dl class="return"><dt><b>Returns:</b></dt><dd><code>*this</code> </dd></dl>
<p>The target of <em>x</em> is copied to <code>*this</code>. If <em>x</em> has no target, then <code>*this</code> will be empty.</p>
<p>If <em>x</em> targets a function pointer or a reference to a function object, then this operation will not throw an exception. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l01961">1961</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="a6bcb2484183496e238f5da4e87d7e4e5"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::swap" ref="a6bcb2484183496e238f5da4e87d7e4e5" args="(function &amp;__x)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">void std::function&lt; _Res(_ArgTypes...)&gt;::swap </td>
          <td>(</td>
          <td class="paramtype">function&lt; _Res(_ArgTypes...)&gt; &amp;&#160;</td>
          <td class="paramname"><em>__x</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Swap the targets of two function objects. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">f</td><td>A function with identical call signature.</td></tr>
  </table>
  </dd>
</dl>
<p>Swap the targets of <code>this</code> function object and <em>f</em>. This function will not throw an exception. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02046">2046</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="ad18f38e9df30b14eeb42aebaa4bf2d4d"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::target" ref="ad18f38e9df30b14eeb42aebaa4bf2d4d" args="()" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
<div class="memtemplate">
template&lt;typename _Functor &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">_Functor * std::function&lt; _Res(_ArgTypes...)&gt;::target </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Access the stored target function object. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>Returns a pointer to the stored target function object, if <code>typeid(Functor)</code>.equals(<a class="el" href="a00478.html#aa05de936db3bc6945194de5fe001d63d" title="Determine the type of the target of this function object wrapper.">target_type()</a>); otherwise, a NULL pointer.</dd></dl>
<p>This function will not throw an exception. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02184">2184</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="aea904c980fa5469cfa7276b6466b7054"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::target" ref="aea904c980fa5469cfa7276b6466b7054" args="() const " -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
<div class="memtemplate">
template&lt;typename _Functor &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">const _Functor * std::function&lt; _Res(_ArgTypes...)&gt;::target </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02203">2203</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<a class="anchor" id="aa05de936db3bc6945194de5fe001d63d"></a><!-- doxytag: member="std::function&lt; _Res(_ArgTypes...)&gt;::target_type" ref="aa05de936db3bc6945194de5fe001d63d" args="() const " -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename _Res , typename... _ArgTypes&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="a00722.html">type_info</a> &amp; std::function&lt; _Res(_ArgTypes...)&gt;::target_type </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Determine the type of the target of this function object wrapper. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>the type identifier of the target function object, or <code>typeid(void)</code> if <code>!</code>(bool)*this.</dd></dl>
<p>This function will not throw an exception. </p>

<p>Definition at line <a class="el" href="a00884_source.html#l02168">2168</a> of file <a class="el" href="a00884_source.html">functional</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="a00884_source.html">functional</a></li>
</ul>
</div>
</div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="a01137.html">std</a>      </li>
      <li class="navelem"><a class="el" href="a00478.html">function&lt; _Res(_ArgTypes...)&gt;</a>      </li>
      <li class="footer">Generated by&#160;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.4 </li>
    </ul>
  </div>

</body>
</html>