Class: Tumblargh::Renderer::Blocks::Lines

Inherits:
Base show all
Defined in:
lib/tumblargh/renderer/blocks/chat.rb

Instance Attribute Summary

Attributes inherited from Tumblargh::Renderer::Base

#context, #node, #options

Instance Method Summary collapse

Methods inherited from Base

#should_render?

Methods inherited from Tumblargh::Renderer::Base

#context_post, contextual_tag, #escape_html, #escape_url, #initialize, #method_missing, #strip_html

Constructor Details

This class inherits a constructor from Tumblargh::Renderer::Base

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Tumblargh::Renderer::Base

Instance Method Details

#altObject

“odd” or “even” for each line of this post. TODO Implementation



13
14
# File 'lib/tumblargh/renderer/blocks/chat.rb', line 13

def alt
end

#renderObject



22
23
24
25
26
27
28
29
30
31
# File 'lib/tumblargh/renderer/blocks/chat.rb', line 22

def render
  if context.is_a? Resource::Dialogue
    super
  else
    context.dialogue.map do |l|
      l.context = self
      self.class.new(node, l).render
    end.flatten.join('')
  end
end

#user_numberObject

A unique identifying integer representing the user of the current line of this post. TODO Implementation



19
20
# File 'lib/tumblargh/renderer/blocks/chat.rb', line 19

def user_number
end