title: Is it possible to subclass UITableView and make it have an intrinsic content size for its height based on the number of cells?
body: <p>I want my <code>UITableView</code> to only be as tall as it needs to be, as it floats above the main <code>UIViewController</code>'s <code>view</code>. If I hardcode a height of 200 and theres' only one cell in the table, it looks silly.</p>
  
  <p>I'm aware in my view controller I could monitor the table view and define the height of it based on the number of cells it has, but the height is a property of the view, and for MVC it doesn't make much sense for the controller to be actively managing a view's height.</p>
  
  <p>Is it possible to have a <code>UITableView</code> subclass, and have it define an intrinsic height based on the number of cells it holds? So with Auto Layout I could add the subclass to my view, specify its width, center it vertically, and perhaps define a "less than or equal" height constraint saying to keep it smaller than 200pts.  But for the most part have the intrinsic content size of the view define the height of the view automatically?</p>
  
  <p>This would be just like a <code>UILabel</code> being able to be centered horizontally and vertically with some distance from the left and right, and have it grow and shrink vertically automatically.</p>
  
  <p>Could I feasibly do this with a <code>UITableView</code> subclass?</p>