title: When to use a Constructor and when to use getInstance() method (static factory methods)?
body: <ol>
  <li><p>When and how should we use a constructor</p>
  
  <pre><code>Foo bar = new Foo();
  </code></pre></li>
  <li><p>And when and how should we use getInstance() (static factory methods)</p>
  
  <pre><code>Foo bar = Foo.getInstance();
  </code></pre></li>
  </ol>
  
  <p>What is the difference between these two? I have always used a constructor, but when should I use <code>getInstance()</code> instead?</p>