Cleanup

Formatting etc.
Cleanup

Formatting etc.
Virtual properties

If ModelBase::set_data() is provided with more columns than what
natively belongs to the table, and the model has set property of the
same name as the column set, then the property will be available like a
native property.
Cleanup

Formatting etc.
Added query log

The db adapter now implements a get_query_log() method that will output
an array of all the queries run.
Collection counter optimisation

The Countable interface was improved - if the collection has a counter
method registered, it will be used instead of loading the contents of
the collection.

If the collection is a ModelCollection, and is a collection of a
relation - HM or HABTM - the counter method will be set automatically.