public function export_to_xml($question, qformat_xml $format, $extra=null) {
        $expout = '';
        $expout .= $format->write_combined_feedback($question->options,
                                                    $question->id,
                                                    $question->contextid);
        $extraquestionfields = $this->extra_question_fields();
        array_shift($extraquestionfields);
        foreach ($extraquestionfields as $extra) {
            $expout .= "    <{$extra}>" . $question->options->$extra . "</{$extra}>\n";
        }
        return $expout;
    }
public function export_to_xml($question, qformat_xml $format, $extra=null) {
        $expout = '';
        $expout .= $format->write_combined_feedback($question->options,
                                                    $question->id,
                                                    $question->contextid);
        $extraquestionfields = $this->extra_question_fields();
        array_shift($extraquestionfields);
        foreach ($extraquestionfields as $extra) {
            $expout .= "    <{$extra}>" . $question->options->$extra . "</{$extra}>\n";
        }
        return $expout;
    }
public function export_to_xml ( $ question , qformat_xml $ format , $ extra = null ) { $ expout = '' ; $ expout .= $ format -> write_combined_feedback ( $ question -> options , $ question -> id , $ question -> contextid ) ; $ extraquestionfields = $ this -> extra_question_fields ( ) ; array_shift ( $ extraquestionfields ) ; foreach ( $ extraquestionfields as $ extra ) { $ expout .= "    <{$extra}>" . $ question -> options -> $ extra . "</{$extra}>\n" ; } return $ expout ; }
Exports the question to Moodle XML format.

@param object $question question to be exported into XML format
@param qformat_xml $format format class exporting the question
@param object $extra extra information (not required for exporting this question in this format)
@return string containing the question data in XML format
Exports the question to Moodle XML format .