search for: billablecustom

Displaying 1 result from an estimated 1 matches for "billablecustom".

Did you mean: billablecustomer
2006 Jun 22
0
Domain modelling and ActiveRecords
Hi all, I am wondering if this could be a good idea to support the Object#extend method for an ActiveRecord class. Let''s say I have a customer (with a corresponding customer table in the DB). At one point, this customer becomes a "BillableCustomer" (with data in another table for billing information). Wouldn''t it be nice to write: customer.extend(Billable) customer.billingAddress = ... customer.save This way, you could implement Actor-Role patterns without the necessity to create 2 classes representing the same logica...