Module: RIO::Grande

Includes:
Match::Common
Included in:
Ops::Dir::Stream, Ops::Stream::Input
Defined in:
lib/rio/grande.rb

Overview

:nodoc: all

Instance Method Summary collapse

Methods included from Match::Common

#ss_type?

Instance Method Details

#[](*args) ⇒ Object



41
42
43
44
45
46
47
48
49
50
51
# File 'lib/rio/grande.rb', line 41

def [](*args)
  #p "#{callstr('[]',*args)} ss_type=#{cx['ss_type']} stream_iter=#{stream_iter?}"
  ss_args = cx['ss_args'] = args
  rtn = nil
  if ss_args and (ss_type = ss_type?(_ss_keys()))
    rtn = self.__send__(ss_type,*(ss_args)).to_a
  else
    rtn = to_a()
  end
  _ss_returns_first? ? _ss_return_first(rtn) : rtn
end