-
Notifications
You must be signed in to change notification settings - Fork 0
GeoJson properties
Vincent Sels edited this page Jan 14, 2016
·
1 revision
Aside from following the GeoJson spec, the GeoJson layer data returned by the REST API must have a couple of properties for this GNaP Map plugin to be able to work with it.
In regular GeoJson, the id
property of a Feature is optional. In order to work with this plugin, though, this id
is required, and must be unique among all features of any type used in the application. This can be achieved by using guids, or by prefixing the a numeric id with the layer type (which must also be unique within the application), e.g.: station-123
.
Every feature must have a type
property, which must correspond to the the data layer's itemType
.
In case the Feature's geometry is a Polygon
, it must have a center
property in the desired coordinate system.
-
label
: A label, if applicable. Can for example be displayed as text over the feature. -
info
: Additional one-line info, if applicable. Can for instance be displayed in a tooltip when hoovering over the feature.