@lbdudc/gp-gis-dsl 0.3.1 → 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/.claude/settings.local.json +7 -0
  2. package/grammar/.antlr/GISGrammar.interp +182 -0
  3. package/grammar/.antlr/GISGrammar.tokens +73 -0
  4. package/grammar/.antlr/GISGrammarBaseListener.java +579 -0
  5. package/grammar/.antlr/GISGrammarLexer.interp +241 -0
  6. package/grammar/.antlr/GISGrammarLexer.java +686 -0
  7. package/grammar/.antlr/GISGrammarLexer.tokens +73 -0
  8. package/grammar/.antlr/GISGrammarListener.java +459 -0
  9. package/grammar/.antlr/GISGrammarParser.java +2948 -0
  10. package/grammar/GISGrammar.g4 +313 -313
  11. package/package.json +1 -1
  12. package/parse-file.js +73 -0
  13. package/src/GISVisitorHelper.js +93 -93
  14. package/src/cli.js +34 -34
  15. package/src/error/ErrorListener.js +26 -26
  16. package/src/error/SyntaxGenericError.js +18 -18
  17. package/src/index.js +4 -1
  18. package/src/lib/GISGrammar.interp +181 -181
  19. package/src/lib/GISGrammarLexer.interp +241 -241
  20. package/src/lib/GISGrammarLexer.js +202 -202
  21. package/src/lib/GISGrammarListener.js +1 -1
  22. package/src/lib/GISGrammarParser.js +1 -1
  23. package/src/lib/GISGrammarVisitor.js +1 -1
  24. package/src/spl/GIS.js +234 -234
  25. package/src/spl/GeoJSONLayer.js +21 -21
  26. package/src/spl/GeoJSONLayerStyle.js +14 -14
  27. package/src/spl/TileLayer.js +16 -16
  28. package/src/spl/WMSLayer.js +30 -30
  29. package/src/spl/WMSStyle.js +13 -13
  30. package/src/spl/WMSStyleCustom.js +22 -22
  31. package/src/store.js +74 -74
  32. package/test-examples.js +120 -0
  33. package/test-output/agriculture.json +429 -0
  34. package/test-output/basic.json +315 -0
  35. package/test-output/complete.json +1259 -0
  36. package/test-output/emergency.json +755 -0
  37. package/test-output/environmental.json +591 -0
  38. package/test-output/gis.json +254 -0
  39. package/test-output/tourism.json +704 -0
  40. package/test-output/transportation.json +488 -0
  41. package/test-output/utilities.json +620 -0
  42. package/test-output/wms.json +110 -0
