protected function generateClass($properties, $tablename, $classname, $toString)
{
$props = implode("\n", $properties);
$relations = $this->_renderRelations($tablename);
$date = date('Y-m-d h:i:s');
$env_user = getenv("username");
return <<<EOD
<?php
/**
* Auto generated by PRADO - WSAT on {$date}.
* @author {$env_user}
*/
class {$classname} extends TActiveRecord
{
\tconst TABLE='{$tablename}';
{$props}
\tpublic static function finder(\$className=__CLASS__) {
return parent::finder(\$className);
\t}
{$relations}
{$toString}
}
EOD;
}