protected function validateTaskResult(Result $result)
    {
        if ($result->getExitCode() !== Result::EXITCODE_OK) {
            throw new TaskResultRuntimeException($result);
        }

        return $result;
    }
protected function validateTaskResult(Result $result)
    {
        if ($result->getExitCode() !== Result::EXITCODE_OK) {
            throw new TaskResultRuntimeException($result);
        }

        return $result;
    }
protected function validateTaskResult ( Result $ result ) { if ( $ result -> getExitCode ( ) !== Result :: EXITCODE_OK ) { throw new TaskResultRuntimeException ( $ result ) ; } return $ result ; }
Validate task result.

@param Result $result

@return Result
@throws TaskResultRuntimeException
Validate task result .