Sha256: 2abb8ed6bfc3e1049a34e2451e8d67af635aa96aa66ae2924dcf6f872d43527e

Contents?: true

Size: 535 Bytes

Versions: 8

Compression:

Stored size: 535 Bytes

Contents

# $Id: libxml.rb 374 2008-07-11 04:51:41Z cfis $ 
# Please see the LICENSE file for copyright and distribution information 


module LibXML
  module XML
    class Node
      class Set 
        include Enumerable 

        # inefficient, but maybe can find a way to cache the
        # ary and dump on change?
        def [](i, count = nil) 
          if count
            to_a[i,count]
          else
            to_a[i]
          end
        end

        def to_s #:nodoc:
          to_a.to_s
        end
      end
    end
  end
end  

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
libxml-ruby-0.8.0 lib/libxml/node_set.rb
libxml-ruby-0.8.0-x86-mswin32-60 lib/libxml/node_set.rb
libxml-ruby-0.8.1 lib/libxml/node_set.rb
libxml-ruby-0.8.1-x86-mswin32-60 lib/libxml/node_set.rb
libxml-ruby-0.8.2 lib/libxml/node_set.rb
libxml-ruby-0.8.2-x86-mswin32-60 lib/libxml/node_set.rb
libxml-ruby-0.8.3 lib/libxml/node_set.rb
libxml-ruby-0.8.3-x86-mswin32-60 lib/libxml/node_set.rb