lithium\data\collection\RecordSet::_init()

protected method

Initializes the record set and uses the database connection to get the column list contained in the query that created this object.

Returns

void

Source

	protected function _init() {
		parent::_init();

		if (!$this->_result) {
			return;
		}
		$this->_columns = $this->_columnMap();

		if (!$this->_query) {
			return;
		}
		$this->_keyIndex = $this->_keyIndex();

		$this->_dependencies = Set::expand(Set::normalize(
			array_filter(array_keys($this->_columns))
		));
		$this->_relationships = $this->_query->relationships();
	}