public function render_grade_link($counts, $type, $gradestring, $gradequestionurl) {
        $output = '';
        if ($counts->$type > 0) {
            $output .= ' ' . html_writer::link(
                            $gradequestionurl,
                            get_string($gradestring, 'quiz_grading'),
                            ['class' => 'gradetheselink']);
        }
        return $output;
    }
public function render_grade_link($counts, $type, $gradestring, $gradequestionurl) {
        $output = '';
        if ($counts->$type > 0) {
            $output .= ' ' . html_writer::link(
                            $gradequestionurl,
                            get_string($gradestring, 'quiz_grading'),
                            ['class' => 'gradetheselink']);
        }
        return $output;
    }
public function render_grade_link ( $ counts , $ type , $ gradestring , $ gradequestionurl ) { $ output = '' ; if ( $ counts -> $ type > 0 ) { $ output .= ' ' . html_writer :: link ( $ gradequestionurl , get_string ( $ gradestring , 'quiz_grading' ) , [ 'class' => 'gradetheselink' ] ) ; } return $ output ; }
Render grade link for question.

@param object $counts
@param string $type Type of grade.
@param string $gradestring Lang string.
@param moodle_url $gradequestionurl Url to grade question.
@return string The HTML for the question grade link.
@throws coding_exception
Render grade link for question .