geojson-types-0.1.3: GeoJSON data types including JSON/BSON conversion.

Copyright(C) 2016 Markus Barenhoff
LicenseBSD-style (see the file LICENSE)
MaintainerMarkus Barenhoff <mbarenh@alios.org>
Stabilityprovisional
PortabilityFunctionalDependencies, TypeFamilies, GADTs RankNTypes
Safe HaskellNone
LanguageHaskell2010

Data.GeoJSON.Features

Contents

Description

 

Synopsis

Feature

data Feature v a t Source

A GeoJSON Feature record. See _FeatureJSON for feature records that can be converted from/to JSON. See _FeatureBSON for feature records that can be converted from/to BSON.

type FeatureJSON = Feature Value Source

feature records that can be converted from/to JSON.

_FeatureJSON :: (GeoJSONObject a, BaseType t) => Iso' (GeoJSON a t, Maybe Value, Value) (FeatureJSON a t) Source

convert from to a JSON Feature. The 3-tupel contains: a GeoJSONObject, an optional id, a properties value

type FeatureBSON = Feature Value Source

feature records that can be converted from/to BSON.

_FeatureBSON :: (GeoJSONObject a, BaseType t) => Iso' (GeoJSON a t, Maybe Value, Value) (FeatureBSON a t) Source

convert from to a BSON Feature. The 3-tupel contains: a GeoJSONObject, an optional id, a properties value

FeatureCollection

data FeatureCollection v t Source

a collection of multiple Feature

fcNew :: (GeoJSONObject a, BaseType t) => Feature v a t -> FeatureCollection v t Source

create a FeatureCollection with an initial element.

fcInsert :: (GeoJSONObject a, BaseType t) => FeatureCollection v t -> Feature v a t -> FeatureCollection v t Source

insert an element into a FeatureCollection