1<html> 2<head> 3<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 4<title>system_context</title> 5<link rel="stylesheet" href="../../../../doc/src/boostbook.css" type="text/css"> 6<meta name="generator" content="DocBook XSL Stylesheets V1.79.1"> 7<link rel="home" href="../../boost_asio.html" title="Boost.Asio"> 8<link rel="up" href="../reference.html" title="Reference"> 9<link rel="prev" href="streambuf.html" title="streambuf"> 10<link rel="next" href="system_context/add_service.html" title="system_context::add_service"> 11</head> 12<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> 13<table cellpadding="2" width="100%"><tr> 14<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../boost.png"></td> 15<td align="center"><a href="../../../../index.html">Home</a></td> 16<td align="center"><a href="../../../../libs/libraries.htm">Libraries</a></td> 17<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td> 18<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td> 19<td align="center"><a href="../../../../more/index.htm">More</a></td> 20</tr></table> 21<hr> 22<div class="spirit-nav"> 23<a accesskey="p" href="streambuf.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../boost_asio.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="system_context/add_service.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a> 24</div> 25<div class="section"> 26<div class="titlepage"><div><div><h3 class="title"> 27<a name="boost_asio.reference.system_context"></a><a class="link" href="system_context.html" title="system_context">system_context</a> 28</h3></div></div></div> 29<p> 30 The executor context for the system executor. 31 </p> 32<pre class="programlisting">class system_context : 33 public execution_context 34</pre> 35<h5> 36<a name="boost_asio.reference.system_context.h0"></a> 37 <span class="phrase"><a name="boost_asio.reference.system_context.types"></a></span><a class="link" href="system_context.html#boost_asio.reference.system_context.types">Types</a> 38 </h5> 39<div class="informaltable"><table class="table"> 40<colgroup> 41<col> 42<col> 43</colgroup> 44<thead><tr> 45<th> 46 <p> 47 Name 48 </p> 49 </th> 50<th> 51 <p> 52 Description 53 </p> 54 </th> 55</tr></thead> 56<tbody> 57<tr> 58<td> 59 <p> 60 <a class="link" href="system_context/executor_type.html" title="system_context::executor_type"><span class="bold"><strong>executor_type</strong></span></a> 61 </p> 62 </td> 63<td> 64 <p> 65 The executor type associated with the context. 66 </p> 67 </td> 68</tr> 69<tr> 70<td> 71 <p> 72 <a class="link" href="system_context/fork_event.html" title="system_context::fork_event"><span class="bold"><strong>fork_event</strong></span></a> 73 </p> 74 </td> 75<td> 76 <p> 77 Fork-related event notifications. 78 </p> 79 </td> 80</tr> 81</tbody> 82</table></div> 83<h5> 84<a name="boost_asio.reference.system_context.h1"></a> 85 <span class="phrase"><a name="boost_asio.reference.system_context.member_functions"></a></span><a class="link" href="system_context.html#boost_asio.reference.system_context.member_functions">Member Functions</a> 86 </h5> 87<div class="informaltable"><table class="table"> 88<colgroup> 89<col> 90<col> 91</colgroup> 92<thead><tr> 93<th> 94 <p> 95 Name 96 </p> 97 </th> 98<th> 99 <p> 100 Description 101 </p> 102 </th> 103</tr></thead> 104<tbody> 105<tr> 106<td> 107 <p> 108 <a class="link" href="system_context/get_executor.html" title="system_context::get_executor"><span class="bold"><strong>get_executor</strong></span></a> 109 </p> 110 </td> 111<td> 112 <p> 113 Obtain an executor for the context. 114 </p> 115 </td> 116</tr> 117<tr> 118<td> 119 <p> 120 <a class="link" href="system_context/join.html" title="system_context::join"><span class="bold"><strong>join</strong></span></a> 121 </p> 122 </td> 123<td> 124 <p> 125 Join all threads in the system thread pool. 126 </p> 127 </td> 128</tr> 129<tr> 130<td> 131 <p> 132 <a class="link" href="system_context/notify_fork.html" title="system_context::notify_fork"><span class="bold"><strong>notify_fork</strong></span></a> 133 </p> 134 </td> 135<td> 136 <p> 137 Notify the execution_context of a fork-related event. 138 </p> 139 </td> 140</tr> 141<tr> 142<td> 143 <p> 144 <a class="link" href="system_context/stop.html" title="system_context::stop"><span class="bold"><strong>stop</strong></span></a> 145 </p> 146 </td> 147<td> 148 <p> 149 Signal all threads in the system thread pool to stop. 150 </p> 151 </td> 152</tr> 153<tr> 154<td> 155 <p> 156 <a class="link" href="system_context/stopped.html" title="system_context::stopped"><span class="bold"><strong>stopped</strong></span></a> 157 </p> 158 </td> 159<td> 160 <p> 161 Determine whether the system thread pool has been stopped. 162 </p> 163 </td> 164</tr> 165<tr> 166<td> 167 <p> 168 <a class="link" href="system_context/_system_context.html" title="system_context::~system_context"><span class="bold"><strong>~system_context</strong></span></a> <span class="silver">[destructor]</span> 169 </p> 170 </td> 171<td> 172 <p> 173 Destructor shuts down all threads in the system thread pool. 174 </p> 175 </td> 176</tr> 177</tbody> 178</table></div> 179<h5> 180<a name="boost_asio.reference.system_context.h2"></a> 181 <span class="phrase"><a name="boost_asio.reference.system_context.protected_member_functions"></a></span><a class="link" href="system_context.html#boost_asio.reference.system_context.protected_member_functions">Protected 182 Member Functions</a> 183 </h5> 184<div class="informaltable"><table class="table"> 185<colgroup> 186<col> 187<col> 188</colgroup> 189<thead><tr> 190<th> 191 <p> 192 Name 193 </p> 194 </th> 195<th> 196 <p> 197 Description 198 </p> 199 </th> 200</tr></thead> 201<tbody> 202<tr> 203<td> 204 <p> 205 <a class="link" href="system_context/destroy.html" title="system_context::destroy"><span class="bold"><strong>destroy</strong></span></a> 206 </p> 207 </td> 208<td> 209 <p> 210 Destroys all services in the context. 211 </p> 212 </td> 213</tr> 214<tr> 215<td> 216 <p> 217 <a class="link" href="system_context/shutdown.html" title="system_context::shutdown"><span class="bold"><strong>shutdown</strong></span></a> 218 </p> 219 </td> 220<td> 221 <p> 222 Shuts down all services in the context. 223 </p> 224 </td> 225</tr> 226</tbody> 227</table></div> 228<h5> 229<a name="boost_asio.reference.system_context.h3"></a> 230 <span class="phrase"><a name="boost_asio.reference.system_context.friends"></a></span><a class="link" href="system_context.html#boost_asio.reference.system_context.friends">Friends</a> 231 </h5> 232<div class="informaltable"><table class="table"> 233<colgroup> 234<col> 235<col> 236</colgroup> 237<thead><tr> 238<th> 239 <p> 240 Name 241 </p> 242 </th> 243<th> 244 <p> 245 Description 246 </p> 247 </th> 248</tr></thead> 249<tbody> 250<tr> 251<td> 252 <p> 253 <a class="link" href="system_context/add_service.html" title="system_context::add_service"><span class="bold"><strong>add_service</strong></span></a> 254 </p> 255 </td> 256<td> 257 <p> 258 (Deprecated: Use make_service().) Add a service object to the execution_context. 259 </p> 260 </td> 261</tr> 262<tr> 263<td> 264 <p> 265 <a class="link" href="system_context/has_service.html" title="system_context::has_service"><span class="bold"><strong>has_service</strong></span></a> 266 </p> 267 </td> 268<td> 269 <p> 270 Determine if an execution_context contains a specified service 271 type. 272 </p> 273 </td> 274</tr> 275<tr> 276<td> 277 <p> 278 <a class="link" href="system_context/make_service.html" title="system_context::make_service"><span class="bold"><strong>make_service</strong></span></a> 279 </p> 280 </td> 281<td> 282 <p> 283 Creates a service object and adds it to the execution_context. 284 </p> 285 </td> 286</tr> 287<tr> 288<td> 289 <p> 290 <a class="link" href="system_context/use_service.html" title="system_context::use_service"><span class="bold"><strong>use_service</strong></span></a> 291 </p> 292 </td> 293<td> 294 <p> 295 Obtain the service object corresponding to the given type. 296 </p> 297 </td> 298</tr> 299</tbody> 300</table></div> 301<h5> 302<a name="boost_asio.reference.system_context.h4"></a> 303 <span class="phrase"><a name="boost_asio.reference.system_context.requirements"></a></span><a class="link" href="system_context.html#boost_asio.reference.system_context.requirements">Requirements</a> 304 </h5> 305<p> 306 <span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/system_context.hpp</code> 307 </p> 308<p> 309 <span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code> 310 </p> 311</div> 312<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr> 313<td align="left"></td> 314<td align="right"><div class="copyright-footer">Copyright © 2003-2020 Christopher M. 315 Kohlhoff<p> 316 Distributed under the Boost Software License, Version 1.0. (See accompanying 317 file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>) 318 </p> 319</div></td> 320</tr></table> 321<hr> 322<div class="spirit-nav"> 323<a accesskey="p" href="streambuf.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../boost_asio.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="system_context/add_service.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a> 324</div> 325</body> 326</html> 327