Class: Furnace::Code::SeparatedToken
Instance Attribute Summary
#children
Attributes inherited from Token
#origin
Instance Method Summary
collapse
#text_after, #text_before
#initialize
Methods inherited from Token
#initialize, #subscribe, type, #type, #unsubscribe
Instance Method Details
#text_between ⇒ Object
4
5
6
|
# File 'lib/furnace/code/separated_token.rb', line 4
def text_between
""
end
|
#to_structure(options = {}) ⇒ Object
12
13
14
|
# File 'lib/furnace/code/separated_token.rb', line 12
def to_structure(options={})
structurize "#{text_before} #{([text_between] * 3).join(" ")} #{text_after}", options
end
|
#to_text ⇒ Object
8
9
10
|
# File 'lib/furnace/code/separated_token.rb', line 8
def to_text
"#{text_before}#{children.map(&:to_text).join(text_between)}#{text_after}"
end
|