Use declarative syntax to define attributes

- Attributes declared in the class via 'attribute :name'
- The next step is to move the common code for resources into an abstract class and inherit from that.
Use AbstractResource to DRY up resource classes

  - Moved into AbstractResource
    - initialization
    - attribute creation
    - parametrization (via mixin)