lib/rgeo/geos/ffi_factory.rb in rgeo-0.3.18 vs lib/rgeo/geos/ffi_factory.rb in rgeo-0.3.19

- old
+ new

@@ -52,12 +52,12 @@ # # See ::RGeo::Geos.factory for a list of supported options. def initialize(opts_={}) # Main flags - @uses_lenient_multi_polygon_assertions = opts_[:lenient_multi_polygon_assertions] || - opts_[:uses_lenient_multi_polygon_assertions] + @uses_lenient_multi_polygon_assertions = opts_[:uses_lenient_assertions] || + opts_[:lenient_multi_polygon_assertions] || opts_[:uses_lenient_multi_polygon_assertions] @has_z = opts_[:has_z_coordinate] ? true : false @has_m = opts_[:has_m_coordinate] ? true : false if @has_z && @has_m raise Error::UnsupportedOperation, "GEOS cannot support both Z and M coordinates at the same time." end @@ -142,11 +142,13 @@ @wkb_reader = nil end end - def inspect # :nodoc: + # Standard object inspection output + + def inspect "#<#{self.class}:0x#{object_id.to_s(16)} srid=#{srid}>" end # Factory equivalence test. @@ -158,9 +160,11 @@ @buffer_resolution == rhs_.property(:buffer_resolution) && @proj4.eql?(rhs_.proj4) end alias_method :==, :eql? + + # Standard hash code def hash @hash ||= [@srid, @has_z, @has_m, @buffer_resolution, @proj4].hash end