function __construct($class, $loadColumns = true)
{
$this->table = strtolower($class);
$this->relationships = array();
$this->properties = array();
$this->source = false;
if ($loadColumns) {
$this->columns = $this->getSource()->getColumns($this->table);
} else {
$this->columns = array();
}
$this->primaryKeyColumn = 'id';
$this->modelClass = $class;
}