Class: Ciphr::Functions::Reader::StringReader::StringProc

Inherits:
Object
  • Object
show all
Defined in:
lib/ciphr/functions/reader.rb

Overview

extend Proc?

Instance Method Summary collapse

Constructor Details

#initialize(str) ⇒ StringProc

Returns a new instance of StringProc.



11
12
13
# File 'lib/ciphr/functions/reader.rb', line 11

def initialize(str)
  @str = str
end

Instance Method Details

#callObject



15
16
17
18
19
20
21
# File 'lib/ciphr/functions/reader.rb', line 15

def call
  begin
    @str
  ensure
    @str = nil
  end
end