You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

70 lines
1.6 KiB

13 years ago
<?php
13 years ago
/**
* ActiveRelation class file.
*
* @author Qiang Xue <qiang.xue@gmail.com>
* @link http://www.yiiframework.com/
* @copyright Copyright &copy; 2008-2012 Yii Software LLC
* @license http://www.yiiframework.com/license/
*/
13 years ago
namespace yii\db\ar;
13 years ago
use yii\db\dao\BaseQuery;
/**
* ActiveRelation represents the specification of a relation declared in [[ActiveRecord::relations()]].
*
* @author Qiang Xue <qiang.xue@gmail.com>
* @since 2.0
*/
class ActiveRelation extends BaseQuery
13 years ago
{
13 years ago
/**
* @var string the name of this relation
*/
13 years ago
public $name;
13 years ago
/**
13 years ago
* @var string the name of the model class that this relation represents
13 years ago
*/
13 years ago
public $modelClass;
13 years ago
/**
13 years ago
* @var boolean whether this relation is a one-many relation
13 years ago
*/
13 years ago
public $hasMany;
13 years ago
/**
13 years ago
* @var string the join type (e.g. INNER JOIN, LEFT JOIN). Defaults to 'LEFT JOIN' when
* this relation is used to load related records, and 'INNER JOIN' when this relation is used as a filter.
13 years ago
*/
13 years ago
public $joinType;
13 years ago
/**
13 years ago
* @var string the table alias used for the corresponding table during query
13 years ago
*/
13 years ago
public $tableAlias;
13 years ago
/**
13 years ago
* @var string the name of the column that the result should be indexed by.
* This is only useful when [[hasMany]] is true.
13 years ago
*/
13 years ago
public $indexBy;
13 years ago
/**
13 years ago
* @var string the ON clause of the join query
13 years ago
*/
13 years ago
public $on;
13 years ago
/**
13 years ago
* @var string
13 years ago
*/
13 years ago
public $via;
13 years ago
/**
13 years ago
* @var array the relations that should be queried together (eager loading)
13 years ago
*/
13 years ago
public $with;
13 years ago
/**
13 years ago
* @var array the relations that should be used as filters for this query
*/
public $filters;
/**
13 years ago
* @var array the scopes that should be applied during query
13 years ago
*/
13 years ago
public $scopes;
13 years ago
}