Sha256: 7ca7113d251d8de4b34a7865bf408aa9ac3a1590be89e0166447b96a6be546f3
Contents?: true
Size: 644 Bytes
Versions: 23
Compression:
Stored size: 644 Bytes
Contents
# encoding: utf-8 =begin Copyright(c) 2012 arton =end require 'rjb' module Rjb JIterable = import('java.lang.Iterable') JIterator = import('java.util.Iterator') module Iterable def each it = iterator while it.has_next yield it.next end end end module Iterator def each while has_next yield self.next end end end class Rjb_JavaProxy def initialize_proxy if JIterable.isInstance(self) include Iterable include Enumerable elsif JIterator.isInstance(self) include Iterator include Enumerable end end end end
Version data entries
23 entries across 23 versions & 1 rubygems