Class: RegexpExamples::SingleCharGroup

Inherits:
Object
  • Object
show all
Defined in:
lib/regexp-examples/groups.rb

Instance Method Summary collapse

Constructor Details

#initialize(char) ⇒ SingleCharGroup

Returns a new instance of SingleCharGroup.



22
23
24
# File 'lib/regexp-examples/groups.rb', line 22

def initialize(char)
  @char = char
end

Instance Method Details

#resultObject



25
26
27
# File 'lib/regexp-examples/groups.rb', line 25

def result
  [GroupResult.new(@char)]
end