src/Support/Container/BoundCallable.php
/**
	 * Makes a copy of this bound callable for a new callable. The objects in the bound callable, as well as the
	 * service container it binds to, will be copied.
	 *
	 * @param callable $callable
	 * @return BoundCallable
	 */
Makes a copy of this bound callable for a new callable. The objects in the bound callable, as well as the
service container it binds to, will be copied.

@param callable $callable
@return BoundCallable
Makes a copy of this bound callable for a new callable . The objects in the bound callable as well as the service container it binds to will be copied . @param callable $callable @return BoundCallable
public function copy($callable) {
		$callable = new BoundCallable($callable, $this->container);
		foreach ($this->objects as $name => $instance) {
			if ($name == 'Horizon\Support\Container\BoundCallable') continue;
			$callable->with($instance);
		}
		foreach ($this->variables as $name => $value) {
			$callable->where($name, $value);
		}
		return $callable;
	}
public function copy ( $ callable ) { $ callable = new BoundCallable ( $ callable , $ this -> container ) ; foreach ( $ this -> objects as $ name => $ instance ) { if ( $ name == 'Horizon\Support\Container\BoundCallable' ) continue ; $ callable -> with ( $ instance ) ; } foreach ( $ this -> variables as $ name => $ value ) { $ callable -> where ( $ name , $ value ) ; } return $ callable ; }
Makes a copy of this bound callable for a new callable.
Makes a copy of this bound callable for a new callable .