1<html> 2<head> 3<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 4<title>Files</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="../../index.html" title="Chapter 1. Boost.Beast"> 8<link rel="up" href="../using_io.html" title="Networking"> 9<link rel="prev" href="buffer_types.html" title="Buffer Types"> 10<link rel="next" href="writing_composed_operations.html" title="Writing Composed Operations"> 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="buffer_types.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../using_io.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="writing_composed_operations.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="beast.using_io.files"></a><a class="link" href="files.html" title="Files">Files</a> 28</h3></div></div></div> 29<p> 30 Often when implementing network algorithms such as servers, it is necessary 31 to interact with files on the system. Beast defines the <a class="link" href="../concepts/File.html" title="File"><span class="emphasis"><em>File</em></span></a> 32 concept and several models to facilitate cross-platform interaction with 33 the underlying filesystem: 34 </p> 35<div class="table"> 36<a name="beast.using_io.files.file_types"></a><p class="title"><b>Table 1.11. File Types</b></p> 37<div class="table-contents"><table class="table" summary="File Types"> 38<colgroup> 39<col> 40<col> 41</colgroup> 42<thead><tr> 43<th> 44 <p> 45 Name 46 </p> 47 </th> 48<th> 49 <p> 50 Description 51 </p> 52 </th> 53</tr></thead> 54<tbody> 55<tr> 56<td> 57 <p> 58 <a class="link" href="../ref/boost__beast__file.html" title="file"><code class="computeroutput"><span class="identifier">file</span></code></a> 59 </p> 60 </td> 61<td> 62 <p> 63 <code class="computeroutput"><span class="identifier">file</span></code> is a type 64 alias to one of the following implementations, depending on what 65 is available on the target platform. 66 </p> 67 </td> 68</tr> 69<tr> 70<td> 71 <p> 72 <a class="link" href="../ref/boost__beast__file_stdio.html" title="file_stdio"><code class="computeroutput"><span class="identifier">file_stdio</span></code></a> 73 </p> 74 </td> 75<td> 76 <p> 77 This implementation of <a class="link" href="../concepts/File.html" title="File"><span class="emphasis"><em>File</em></span></a> 78 uses the C++ standard library facilities obtained by including 79 <code class="computeroutput"><span class="special"><</span><span class="identifier">cstdio</span><span class="special">></span></code>. 80 </p> 81 </td> 82</tr> 83<tr> 84<td> 85 <p> 86 <a class="link" href="../ref/boost__beast__file_win32.html" title="file_win32"><code class="computeroutput"><span class="identifier">file_win32</span></code></a> 87 </p> 88 </td> 89<td> 90 <p> 91 This implements a <a class="link" href="../concepts/File.html" title="File"><span class="emphasis"><em>File</em></span></a> 92 for the Win32 API. It provides low level access to the native file 93 handle when necessary. 94 </p> 95 </td> 96</tr> 97<tr> 98<td> 99 <p> 100 <a class="link" href="../ref/boost__beast__file_posix.html" title="file_posix"><code class="computeroutput"><span class="identifier">file_posix</span></code></a> 101 </p> 102 </td> 103<td> 104 <p> 105 For POSIX systems, this class provides a suitable implementation 106 of <a class="link" href="../concepts/File.html" title="File"><span class="emphasis"><em>File</em></span></a> 107 which wraps the native file descriptor and provides it if necessary. 108 </p> 109 </td> 110</tr> 111</tbody> 112</table></div> 113</div> 114<br class="table-break"> 115</div> 116<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr> 117<td align="left"></td> 118<td align="right"><div class="copyright-footer">Copyright © 2016-2019 Vinnie 119 Falco<p> 120 Distributed under the Boost Software License, Version 1.0. (See accompanying 121 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>) 122 </p> 123</div></td> 124</tr></table> 125<hr> 126<div class="spirit-nav"> 127<a accesskey="p" href="buffer_types.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../using_io.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="writing_composed_operations.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a> 128</div> 129</body> 130</html> 131