@@ -0,0 +1,254 @@
1
+ {
2
+ "features": [
3
+ "MapViewer",
4
+ "ChartViewer",
5
+ "Tools",
6
+ "DM_SpatialDatabase",
7
+ "DM_GenerationType",
8
+ "MV_MapServer",
9
+ "MV_Tools",
10
+ "MV_MapManagement",
11
+ "DM_SD_PostGIS",
12
+ "DM_GT_Sequence",
13
+ "MV_MM_MultipleMapViewer",
14
+ "MV_MM_MMV_MapSelectorInMapViewer",
15
+ "MV_MM_MMV_MapSelectorInMenuElement",
16
+ "MV_MS_GeoServer",
17
+ "GUI_Lists",
18
+ "GUI_L_FormLink",
19
+ "GUI_L_F_BasicSearch",
20
+ "GUI_L_Filterable",
21
+ "GUI_L_Sortable",
22
+ "GUI_L_LocateInMap",
23
+ "GUI_L_ViewListAsMap",
24
+ "MV_ContextInformation",
25
+ "MV_CI_Scale",
26
+ "MV_CI_Map",
27
+ "MV_CI_CenterCoordinates",
28
+ "MV_CI_Dimensions",
29
+ "MV_DetailOnClick",
30
+ "MV_LayerManagement",
31
+ "MV_LM_CenterViewOnLayer",
32
+ "MV_LM_Order",
33
+ "MV_LM_Opacity",
34
+ "MV_LM_HideLayer",
35
+ "MV_LM_Style",
36
+ "MV_LM_ExternalLayer",
37
+ "MV_LM_StylePreview",
38
+ "MV_T_E_Type",
39
+ "MV_T_E_F_URL",
40
+ "MV_T_E_F_PDF",
41
+ "MV_T_E_SetScale",
42
+ "MV_T_E_ShowLegend",
43
+ "MV_T_InformationMode",
44
+ "MV_T_MeasureControl",
45
+ "MV_T_ZoomWindow",
46
+ "MV_T_ViewMapAsList",
47
+ "DM_DataInput",
48
+ "DM_DI_DataFeeding",
49
+ "DM_DI_DF_Shapefile",
50
+ "T_GIS",
51
+ "T_EntitiesInformation",
52
+ "D_C_Postgres",
53
+ "D_C_Geoserver",
54
+ "D_C_Nginx"
55
+ ],
56
+ "basicData": {
57
+ "name": "maritime_coruña",
58
+ "extra": {
59
+ "geoserver_user": "admin",
60
+ "geoserver_password": "geoserver",
61
+ "geoserver_url_wms": "http://localhost:8080/geoserver"
62
+ }
63
+ },
64
+ "data": {
65
+ "dataModel": {
66
+ "entities": [
67
+ {
68
+ "name": "Buoy",
69
+ "properties": [
70
+ {
71
+ "name": "id",
72
+ "class": "Long (autoinc)",
73
+ "pk": true,
74
+ "required": true,
75
+ "unique": true
76
+ },
77
+ {
78
+ "name": "buoy_id",
79
+ "class": "String",
80
+ "required": true,
81
+ "unique": true
82
+ },
83
+ {
84
+ "name": "name",
85
+ "class": "String"
86
+ },
87
+ {
88
+ "name": "geometry",
89
+ "class": "Point"
90
+ }
91
+ ],
92
+ "displayString": "$id"
93
+ },
94
+ {
95
+ "name": "River",
96
+ "properties": [
97
+ {
98
+ "name": "id",
99
+ "class": "Long (autoinc)",
100
+ "pk": true,
101
+ "required": true,
102
+ "unique": true
103
+ },
104
+ {
105
+ "name": "name",
106
+ "class": "String",
107
+ "required": true
108
+ },
109
+ {
110
+ "name": "length",
111
+ "class": "Double"
112
+ },
113
+ {
114
+ "name": "geometry",
115
+ "class": "LineString"
116
+ }
117
+ ],
118
+ "displayString": "$id"
119
+ },
120
+ {
121
+ "name": "Municipality",
122
+ "properties": [
123
+ {
124
+ "name": "id",
125
+ "class": "Long (autoinc)",
126
+ "pk": true,
127
+ "required": true,
128
+ "unique": true
129
+ },
130
+ {
131
+ "name": "name",
132
+ "class": "String",
133
+ "required": true
134
+ },
135
+ {
136
+ "name": "population",
137
+ "class": "Long"
138
+ },
139
+ {
140
+ "name": "geometry",
141
+ "class": "MultiPolygon"
142
+ }
143
+ ],
144
+ "displayString": "$id"
145
+ }
146
+ ],
147
+ "enums": []
148
+ }
149
+ },
150
+ "mapViewer": {
151
+ "maps": [
152
+ {
153
+ "name": "maritime_view",
154
+ "label": "Maritime Map of Coruña",
155
+ "sortable": false,
156
+ "layers": [
157
+ {
158
+ "name": "osm",
159
+ "baseLayer": true,
160
+ "selected": true
161
+ },
162
+ {
163
+ "name": "rivers",
164
+ "baseLayer": false,
165
+ "selected": true
166
+ },
167
+ {
168
+ "name": "municipalities",
169
+ "baseLayer": false,
170
+ "selected": true
171
+ },
172
+ {
173
+ "name": "buoys",
174
+ "baseLayer": false,
175
+ "selected": true
176
+ }
177
+ ]
178
+ }
179
+ ],
180
+ "layers": [
181
+ {
182
+ "name": "osm",
183
+ "type": "tilelayer",
184
+ "label": "OpenStreetMap",
185
+ "url": "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"
186
+ },
187
+ {
188
+ "name": "rivers",
189
+ "type": "wms",
190
+ "label": "Rivers",
191
+ "list": "River",
192
+ "layers": [
193
+ "River"
194
+ ],
195
+ "availableStyles": [
196
+ "river_style"
197
+ ],
198
+ "defaultStyles": "river_style"
199
+ },
200
+ {
201
+ "name": "municipalities",
202
+ "type": "wms",
203
+ "label": "Municipalities",
204
+ "list": "Municipality",
205
+ "layers": [
206
+ "Municipality"
207
+ ],
208
+ "availableStyles": [
209
+ "municipality_style"
210
+ ],
211
+ "defaultStyles": "municipality_style"
212
+ },
213
+ {
214
+ "name": "buoys",
215
+ "type": "geojson",
216
+ "label": "Buoy Locations",
217
+ "entityName": "Buoy",
218
+ "editable": true,
219
+ "defaultStyle": "buoysStyle",
220
+ "availableStyles": [
221
+ "buoysStyle"
222
+ ]
223
+ }
224
+ ],
225
+ "styles": [
226
+ {
227
+ "name": "river_style",
228
+ "type": "WMSLayerStyle",
229
+ "geometryType": "LINESTRING",
230
+ "fillColor": null,
231
+ "strokeColor": "#0000FF",
232
+ "fillOpacity": null,
233
+ "strokeOpacity": null
234
+ },
235
+ {
236
+ "name": "municipality_style",
237
+ "type": "WMSLayerStyle",
238
+ "geometryType": "POLYGON",
239
+ "fillColor": "#CCFFCC",
240
+ "strokeColor": "#669966",
241
+ "fillOpacity": 0.3,
242
+ "strokeOpacity": null
243
+ },
244
+ {
245
+ "name": "buoysStyle",
246
+ "type": "GeoJSONLayerStyle",
247
+ "fillColor": "#0000FF",
248
+ "strokeColor": "#0000FF",
249
+ "fillOpacity": "1.0",
250
+ "strokeOpacity": "0.5"
251
+ }
252
+ ]
253
+ }
254
+ }