Class: Mutest::AST::Regexp::Transformer::Quantifier::ASTToExpression::Interval Private

Inherits:
Object
  • Object
show all
Defined in:
lib/mutest/ast/regexp/transformer/quantifier.rb

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Instance Method Summary collapse

Constructor Details

#initializeInterval

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of Interval.



101
102
103
104
105
106
107
# File 'lib/mutest/ast/regexp/transformer/quantifier.rb', line 101

def initialize(*)
  super

  unless valid_min? && valid_max?
    fail ArgumentError, 'Unexpected quantifier interval bound.'
  end
end

Instance Method Details

#to_sObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



109
110
111
# File 'lib/mutest/ast/regexp/transformer/quantifier.rb', line 109

def to_s
  "{#{compacted_interval.join(',')}}"
end