<?php

/**
 * Description of ExcerptRecord
 *
 * @author ain
 */

class ErrorRecord extends CActiveRecord {

	public function rules() {
		return array(
			array('message', 'safe'),
			array('url', 'safe'),
			array('linenumber', 'safe'),
			array('data', 'safe'),
			array('useragent', 'safe')
		);
	}

	/**
	 * @return string the associated database table name
	 */
	public function tableName()
	{
		return '{{error}}';
	}

	public function primaryKey() {
		return 'code';
	}

	/**
	 * Returns the static model of the specified AR class.
	 * @return CActiveRecord the static model class
	 */
	public static function model($className=__CLASS__)
	{
		return parent::model($className);
	}
}

