Sha256: 6eb0701971b3b9e5bb4a8e43be8dcb316bfd53f1d28d69f024e203d2f92bc0c0
Contents?: true
Size: 391 Bytes
Versions: 1
Compression:
Stored size: 391 Bytes
Contents
require 'geojson_model/base' module GeojsonModel class GeometryCollection include Base attribute :type, String, default: 'GeometryCollection' attribute :geometries, Array[GeojsonModel::Geometry] # @return [FeatureCollection] def to_feature_collection FeatureCollection.new(features: geometries.map { |geo| Feature.new(geometry: geo) }) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
geojson_model-0.1.1 | lib/geojson_model/geometry_collection.rb |