protected function _captureOutput(callable $callable, $args = null)
    {
        // Default
        if (is_null($args)) {
            $args = [];
        }

        ob_start();
        $this->_invokeCallable($callable, $args);
        $output = ob_get_clean();

        return $output;
    }
protected function _captureOutput(callable $callable, $args = null)
    {
        // Default
        if (is_null($args)) {
            $args = [];
        }

        ob_start();
        $this->_invokeCallable($callable, $args);
        $output = ob_get_clean();

        return $output;
    }
protected function _captureOutput ( callable $ callable , $ args = null ) { // Default if ( is_null ( $ args ) ) { $ args = [ ] ; } ob_start ( ) ; $ this -> _invokeCallable ( $ callable , $ args ) ; $ output = ob_get_clean ( ) ; return $ output ; }
Invokes the given callable, and returns the output as a string.

@since [*next-version*]

@param callable                        $callable The callable that may produce output.
@param array|stdClass|Traversable|null $args     The arguments to invoke the callable with. Defaults to empty array.

@throws InvalidArgumentException If the callable or the args list are invalid.
@throws RootException            If a problem occurs.

@return string The output.
Invokes the given callable and returns the output as a string .