wvanbergen/request-log-analyzer — pull request #137 by richardkmichael (2013-03-18 13:53:57+00:00)
Title: Code cosmetics and allow classical inheritance to Just Work.

I wanted to use RLA on a custom log today, so I was code reading and tried for a bit of gardening. Unsure if you want this PR, it:

- trivially fixes the Bundler warning re: `:rubygems`
- makes the `github_gem.rake` task a bit easier to grok
- removes the inherited hook by defining methods on `RLA::FF::Base`

On this last bit, I thought the special-case of `subclass.superclass` revealed a duck-type, and the implementation was just doing classical OO-inheritance, e.g. if subclass.superclass.methodX, then make subclass.methodX call it. (Although the code was a bit tricky to unwind.)

I re-factored by adding `*_definers` and a `Request` class to `RLA::FF::Base` itself. No code used the setter (the original `attr_accessor` could have been `attr_reader`). So, no `attr_*` helpers are needed, just store the definers in ivars when getting them. With that done, the inherited hook can go.

Tests all pass. Hopefully I haven't broken anything for which there are no tests, or substantially wasted your time. ;-)