Package

vectorpipe

osm

Permalink

package osm

Types and functions unique to working with OpenStreetMap data.

Linear Supertypes
AnyRef, Any
Ordering
  1. Grouped
  2. Alphabetic
  3. By Inheritance
Inherited
  1. osm
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. sealed trait Element extends AnyRef

    Permalink

    A sum type for OSM Elements.

    A sum type for OSM Elements. All Element types share some common attributes.

  2. case class ElementMeta(id: Long, user: String, uid: Long, changeset: Long, version: Long, minorVersion: Long, timestamp: Instant, visible: Boolean, tags: Map[String, String]) extends Product with Serializable

    Permalink

    All Element types have these attributes in common.

  3. case class Features(points: RDD[Feature[Point, ElementMeta]], lines: RDD[Feature[Line, ElementMeta]], polygons: RDD[Feature[Polygon, ElementMeta]], multiPolys: RDD[Feature[MultiPolygon, ElementMeta]]) extends Product with Serializable

    Permalink

    A meaningful wrapping around the various geometry types that can be produced from the OSM-to-Features conversion.

    A meaningful wrapping around the various geometry types that can be produced from the OSM-to-Features conversion. By keeping each Geometry subtype separate, the user can discard types they don't need.

  4. case class Member(typeOf: String, ref: Long, role: String) extends Product with Serializable

    Permalink
  5. case class Node(lat: Double, lon: Double, meta: ElementMeta) extends Element with Product with Serializable

    Permalink

    Some point in the world, which could represent a location or small object like a park bench or flagpole.

  6. type OSMFeature = Feature[Geometry, ElementMeta]

    Permalink
  7. case class Relation(members: List[Member], meta: ElementMeta) extends Element with Product with Serializable

    Permalink
  8. case class Way(nodes: Vector[Long], meta: ElementMeta) extends Element with Product with Serializable

    Permalink

    A string of Nodes which could represent a road, or if connected back around to itself, a building, water body, landmass, etc.

    A string of Nodes which could represent a road, or if connected back around to itself, a building, water body, landmass, etc.

    Assumption: A Way has at least two distinct nodes.

Value Members

  1. object ElementMeta extends Serializable

    Permalink
  2. object Member extends Serializable

    Permalink
  3. object Node extends Serializable

    Permalink
  4. object Relation extends Serializable

    Permalink
  5. object Way extends Serializable

    Permalink
  6. def features(ns: RDD[(Long, Node)], ws: RDD[(Long, Way)], rs: RDD[(Long, Relation)]): Features

    Permalink

    All Lines and Polygons that could be reconstructed from a set of all OSM Elements.

  7. def fromDataFrame(data: DataFrame): (RDD[(Long, Node)], RDD[(Long, Way)], RDD[(Long, Relation)])

    Permalink

    Given a DataFrame that follows this table schema, read out RDDs of each Element type.

  8. def fromLocalXML(path: String)(implicit sc: SparkContext): Try[(RDD[(Long, Node)], RDD[(Long, Way)], RDD[(Long, Relation)])]

    Permalink

    Given a path to an OSM XML file, parse it into usable types.

  9. def fromORC(path: String)(implicit ss: SparkSession): Try[(RDD[(Long, Node)], RDD[(Long, Way)], RDD[(Long, Relation)])]

    Permalink

    Given a path to an Apache ORC file containing OSM data, read out RDDs of each Element type.

Inherited from AnyRef

Inherited from Any

Reading OSM Elements

Element Conversion

Converting OSM Elements into GeoTrellis geometries.

Ungrouped