<areahref="classcrashpad_1_1FileReaderInterface.html"title="An interface to read to files and other file-like objects with semantics matching the underlying plat..."alt="crashpad::FileReaderInterface"shape="rect"coords="0,56,183,80"/>
<areahref="classcrashpad_1_1FileWriterInterface.html"title="An interface to write to files and other file-like objects with semantics matching the underlying pla..."alt="crashpad::FileWriterInterface"shape="rect"coords="193,56,376,80"/>
<areahref="classcrashpad_1_1FileSeekerInterface.html"title="An interface to seek in files and other file-like objects with semantics matching the underlying plat..."alt="crashpad::FileSeekerInterface"shape="rect"coords="0,0,183,24"/>
<areahref="classcrashpad_1_1FileSeekerInterface.html"title="An interface to seek in files and other file-like objects with semantics matching the underlying plat..."alt="crashpad::FileSeekerInterface"shape="rect"coords="193,0,376,24"/>
<trclass="memdesc:aa3ee94c41f187734e74e74feab1cd756"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Returns a string containing the virtual file’s contents. <br/></td></tr>
<trclass="memdesc:a294a955a7a0baa9a595fa73b33578708"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Sets the virtual file’s contents to <em>string</em>, and resets its file position to <code>0</code>. <br/></td></tr>
<trclass="memdesc:acc9180465c3147b38c6d6aa4049f8958"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Resets the virtual file’s contents to be empty, and resets its file position to <code>0</code>. <br/></td></tr>
<trclass="memdesc:a05de4b2d8ef91a974181d7340c61b346"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Wraps <aclass="el"href="namespacecrashpad.html#a8599600814a17d622766decd5f122a96"title="Reads from a file, retrying when interrupted before reading any data on POSIX. ">ReadFile()</a>, or provides an implementation with identical semantics. <ahref="#a05de4b2d8ef91a974181d7340c61b346">More...</a><br/></td></tr>
<trclass="memdesc:aa7e22ad48bbedf3e1e6a257cfba0c137"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Wraps <aclass="el"href="namespacecrashpad.html#a8a91af9c690d2a280c463596bf82070b"title="Wraps WriteFile(), ensuring that exactly size bytes are written. ">LoggingWriteFile()</a>, or provides an implementation with identical semantics. <ahref="#aa7e22ad48bbedf3e1e6a257cfba0c137">More...</a><br/></td></tr>
<trclass="memdesc:aa5b57a3a13ee4f973dc7984fbc6e3237"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Wraps <code>writev()</code> on POSIX or provides an alternate implementation with identical semantics. This method will write entire buffers, continuing after a short write or after being interrupted. On non-POSIX this is a simple wrapper around <aclass="el"href="classcrashpad_1_1StringFile.html#aa7e22ad48bbedf3e1e6a257cfba0c137"title="Wraps LoggingWriteFile(), or provides an implementation with identical semantics. ...">Write()</a>. <ahref="#aa5b57a3a13ee4f973dc7984fbc6e3237">More...</a><br/></td></tr>
<trclass="memitem:acabb59b99e86bea5949f7a9a47c6dbcc"><tdclass="memItemLeft"align="right"valign="top"><aclass="el"href="namespacecrashpad.html#a1e53a1957d9edcba8b406ea632b6daf2">FileOffset</a> </td><tdclass="memItemRight"valign="bottom"><aclass="el"href="classcrashpad_1_1StringFile.html#acabb59b99e86bea5949f7a9a47c6dbcc">Seek</a> (<aclass="el"href="namespacecrashpad.html#a1e53a1957d9edcba8b406ea632b6daf2">FileOffset</a> offset, int whence) override</td></tr>
<trclass="memdesc:acabb59b99e86bea5949f7a9a47c6dbcc"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Wraps <aclass="el"href="namespacecrashpad.html#a3d6cedc10e24145d4a0c1000c33f8a10"title="Wraps lseek() or SetFilePointerEx(). Logs an error if the operation fails. ">LoggingSeekFile()</a> or provides an alternate implementation with identical semantics. <ahref="#acabb59b99e86bea5949f7a9a47c6dbcc">More...</a><br/></td></tr>
<trclass="inherit_header pub_methods_classcrashpad_1_1FileReaderInterface"><tdcolspan="2"onclick="javascript:toggleInherit('pub_methods_classcrashpad_1_1FileReaderInterface')"><imgsrc="closed.png"alt="-"/> Public Member Functions inherited from <aclass="el"href="classcrashpad_1_1FileReaderInterface.html">crashpad::FileReaderInterface</a></td></tr>
<trclass="memdesc:ad046f1ebf1071eb6b92a2a8d06c14a56 inherit pub_methods_classcrashpad_1_1FileReaderInterface"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Wraps <aclass="el"href="classcrashpad_1_1FileReaderInterface.html#ad9035ff345274f33cef248712d53d9e1"title="Wraps ReadFile(), or provides an implementation with identical semantics. ">Read()</a>, ensuring that the read succeeded and exactly <em>size</em> bytes were read. <ahref="classcrashpad_1_1FileReaderInterface.html#ad046f1ebf1071eb6b92a2a8d06c14a56">More...</a><br/></td></tr>
<trclass="inherit_header pub_methods_classcrashpad_1_1FileSeekerInterface"><tdcolspan="2"onclick="javascript:toggleInherit('pub_methods_classcrashpad_1_1FileSeekerInterface')"><imgsrc="closed.png"alt="-"/> Public Member Functions inherited from <aclass="el"href="classcrashpad_1_1FileSeekerInterface.html">crashpad::FileSeekerInterface</a></td></tr>
<trclass="memdesc:a49a884bfb0a61461b0291c975aa15382 inherit pub_methods_classcrashpad_1_1FileSeekerInterface"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Wraps <aclass="el"href="classcrashpad_1_1FileSeekerInterface.html#a8d56f7d12dfcce3e4a39ad1524302aa1"title="Wraps LoggingSeekFile() or provides an alternate implementation with identical semantics. ">Seek()</a>, using <code>SEEK_CUR</code> to obtain the file’s current position. <ahref="classcrashpad_1_1FileSeekerInterface.html#a49a884bfb0a61461b0291c975aa15382">More...</a><br/></td></tr>
<trclass="memdesc:add2e1ee642d94c91ef722911e9aee250 inherit pub_methods_classcrashpad_1_1FileSeekerInterface"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Wraps <aclass="el"href="classcrashpad_1_1FileSeekerInterface.html#a8d56f7d12dfcce3e4a39ad1524302aa1"title="Wraps LoggingSeekFile() or provides an alternate implementation with identical semantics. ">Seek()</a>, using <code>SEEK_SET</code>, ensuring that the seek succeeded and the file is positioned as desired. <ahref="classcrashpad_1_1FileSeekerInterface.html#add2e1ee642d94c91ef722911e9aee250">More...</a><br/></td></tr>
<divclass="textblock"><p>A file reader and writer backed by a virtual file, as opposed to a file on disk or other operating system file descriptor-based file. </p>
<p>The virtual file is a buffer in memory. This class is convenient for use with other code that normally expects to read or write files, when it is impractical or inconvenient to read or write a file. It is expected that tests, in particular, will benefit from using this class. </p>
</div><h2class="groupheader">Member Function Documentation</h2>
<p>Wraps <aclass="el"href="namespacecrashpad.html#a8599600814a17d622766decd5f122a96"title="Reads from a file, retrying when interrupted before reading any data on POSIX. ">ReadFile()</a>, or provides an implementation with identical semantics. </p>
<dlclass="section return"><dt>Returns</dt><dd>The number of bytes actually read if the operation succeeded, which may be <code>0</code> or any positive value less than or equal to <em>size</em>. <code>-1</code> if the operation failed, with an error message logged. </dd></dl>
<p>Wraps <aclass="el"href="namespacecrashpad.html#a3d6cedc10e24145d4a0c1000c33f8a10"title="Wraps lseek() or SetFilePointerEx(). Logs an error if the operation fails. ">LoggingSeekFile()</a> or provides an alternate implementation with identical semantics. </p>
<dlclass="section return"><dt>Returns</dt><dd>The return value of <aclass="el"href="namespacecrashpad.html#a3d6cedc10e24145d4a0c1000c33f8a10"title="Wraps lseek() or SetFilePointerEx(). Logs an error if the operation fails. ">LoggingSeekFile()</a>. <code>-1</code> on failure, with an error message logged. </dd></dl>
<p>Wraps <aclass="el"href="namespacecrashpad.html#a8a91af9c690d2a280c463596bf82070b"title="Wraps WriteFile(), ensuring that exactly size bytes are written. ">LoggingWriteFile()</a>, or provides an implementation with identical semantics. </p>
<dlclass="section return"><dt>Returns</dt><dd><code>true</code> if the operation succeeded, <code>false</code> if it failed, with an error message logged. </dd></dl>
<p>Wraps <code>writev()</code> on POSIX or provides an alternate implementation with identical semantics. This method will write entire buffers, continuing after a short write or after being interrupted. On non-POSIX this is a simple wrapper around <aclass="el"href="classcrashpad_1_1StringFile.html#aa7e22ad48bbedf3e1e6a257cfba0c137"title="Wraps LoggingWriteFile(), or provides an implementation with identical semantics. ...">Write()</a>. </p>
<dlclass="section return"><dt>Returns</dt><dd><code>true</code> if the operation succeeded, <code>false</code> if it failed, with an error message logged.</dd></dl>
<dlclass="section note"><dt>Note</dt><dd>The contents of <em>iovecs</em> are undefined when this method returns. </dd></dl>