title: Rails: get all field for an object coming from the database
body: <p>Let's say I have an <code>Foo</code> <code>ActiveRecord</code> model with fields <code>foo_id</code>, <code>foo_name</code> and <code>foo_description</code>.</p>
  
  <p>After doing something like </p>
  
  <pre><code>@foo = Foo.find(1)
  </code></pre>
  
  <p>Is there any method "<code>model_fields</code>" such that: <code>@foo.model_fields()</code> would return the array:</p>
  
  <pre><code>["foo_id", "foo_name", "foo_description"] ?
  </code></pre>
  
  <p>Thanks for the help.</p>