lib/db/cortex.php
protected function factory($mapper) {
		if (is_array($mapper)) {
			$mp = clone($this->mapper);
			$mp->reset();
			$cx = $this->factory($mp);
			$cx->copyfrom($mapper);
		} else {
			$cx = clone($this);
			$cx->reset(false);
			$cx->mapper = $mapper;
		}
		$cx->emit('load');
		return $cx;
	}
protected function factory($mapper) {
		if (is_array($mapper)) {
			$mp = clone($this->mapper);
			$mp->reset();
			$cx = $this->factory($mp);
			$cx->copyfrom($mapper);
		} else {
			$cx = clone($this);
			$cx->reset(false);
			$cx->mapper = $mapper;
		}
		$cx->emit('load');
		return $cx;
	}
protected function factory ( $ mapper ) { if ( is_array ( $ mapper ) ) { $ mp = clone ( $ this -> mapper ) ; $ mp -> reset ( ) ; $ cx = $ this -> factory ( $ mp ) ; $ cx -> copyfrom ( $ mapper ) ; } else { $ cx = clone ( $ this ) ; $ cx -> reset ( false ) ; $ cx -> mapper = $ mapper ; } $ cx -> emit ( 'load' ) ; return $ cx ; }
wrap result mapper
@param Cursor|array $mapper
@return Cortex
wrap result mapper