public function joins($name = null, $join = null) {
		if (is_array($name)) {
			$join = $name;
			$name = null;
		}
		if ($join) {
			if (!$name) {
				$this->_config['joins'][] = $join;
			} else {
				$this->_config['joins'][$name] = $join;
			}
			return $this;
		}
		if (!$name) {
			return $this->_config['joins'];
		}
		if (isset($this->_config['joins'][$name])) {
			return $this->_config['joins'][$name];
		}
	}
public function joins($name = null, $join = null) {
		if (is_array($name)) {
			$join = $name;
			$name = null;
		}
		if ($join) {
			if (!$name) {
				$this->_config['joins'][] = $join;
			} else {
				$this->_config['joins'][$name] = $join;
			}
			return $this;
		}
		if (!$name) {
			return $this->_config['joins'];
		}
		if (isset($this->_config['joins'][$name])) {
			return $this->_config['joins'][$name];
		}
	}
public function joins ( $ name = null , $ join = null ) { if ( is_array ( $ name ) ) { $ join = $ name ; $ name = null ; } if ( $ join ) { if ( ! $ name ) { $ this -> _config [ 'joins' ] [ ] = $ join ; } else { $ this -> _config [ 'joins' ] [ $ name ] = $ join ; } return $ this ; } if ( ! $ name ) { return $ this -> _config [ 'joins' ] ; } if ( isset ( $ this -> _config [ 'joins' ] [ $ name ] ) ) { return $ this -> _config [ 'joins' ] [ $ name ] ; } }
Set and get the joins

@param string $name Optional name of join. Unless two parameters are passed, this parameter
is regonized as `$join`.
@param object|string $join A single query object or an array of query objects
@return mixed The joins array or a join array if `$name` is set. Returns `null` if a join
doesn't exist.
Set and get the joins