Skip to content

rerFeatureServer item

Giovanni Lughi edited this page Sep 5, 2025 · 7 revisions

DEPRECATED ITEM!!

A CatalogItem representing a layer from a custom Regione Emilia-Romagna server, built upon an ESRI ArcGIS FeatureServer.

This item borns to allow a more customizable use of billboards.

"LEVEL_ID" feature property is the minimum zoom level from which the feature is visibile.

It can be used in catalog definition.

This item has all properties of a ArcGIS FeatureServer and some others described below.

Property Type Default Description
cacheFeatures bool true If true, features are cached.
levelMax number 16 Max features zoom level.
levelMin number 7 Min features zoom level.
lowPitchAngle number 30 Define upper bound of lowPitch range (lower bound is veryLowPitchAngle), in degrees.
veryLowPitchAngle number 15 Define uppre bound of veryLowPitchAngle range (lower bound is 0), in degrees.
distanceFilter object undefined Instance of distanceFilter (see below), defines feature distance filter.
labels object all labels use { show: true, font: “16px Titillium Web”, fillColor: “white”, backgroundColor: “transparent” } Instance of labels (see below), defines labels policy of displayed features.
icons object all icons use {"marker-size": "large", "marker-symbol": "marker", "marker-color": "blue"} Instance of icons (see below), defines features icon.

distanceFilter

Defines the visibility policy for the features of the layer.

Property Type Description
hideFeaturesOnVeryLowPitch bool If true, when pitch angle of camera is less than veryLowPitch, hide all features.
nearestPerLevel object Defines features filter by closeness for each zoom level: features are sorted by distance from observer, only the N closest features are shown (see below).
displayDistanceMaxPerLevel object Defines features filter by distance for each zoom level: a feature is shown only if its distance from the observer is less than filter value of its level (see below).

nearestPerLevel

Property Type Description
isEnabled bool Enable/disable the filter.
nearest array Array of integer with an element for each zoom level between levelMin and levelMax; the element value represents the number of features shown at the specific LEVEL_ID (N closest features).

In the following example the nearestPerLevel filter is enabled on a layer with 10 zoom levels (from 7 to 16) with features. Values of nearest array indicates how many features are visible for each LEVEL_ID values. Features visible are the N features closest to the point in the middle of the screen. So at zoom level 7 are displayed 5 features, at zoom level 8 are displayed 10 features (5 + 5), at zoom level 9 are displayed 15 features (5 + 5 + 5), at zoom level 10 are displayed 25 features (5 + 5 + 5 + 10), and so on.

"nearestPerLevel": {
  "isEnabled": false,
  "nearest": [
    5,  // Shows only the 5 closest features with LEVEL_ID = 7 (levelMin)
    5,  // Shows only the 5 closest features with LEVEL_ID = 8
    5,  // Shows only the 5 closest features with LEVEL_ID = 9
    10, // Shows only the 10 closest features with LEVEL_ID = 10
    10, // Shows only the 10 closest features with LEVEL_ID = 11
    10, // Shows only the 10 closest features with LEVEL_ID = 12
    20, // Shows only the 20 closest features with LEVEL_ID = 13
    20, // Shows only the 20 closest features with LEVEL_ID = 14
    1,  // Shows only the 1 closest features with LEVEL_ID = 15
    5   // Shows only the 5 closest features with LEVEL_ID = 16 (levelMax)
]},

displayDistanceMaxPerLevel

Property Type Description
isEnabled bool Enable/disable the filter.
distances array Array of integer with an element for each zoom level between levelMin and levelMax; if the distance between a feature and the observer is greater then the element value, that features is hided.

In the following example the displayDistanceMaxPerLevel filter is enabled on a layer with 10 zoom levels (from 7 to 16) with features. Values of distances array indicates the distance threshold for each LEVEL_ID values. Are displayed only features whose distance from the point in the middle of the screen is less than level threshold.

 "displayDistanceMaxPerLevel": {
  "isEnabled": true,
  "distances": [
    50000, // Shows features with LEVEL_ID = 7 (levelMin) only if distance is less than 50000m
    40000, // Shows features with LEVEL_ID = 8 only if distance is less than 40000m
    32000, // Shows features with LEVEL_ID = 9 only if distance is less than 32000m
    25000, // Shows features with LEVEL_ID = 10 only if distance is less than 25000m
    19000, // Shows features with LEVEL_ID = 11 only if distance is less than 19000m
    14000, // Shows features with LEVEL_ID = 12 only if distance is less than 14000m
    10000, // Shows features with LEVEL_ID = 13 only if distance is less than 10000m
    7000,  // Shows features with LEVEL_ID = 14 only if distance is less than 7000m
    5000,  // Shows features with LEVEL_ID = 15 only if distance is less than 5000m
    4000   // Shows features with LEVEL_ID = 16 (levelMax) only if distance is less than 4000m
]},

