class Regex::Concatenation
Abstract class. A n-ary matching operator. It succeeds when each child succeeds to match the subject text in the same serial arrangement than defined by this concatenation.
Public Class Methods
new(*theChildren)
click to toggle source
Constructor.
Calls superclass method
# File lib/regex/concatenation.rb, line 13 def initialize(*theChildren) super(theChildren) end
Protected Instance Methods
text_repr()
click to toggle source
Conversion method re-definition. Purpose: Return the String representation of the concatented expressions.
# File lib/regex/concatenation.rb, line 21 def text_repr outcome = children.inject(+'') do |result, child| result << child.to_str end return outcome end