class ZhSieve::HTMLPage

Attributes

answer_id[RW]
article_id[RW]
contents[RW]
question_id[RW]

Public Class Methods

new(options) click to toggle source
# File lib/zhSieve/htmlpage.rb, line 7
def initialize(options)
  @contents = options[:contents].body
  @question_id = options[:question_id]
  @answer_id = options[:answer_id]
  @article_id = options[:article_id]
end

Public Instance Methods

answerMarkdown() click to toggle source
# File lib/zhSieve/htmlpage.rb, line 18
def answerMarkdown
  @markdown = answer_to_markdown(@contents,@question_id,@answer_id)
end
articleMarkdown() click to toggle source
# File lib/zhSieve/htmlpage.rb, line 22
def articleMarkdown
  @markdown = article_to_markdown(@contents,@article_id)
end
markdown() click to toggle source
# File lib/zhSieve/htmlpage.rb, line 30
def markdown
  @markdown ||= markdown!
end
markdown!() click to toggle source
# File lib/zhSieve/htmlpage.rb, line 34
def markdown!
  @markdown = to_markdown(@contents)
end
peopleMarkdown() click to toggle source
# File lib/zhSieve/htmlpage.rb, line 14
def peopleMarkdown
  @markdown = people_to_markdown(@contents)
end
to_html() click to toggle source
# File lib/zhSieve/htmlpage.rb, line 26
def to_html
  @html =  @contents
end