Module: Textoken::RegexpOption

Includes:
ConditionalOption
Included in:
ExcludeRegexp, OnlyRegexp
Defined in:
lib/textoken/options/modules/regexp_option.rb

Overview

This module will be shared in options like, only_regexp and exclude_regexp

Instance Attribute Summary

Attributes included from ConditionalOption

#base, #findings, #regexps

Attributes included from TokenizableOption

#base

Instance Method Summary collapse

Methods included from ConditionalOption

#priority

Methods included from TokenizableOption

#tokenize

Instance Method Details

#initialize(value) ⇒ Object



6
7
8
9
# File 'lib/textoken/options/modules/regexp_option.rb', line 6

def initialize(value)
  @regexps  = [Regexp.new(value)]
  @findings = Findings.new
end