title: Android: Reading from file (Openfileinput)
body: <p>I am trying to write a basic "notepad" app for a school project.</p>
  
  <p>I have created the main class with an <code>editText</code> which I save as <code>String</code> textOutput. </p>
  
  <p>I have used the following to save the string to a file:</p>
  
  <pre><code>FileOutputStream fos = openFileOutput(textOutput, Context.MODE_PRIVATE);
  fos.write(textOutput.getBytes());
  fos.close();
  </code></pre>
  
  <p>However <strong>Android Developers</strong> reference says in order to read I should use the following steps:</p>
  
  <blockquote>
    <p><strong>To read a file from internal storage:</strong></p>
    
    <ul>
    <li>Call <code>openFileInput()</code> and pass it the name of the file to read. This returns a <code>FileInputStream</code>.</li>
    <li>Read bytes from the file with <code>read()</code>.</li>
    <li>Then close the stream with <code>close()</code>.</li>
    </ul>
  </blockquote>
  
  <p>What does this mean, and how do I implement it?</p>