Class: RubyPython::PyEnumerable
- Inherits:
-
RubyPyProxy
- Object
- BlankSlate
- BlankObject
- RubyPyProxy
- RubyPython::PyEnumerable
- Includes:
- Enumerable
- Defined in:
- lib/rubypython/rubypyproxy.rb
Overview
An object representing a Python enumerable object.
Instance Attribute Summary
Attributes inherited from RubyPyProxy
Instance Method Summary collapse
Methods inherited from RubyPyProxy
#initialize, #inspect, #is_real_method?, #method_missing, #methods, #respond_to?, #rubify, #to_a, #to_enum, #to_s
Methods included from Operators
#<=>, #[], #[]=, bin_op, #include?, operator_, rel_op, unary_op, update
Methods inherited from BlankObject
Constructor Details
This class inherits a constructor from RubyPython::RubyPyProxy
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class RubyPython::RubyPyProxy
Instance Method Details
#each ⇒ Object
325 326 327 328 329 330 331 332 333 334 |
# File 'lib/rubypython/rubypyproxy.rb', line 325 def each iter = self.__iter__ loop do begin yield iter.next rescue RubyPython::PythonError => exc return if exc. =~ /StopIteration/ end end end |