Sha256: b14a6fecb3aad445cc7adc06ecd087bde1d31dde9ce6c745d461f603e233acfb
Contents?: true
Size: 678 Bytes
Versions: 4
Compression:
Stored size: 678 Bytes
Contents
module GeoConcerns module Processors module Ogr extend ActiveSupport::Concern included do # Executes a ogr2ogr command. Used to reproject a # vector dataset and save the output as a shapefile # @param in_path [String] file input path # #param options [Hash] creation options # @param out_path [String] processor output file path def self.reproject(in_path, out_path, options) execute "env SHAPE_ENCODING= ogr2ogr -q -nln #{options[:basename]} -f 'ESRI Shapefile'"\ " -t_srs #{options[:output_srid]} -preserve_fid '#{out_path}' '#{in_path}'" end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems