Skip to content

Commit

Permalink
Fix issue #89
Browse files Browse the repository at this point in the history
  • Loading branch information
eh3rrera committed Dec 16, 2019
1 parent 6355924 commit f2fb4a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ch23.html
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ <h2>BufferedWriter</h2>

<p><code class="java hljs"><span class="hljs-keyword">try</span> ( BufferedWriter bw =<br />
<span class="hljs-keyword">&nbsp; &nbsp; &nbsp;new</span> BufferedWriter( <span class="hljs-keyword">new</span> FileWriter(<span class="hljs-string">"/file.txt"</span>) ) ) {<br />
&nbsp; &nbsp;w.newLine(<span class="hljs-string">"Writing to the file..."</span>);<br />
&nbsp; &nbsp;w.write(<span class="hljs-string">"Writing to the file..."</span>);<br />
} <span class="hljs-keyword">catch</span>(IOException e) { <span class="hljs-comment">/** ... */</span> }</code></p>

<p>Since data is written to a buffer first, you can call the <code>flush()</code> method to make sure that the text written until that moment is indeed written to the disk.</p>
Expand Down

0 comments on commit f2fb4a7

Please sign in to comment.