lithium\data\model\Query::entity()

public method

Set and get method for the query's entity instance.

Parameters

  • object $entity

    Reference to the query's current entity object.

Returns

\lithium\data\Query|\lithium\data\Entity

Source

	public function &entity(&$entity = null) {
		if ($entity) {
			$this->_entity = $entity;
			return $this;
		}
		return $this->_entity;
	}