title: How to implement multiple inheritance in delphi?
body: <p>I'm doing a full rewrite of an old library, and I'm not sure how to handle this situation (for the sake of being understood, all hail the bike analogy):</p>
  
  <p>I have the following classes:</p>
  
  <ul>
  <li><code>TBike</code> - the bike itself</li>
  <li><code>TBikeWheel</code> - one of the bike's wheel</li>
  <li><code>TBikeWheelFront</code> and <code>TBikeWheelBack</code>, both inherits from <code>TBikeWheel</code> and then implements the specific stuff they need on top of it</li>
  </ul>
  
  <p>This is pretty straightforward, but now I decide to create multiple kind of bikes, each bikes having it's own kinds of wheel - they do the same stuff as a regular front/back wheels, plus the specific for that bike.</p>
  
  <ul>
  <li><code>TBikeXYZ</code> - inherits from <code>TBike</code></li>
  <li><code>TBikeWheelXYZ</code> - inherits from <code>TBikeWheel</code></li>
  </ul>
  
  <p>And here is my problem: <code>TBikeWheelFrontXYZ</code> should inherit from <code>TBikeWheelXYZ</code> (to get the specific methods of an XYZ wheel), but it should also inherit from <code>TBikeWheelFront</code> (to get the specific methods of a front wheel).</p>
  
  <p>My question here is, how can I implement that in a way that doesn't:</p>
  
  <ol>
  <li>feel like a hack</li>
  <li>force me to rewrite the same code several time</li>
  </ol>