class Regexp::Expression::Conditional::Expression
def <<(exp)
def <<(exp) expressions.last << exp end
def add_sequence(active_opts = {}, params = { ts: 0 })
def add_sequence(active_opts = {}, params = { ts: 0 }) raise TooManyBranches.new if branches.length == 2 params = params.merge({ conditional_level: conditional_level + 1 }) Branch.add_to(self, params, active_opts) end
def branches
def branches select { |subexp| subexp.is_a?(Sequence) } end
def condition
def condition find { |subexp| subexp.is_a?(Condition) } end
def condition=(exp)
def condition=(exp) expressions.delete(condition) expressions.unshift(exp) end
def reference
def reference condition.reference end