Module: RGeo::Geos::ZMGeometryCollectionMethods

Includes:
Enumerable
Included in:
ZMGeometryCollectionImpl, ZMMultiLineStringImpl, ZMMultiPointImpl, ZMMultiPolygonImpl
Defined in:
lib/rgeo/geos/zm_feature_methods.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#eachObject


395
396
397
398
399
# File 'lib/rgeo/geos/zm_feature_methods.rb', line 395

def each
  num_geometries.times do |i_|
    yield geometry_n(i_)
  end
end

#geometry_n(n_) ⇒ Object Also known as: []


389
390
391
# File 'lib/rgeo/geos/zm_feature_methods.rb', line 389

def geometry_n(n_)
  @factory._create_feature(nil, @zgeometry.geometry_n(n_), @mgeometry.geometry_n(n_))
end

#num_geometriesObject Also known as: size


383
384
385
# File 'lib/rgeo/geos/zm_feature_methods.rb', line 383

def num_geometries
  @zgeometry.num_geometries
end