Class: Mustermann::Regular
- Inherits:
-
RegexpBased
- Object
- Pattern
- RegexpBased
- Mustermann::Regular
- Defined in:
- lib/mustermann/regular.rb
Overview
Regexp pattern implementation.
Constant Summary
Constants inherited from Pattern
Constants included from Mustermann
Instance Attribute Summary
Attributes inherited from RegexpBased
Instance Method Summary collapse
-
#initialize(string, options = {}) ⇒ Pattern
constructor
A new instance of Pattern.
Methods inherited from RegexpBased
Methods inherited from Pattern
#&, #===, #=~, #^, #expand, #match, #named_captures, #names, new, #params, #peek, #peek_match, #peek_params, #peek_size, supported?, supported_options, #to_proc, #to_s, #to_templates, #|
Methods included from Mustermann
Constructor Details
#initialize(string, options = {}) ⇒ Pattern
Returns a new instance of Pattern.
17 18 19 20 |
# File 'lib/mustermann/regular.rb', line 17 def initialize(string, = {}) string = $1 if string.to_s =~ /\A\(\?\-mix\:(.*)\)\Z/ && string.inspect == "/#$1/" super(string, ) end |