I'm using ActiveResource to consume a REST service. The xml from the service looks like:
<Person>
<FirstName>Kevin</FirstName>
<LastName>Berridge</LastName>
</Person>
ActiveResource parses this just fine, but it uses the names verbatim. So the model class will look like:
p = Person.find(1)
p.FirstName
p.LastName
I would much prefer if this would follow the Ruby naming conventions and look like:
p = Person.find(1)
p.first_name
p.last_name
Does ActiveResource have a way to do this? Is there a way I can hook into ActiveResource and add this?