Class: SpatialFeatures::Importers::KML

Inherits:
Base
  • Object
show all
Defined in:
lib/spatial_features/importers/kml.rb

Direct Known Subclasses

KMLFile

Constant Summary collapse

IMAGE_METADATA_KEYS =

<SimpleData name> keys that may contain <img> tags

%w[pdfmaps_photos].freeze
COORDINATES_WITH_ALTITUDE =

matches a coordinate pair with an optional altitude, including invalid altitudes like NaN

-118.1,50.9,NaN
-118.1,50.9,0
-118.1,50.9
/(?<lng>\S+),(?<lat>\S+),(?<alt>\S+)/.freeze

Instance Attribute Summary

Attributes inherited from Base

#errors, #source_identifier

Instance Method Summary collapse

Methods inherited from Base

#cache_key, create_all, #features

Constructor Details

#initialize(data, base_dir: nil, **options) ⇒ KML

Returns a new instance of KML.



15
16
17
18
# File 'lib/spatial_features/importers/kml.rb', line 15

def initialize(data, base_dir: nil, **options)
  @base_dir = base_dir
  super data, **options
end