Class/Object

geotrellis.vector.io.json

JsonFeatureCollection

Related Docs: object JsonFeatureCollection | package json

Permalink

class JsonFeatureCollection extends AnyRef

Accumulates GeoJson from Feature class instances.

During serialization: Each individual feature is parametrized on a class we need to accumulate geoJson per instance of an object in order to use implicit scope resolution in finding the correct format.

Features may be added using the .add, addAll methods, they are buffered as JsValues until .toJson is called

During deserialization: This object is instantiated with list of JsValues representing features. It may be queried using .getAll[F <: Feature[_] ] method.

It aggregates feature objects with data member still encoded in json

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

Instance Constructors

  1. new JsonFeatureCollection(features: List[JsValue] = Nil)

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. def ++=[G <: Geometry, D](features: Seq[Feature[G, D]])(implicit arg0: JsonWriter[D]): Unit

    Permalink

    Add a Seq of JsValue to the buffer, pending an ultimate call of toJson

  4. def +=[G <: Geometry, D](feature: Feature[G, D])(implicit arg0: JsonWriter[D]): ListBuffer[JsValue]

    Permalink

    Add a JsValue to the buffer, pending an ultimate call of toJson

  5. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  6. def add[G <: Geometry, D](feature: Feature[G, D])(implicit arg0: JsonWriter[D]): ListBuffer[JsValue]

    Permalink

    Add a JsValue to the buffer, pending an ultimate call of toJson

  7. def addAll[G <: Geometry, D](features: Seq[Feature[G, D]])(implicit arg0: JsonWriter[D]): Unit

    Permalink

    Add a Seq of JsValue to the buffer, pending an ultimate call of toJson

  8. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  9. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  10. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  11. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  12. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. def getAll[F](implicit arg0: JsonReader[F]): Vector[F]

    Permalink

    This method locates the correct JsonFormat for F through implicit scope and attempts to use it to parse each contained JsValue.

    This method locates the correct JsonFormat for F through implicit scope and attempts to use it to parse each contained JsValue.

    F

    type of Feature to return

    returns

    Vector of Feature objects (type F) that were successfully parsed

  14. def getAllFeatures[F <: Feature[_, _]](implicit arg0: JsonReader[F]): Vector[F]

    Permalink
  15. def getAllLineFeatures[D]()(implicit arg0: JsonReader[D]): Vector[LineFeature[D]]

    Permalink
  16. def getAllLines(): Vector[Line]

    Permalink
  17. def getAllMultiLineFeatures[D]()(implicit arg0: JsonReader[D]): Vector[MultiLineFeature[D]]

    Permalink
  18. def getAllMultiLines(): Vector[MultiLine]

    Permalink
  19. def getAllMultiPointFeatures[D]()(implicit arg0: JsonReader[D]): Vector[MultiPointFeature[D]]

    Permalink
  20. def getAllMultiPoints(): Vector[MultiPoint]

    Permalink
  21. def getAllMultiPolygonFeatures[D]()(implicit arg0: JsonReader[D]): Vector[MultiPolygonFeature[D]]

    Permalink
  22. def getAllMultiPolygons(): Vector[MultiPolygon]

    Permalink
  23. def getAllPointFeatures[D]()(implicit arg0: JsonReader[D]): Vector[PointFeature[D]]

    Permalink
  24. def getAllPoints(): Vector[Point]

    Permalink
  25. def getAllPolygonFeatures[D]()(implicit arg0: JsonReader[D]): Vector[PolygonFeature[D]]

    Permalink
  26. def getAllPolygons(): Vector[Polygon]

    Permalink
  27. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  28. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  29. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  30. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  31. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  32. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  33. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  34. def toJson: JsValue

    Permalink

    Carry out serialization on all buffered JsValues

  35. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  36. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  37. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  38. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped