title: Java Model View Controller for file reading
body: <p>I am having a lot of trouble designing a small program that reads a text document and writes statistics to a text file. We have to use a model-view-controller format that we haven't learned yet!</p>
  
  <p>Basically, the model class represents text from a text file and I need it to be stored in a String or String array. It also has to have methods to report number of words and stuff like that. The view class needs to have bufferedreader and writer. The control class creates the objects and calls the printResults() method.</p>
  
  <p>So I started with my control class having something like:</p>
  
  <pre><code>Model model = new Model();
  View view = new View( model );
  
  view.writeFile();
  </code></pre>
  
  <p>I have a feeling this is incorrect. How do I make my model class represent a text document, and send it to the View class to read it, and then have the view class invoke methods from the model class to write statistics? Is there a better approach or is there something I am missing here?</p>