labels

Defines classes of appearance properties for features label, related to zoom level.

Property Type Description
classPerLevel number or array In case of number it rapresents index of the only class used for all labels; in case of array it rapresents index of classes used for label of each zoom level (one array element for each zoom level between levelMin and levelMax).
classes array Array of objects, each object is a label style class. For each class you can set:
* visibility of this class features with show (true or false),
* threshold distance beyond which a feature is hided with displayDistanceMax (meters),
* text font with font (dimension in pixel and font name, ie "16px Titillium Web"),
* text color with fillColor (textual or hex),
* background color with backgroundColor (textual or hex).

icons

Defines classes of appearance properties for features icon, related to a feature field.

Property Type Description
field string Name of the layer field to use to assign a class to a feature (ie "ID_DOMINIO").
classes object Dictionary of icon style classes: key are field values, for each class you can set:
* icon dimension with "marker-size" ("small", "medium" or "large"),
* symbol with "marker-symbol" (from Maki set),
* color with "marker-color" (textual or hex).

Full example

            {
              "name": "POI",
              "type": "rer-featureServer",
              "url": "",
              "isEnabled": true,
              "isShown": true,
              "cacheFeatures": true,
              "levelMax": 16,
              "levelMin": 7,
              "lowPitchAngle": 30,
              "veryLowPitchAngle": 15,
              "distanceFilter": {
                "hideFeaturesOnVeryLowPitch": false,
                "nearestPerLevel": {
                  "isEnabled": false,
                  "nearest": [
                    5,
                    5,
                    5,
                    10,
                    10,
                    10,
                    20,
                    20,
                    1,
                    5
                ]},
                "displayDistanceMaxPerLevel": {
                  "isEnabled": true,
                  "distances": [
                    50000,
                    40000,
                    32000,
                    25000,
                    19000,
                    14000,
                    10000,
                    7000,
                    5000,
                    4000
                  ],
                  "veryLowPitchDistances": [
                    30000,
                    28000,
                    25000,
                    19000,
                    14000,
                    10000,
                    7000,
                    5000,
                    4000,
                    3000
                ]}
              },
              "labels": {
                "classPerLevel": 0,
                "classes": [
                  {},
                  {
                    "font": "16px Titillium Web",
                    "fillColor": "red",
                    "backgroundColor": "transparent",
                    "displayDistanceMax": 0
                  }
                ]
              },
              "icons": {
                "field": "ID_DOMINIO",
                "classes": {
                  "1": {
                    "marker-symbol": "village"
                  },
                  "2": {
                    "marker-symbol": "village"
                  },
                  "3": {
                    "marker-symbol": "industrial"
                  },
                  "4": {
                    "marker-symbol": "village",
                    "marker-color": "#ff0"
                  },
                  "5": {
                    "marker-symbol": "village",
                    "marker-color": "#333"
                  },
                  "6": {
                    "marker-symbol": "village",
                    "marker-color": "#fff"
                  },
                  "7": {
                    "marker-symbol": "square"
                  },
                  "8": {
                    "marker-symbol": "cross"
                  },
                  "9": {
                    "marker-symbol": "mountain"
                  },
                  "10": {
                    "marker-symbol": "triangle"
                  },
                  "11": {
                    "marker-symbol": "triangle-stroked"
                  },
                  "12": {
                    "marker-symbol": "marker"
                  },
                  "13": {
                    "marker-symbol": "water"
                  },
                  "14": {
                    "marker-symbol": "water"
                  },
                  "15": {
                    "marker-symbol": "marker"
                  },
                  "16": {
                    "marker-symbol": "water"
                  },
                  "17": {
                    "marker-symbol": "water"
                  },
                  "18": {
                    "marker-symbol": "water"
                  },
                  "19": {
                    "marker-symbol": "marker"
                  },
                  "20": {
                    "marker-symbol": "marker"
                  },
                  "21": {
                    "marker-symbol": "marker"
                  },
                  "22": {
                    "marker-symbol": "marker"
                  },
                  "23": {
                    "marker-symbol": "water"
                  },
                  "24": {
                    "marker-symbol": "marker"
                  },
                  "601": {
                    "marker-symbol": "town"
                  },
                  "602": {
                    "marker-symbol": "city"
                  },
                  "603": {
                    "marker-symbol": "city"
                  }
                }
              }
            }

Clone this wiki locally