Class: String
- Inherits
-
Object
- Object
- String
- Defined in
- lib/drumherum/regexp.rb
Instance Method Summary (collapse)
-
- (String) show_regexp(regular_expression)
Easy development of regular expressions.
Instance Method Details
- (String) show_regexp(regular_expression)
Easy development of regular expressions.
10 11 12 13 14 15 16 |
# File 'lib/drumherum/regexp.rb', line 10 def show_regexp(regular_expression) if self =~ regular_expression "#{$`}<<#{$&}>>#{$'}" else "no match" end # if end |