title: Factory / Abstract Factory confusion
body: <p>After ~10 months of procedural PHP, I'm now trying to wrap my head around basic OOP principles and design patterns. This is a hobby, and I haven't nearly as much time as I'd like to pursue it, so please forgive the rather low level of this question.</p>
  
  <p>My site (currently 100% procedural) is at heart a library. Visitors send the Library script 2 datapoints - an item <code>type</code> and item <code>code</code>.</p>
  
  <p><code>Library.php</code> uses the item type to select an include, and the include grabs the code to hit the database and then build the page.</p>
  
  <p>Some examples:</p>
  
  <pre><code>[type]  [code]
   game    RoTo
   map     32
   unit    216
  </code></pre>
  
  <p>An example link would be <code>library.php?type=game&amp;code=RoTo</code></p>
  
  <p>Everything works nicely as is, but as I get started with OOP I see obvious easy entry points and inheritance paths for "objectifying" this system.</p>
  
  <pre><code>class LibraryObject
  {
      protected $_name;
      protected $_description;
  }
  
  class Game extends LibraryObject
  {
      protected $_releaseDate;
      etc.
  }
  </code></pre>
  
  <p>I'm also excited about the flexibility some well-written classes will give me.</p>
  
  <p>The design pattern idea is tripping me up, though. It seems like a Factory pattern, but I'm confused about the differences between <strong>F</strong> and <strong>AF</strong>. I've read other SO questions specifically asking that question, and I've read the examples on <a href="http://www.oodesign.com" rel="noreferrer">OODesign</a> but I feel like they're written in a different language and it's rather frustrating.</p>
  
  <p>Perhaps if someone could explain it using my own data structures it would make more sense to me?</p>
  
  <p>Sorry for the trouble.</p>