Class: GithubToCanvasQuiz::Parser::Markdown::Answer::FillInMultipleBlanks

Inherits:
Base
  • Object
show all
Defined in:
lib/github_to_canvas_quiz/parser/markdown/answer/fill_in_multiple_blanks.rb

Instance Attribute Summary

Attributes inherited from Base

#answer_nodes, #comment, #title

Instance Method Summary collapse

Methods inherited from Base

#initialize

Methods included from Helpers::NodeParser

#parse_text_from_node, #parse_text_from_nodes

Constructor Details

This class inherits a constructor from GithubToCanvasQuiz::Parser::Markdown::Answer::Base

Instance Method Details

#parseObject



8
9
10
11
12
13
14
15
16
# File 'lib/github_to_canvas_quiz/parser/markdown/answer/fill_in_multiple_blanks.rb', line 8

def parse
  text, blank_id = parse_text_from_nodes(answer_nodes, 'li')
  Model::Answer::FillInMultipleBlanks.new(
    title: title,
    text: text,
    comments: comment,
    blank_id: blank_id
  )
end