Classy Inheritance simplifies the definition and implementation of one
object depending on another object. For example, a User object
a Person object. If you do the following:
class User < ActiveRecord::Base
depends_on :person, :attrs => [:first_name, :last_name, :email]
You will get @user.first_name, @user.last_name and @user.email
functionality. So, direct usage of these attributes can be used on your
form and the Person associated is created/maintained for you. e.g.:
<% text_field :user, :first_name %>
Classy Inheritance also supports polymorphic associations, more info on
In this release:
Added two options for the depends_on call: validates_presence_if,
These options allow you to determine if/when the validation is called.
Validation is on by default.
There is a wiki, forum and issue tracking for Classy Inheritance at