@golemio/ndic 1.0.7 → 1.0.8-dev.528010519
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.
- package/db/example/.config.json +3 -0
- package/db/example/00_reset.sql +1 -0
- package/db/example/01_reset3rdParty.sql +50 -0
- package/db/example/{sql_dump.sql → 02_sql_dump.sql} +5 -5
- package/db/migrations/postgresql/.config.json +3 -0
- package/db/migrations/postgresql/20210531070318-ndic-init.js +53 -0
- package/db/migrations/postgresql/20210611010101-ndic-restrictions.js +53 -0
- package/db/migrations/postgresql/20210702010000-ndic-add-geoms.js +53 -0
- package/db/migrations/postgresql/20210927000001-ndic-constriction-fix.js +51 -0
- package/db/migrations/postgresql/package.json +3 -0
- package/db/migrations/postgresql/sqls/20210531070318-ndic-init-down.sql +6 -0
- package/db/migrations/postgresql/sqls/20210531070318-ndic-init-up.sql +164 -0
- package/db/migrations/postgresql/sqls/20210611010101-ndic-restrictions-down.sql +6 -0
- package/db/migrations/postgresql/sqls/20210611010101-ndic-restrictions-up.sql +131 -0
- package/db/migrations/postgresql/sqls/20210702010000-ndic-add-geoms-down.sql +21 -0
- package/db/migrations/postgresql/sqls/20210702010000-ndic-add-geoms-up.sql +21 -0
- package/db/migrations/postgresql/sqls/20210927000001-ndic-constriction-fix-down.sql +5 -0
- package/db/migrations/postgresql/sqls/20210927000001-ndic-constriction-fix-up.sql +5 -0
- package/db/migrations/postgresql/sqls/package.json +3 -0
- package/dist/integration-engine/NdicWorker.js +2 -0
- package/dist/integration-engine/NdicWorker.js.map +1 -1
- package/dist/output-gateway/models/RsdTmcOsmMappingModel.js +4 -3
- package/dist/output-gateway/models/RsdTmcOsmMappingModel.js.map +1 -1
- package/dist/output-gateway/models/TrafficRestrictionsModel.d.ts +1 -1
- package/dist/output-gateway/models/TrafficRestrictionsModel.js +11 -9
- package/dist/output-gateway/models/TrafficRestrictionsModel.js.map +1 -1
- package/dist/output-gateway/transformations/OutputTrafficRestrictionsTransformation.js +1 -1
- package/dist/output-gateway/transformations/OutputTrafficRestrictionsTransformation.js.map +1 -1
- package/dist/schema-definitions/index.js +1 -0
- package/dist/schema-definitions/index.js.map +1 -1
- package/docs/implementation_documentation.md +157 -0
- package/docs/ndic_erdiagram.png +0 -0
- package/package.json +83 -78
|
@@ -0,0 +1 @@
|
|
|
1
|
+
truncate "ndic_traffic_restrictions";
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
drop table if exists public.rsd_tmc_osm_mapping;
|
|
2
|
+
CREATE TABLE public.rsd_tmc_osm_mapping (
|
|
3
|
+
lt_start int8 NULL,
|
|
4
|
+
lt_end int8 NULL,
|
|
5
|
+
osm_path text NULL
|
|
6
|
+
);
|
|
7
|
+
CREATE INDEX rsd_tmc_osm_mapping_idx ON public.rsd_tmc_osm_mapping USING btree (lt_start, lt_end);
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
-- Drop table
|
|
11
|
+
|
|
12
|
+
DROP TABLE if exists public.rsd_tmc_points;
|
|
13
|
+
|
|
14
|
+
CREATE TABLE public.rsd_tmc_points (
|
|
15
|
+
cid int4 NULL,
|
|
16
|
+
"table" int4 NULL,
|
|
17
|
+
lcd int4 NOT NULL,
|
|
18
|
+
"class" varchar(1024) NULL,
|
|
19
|
+
tcd int4 NULL,
|
|
20
|
+
stcd int4 NULL,
|
|
21
|
+
jnumber varchar(50) NULL,
|
|
22
|
+
roadnumber varchar(1024) NULL,
|
|
23
|
+
roadname varchar(1024) NULL,
|
|
24
|
+
firstname varchar(1024) NULL,
|
|
25
|
+
secondname varchar(1024) NULL,
|
|
26
|
+
area_ref int4 NULL,
|
|
27
|
+
area_name varchar(1024) NULL,
|
|
28
|
+
roa_lcd int4 NULL,
|
|
29
|
+
seg_lcd int4 NULL,
|
|
30
|
+
roa_type varchar(1024) NULL,
|
|
31
|
+
inpos int4 NULL,
|
|
32
|
+
outpos int4 NULL,
|
|
33
|
+
inneg int4 NULL,
|
|
34
|
+
outneg int4 NULL,
|
|
35
|
+
presentpos int4 NULL,
|
|
36
|
+
presentneg int4 NULL,
|
|
37
|
+
interrupt int4 NULL,
|
|
38
|
+
urban int4 NULL,
|
|
39
|
+
int_lcd varchar(1024) NULL,
|
|
40
|
+
neg_off int4 NULL,
|
|
41
|
+
pos_off int4 NULL,
|
|
42
|
+
wgs84_x numeric NULL,
|
|
43
|
+
wgs84_y numeric NULL,
|
|
44
|
+
sjtsk_x numeric NULL,
|
|
45
|
+
sjtsk_y numeric NULL,
|
|
46
|
+
isolated int4 NULL,
|
|
47
|
+
version_id varchar(50) NOT NULL,
|
|
48
|
+
wgs84_point geography(point, 4326) NULL,
|
|
49
|
+
CONSTRAINT rsd_tmc_points_pkey PRIMARY KEY (lcd, version_id)
|
|
50
|
+
);
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
-- EXAMPLE DATA - for testing purposes
|
|
2
2
|
|
|
3
|
-
INSERT INTO
|
|
3
|
+
INSERT INTO ndic_traffic_restrictions
|
|
4
4
|
(exchange, publication_time, publication_creator, situation_id, situation_version, situation_version_time, situation_confidentiality, situation_information_status, situation_urgency, situation_record_version, situation_record_type, situation_record_id, situation_record_creation_time, situation_record_version_time, probability_of_occurrence, "source", validity_status, validity_overall_start_time, validity_overall_end_time, impact_capacity_remaining, impact_number_of_lanes_restricted, impact_number_of_operational_lanes, impact_original_number_of_lanes, impact_traffic_constriction_type, impact_delays_type, impact_delay_time_value, cause, general_public_comment, group_of_locations_type, supplementary_positional_description, destination, alert_c_linear, linear_within_linear_element, global_network_linear, linear_extension, geom_gn_line, geom_openlr_line, situation_record_extension, number_of_obstructions, mobility_of_obstruction, compliance_option, applicable_for_traffic_direction, applicable_for_traffic_type, places_at_which_applicable, for_vehicles_with_characteristics_of, roadworks_duration, roadworks_scale, under_traffic, urgent_roadworks, mobility, subjects, maintenance_vehicles, abnormal_traffic_type, accident_type, group_of_vehicles_involved, car_park_identity, car_park_occupancy, number_of_vacant_parking_spaces, driving_condition_type, construction_work_type, disturbance_activity_type, environmental_obstruction_type, general_instruction_to_road_users_type, general_message_to_road_users, general_network_management_type, traffic_manually_directed_by, infrastructure_damage_type, road_maintenance_type, non_weather_related_road_condition_type, poor_environment_type, public_event_type, rerouting_management_type, rerouting_itinerary_description, signed_rerouting, entry, "exit", road_or_junction_number, road_or_carriageway_or_lane_management_type, minimum_car_occupancy, roadside_assistance_type, speed_management_type, temporary_speed_limit, vehicle_obstruction_type, obstructing_vehicle, winter_equipment_management_type, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, geom_alert_c_line, alert_c_direction)
|
|
5
5
|
VALUES('{"supplierIdentification":{"country":"cz","nationalIdentifier":"DIC"}}'::json, '2021-06-21 09:28:36.000', '{"country":"cz","nationalIdentifier":"NDIC"}'::json, 'dc4e500c-6853-4232-a439-26889485f0bf', '10', '2021-06-21 09:26:35.000', 'noRestriction', 'real', 'urgent', '10', 'RoadOrCarriagewayOrLaneManagement', 'dc4e500c-6853-4232-a439-26889485f0bf_RoadOrCarriagewayOrLaneManagement', '2021-06-21 09:27:36.000', '2021-06-21 09:26:35.000', 'certain', '{"sourceIdentification":"SSU","sourceName":{"values":{"value":{"$":{"lang":"cs"}}}}}', 'definedByValidityTimeSpec', '2021-06-21 07:45:00.000', '2024-06-21 09:35:00.000', NULL, 1, NULL, NULL, NULL, NULL, NULL, NULL, '{"comment":{"values":{"value":{"_":"D11 ve směru Hradec Králové, mezi 57.8 a 59.5 km, v termínu od 21. 06. 2021 07:45 do 21. 06. 2021 09:35, sekání trávy a údržba travních porostů, rozsah: zpevněná krajnice (1), počet průjezdných pruhů: 2","$":{"lang":"cs"}}}}}', 'Linear', '{"affectedCarriagewayAndLanes":{"carriageway":"mainCarriageway","lane":["hardShoulder","hardShoulder"]}}'::json, NULL, '{"$":{"xsi:type":"AlertCMethod2Linear"},"alertCLocationCountryCode":"CZ","alertCLocationTableNumber":"25","alertCLocationTableVersion":"8.0","alertCDirection":{"alertCDirectionCoded":"positive"},"alertCMethod2PrimaryPointLocation":{"alertCLocation":{"specificLocation":"25631"}},"alertCMethod2SecondaryPointLocation":{"alertCLocation":{"specificLocation":"25632"}}}'::json, '{"directionRelativeOnLinearSection":"aligned","linearElement":{"roadNumber":"D11"},"fromPoint":{"$":{"xsi:type":"DistanceFromLinearElementStart"},"distanceAlong":"57800"},"toPoint":{"$":{"xsi:type":"DistanceFromLinearElementStart"},"distanceAlong":"59500"}}'::json, '{"networkVersion":{"values":{"value":{"_":"20.12","$":{"lang":"cs"}}}},"linearGeometryType":"continuous","startPoint":{"sjtskPointCoordinates":{"sjtskX":"-673953","sjtskY":"-1047752"}},"endPoint":{"sjtskPointCoordinates":{"sjtskX":"-672281","sjtskY":"-1047729"}},"linearWithinLinearGNElement":[{"sectionId":"3667990","directionRelativeOnLinearSection":"aligned","orderOfSection":"0","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0.609467455621352"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3718219","directionRelativeOnLinearSection":"aligned","orderOfSection":"1","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3718220","directionRelativeOnLinearSection":"aligned","orderOfSection":"2","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3668339","directionRelativeOnLinearSection":"aligned","orderOfSection":"3","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3718215","directionRelativeOnLinearSection":"aligned","orderOfSection":"4","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3718216","directionRelativeOnLinearSection":"aligned","orderOfSection":"5","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3668310","directionRelativeOnLinearSection":"aligned","orderOfSection":"6","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3709873","directionRelativeOnLinearSection":"aligned","orderOfSection":"7","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3709872","directionRelativeOnLinearSection":"aligned","orderOfSection":"8","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"770633","directionRelativeOnLinearSection":"aligned","orderOfSection":"9","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0.333333333333481"}}]}'::json, '{"openlrExtendedLinear":{"firstDirection":{"openlrLocationReferencePoint":{"openlrCoordinate":{"latitude":"50.121507278665177","longitude":"15.286050548849159"},"openlrLineAttributes":{"openlrFunctionalRoadClass":"FRC0","openlrFormOfWay":"motorway","openlrBearing":"96"},"openlrPathAttributes":{"openlrLowestFRCToNextLRPoint":"FRC0","openlrDistanceToNextLRPoint":"11146"}},"openlrLastLocationReferencePoint":{"openlrCoordinate":{"latitude":"50.130281776902336","longitude":"15.436223886461383"},"openlrLineAttributes":{"openlrFunctionalRoadClass":"FRC0","openlrFormOfWay":"motorway","openlrBearing":"282"}},"openlrOffsets":{"openlrPositiveOffset":"7337","openlrNegativeOffset":"2109"}}}}'::json, NULL, NULL, NULL, NULL, NULL, 'mandatory', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'laneClosures', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '2021-06-21 09:28:36.181', NULL, NULL, '2021-06-21 09:28:36.181', NULL, NULL, NULL);
|
|
6
|
-
INSERT INTO
|
|
6
|
+
INSERT INTO ndic_traffic_restrictions
|
|
7
7
|
(exchange, publication_time, publication_creator, situation_id, situation_version, situation_version_time, situation_confidentiality, situation_information_status, situation_urgency, situation_record_version, situation_record_type, situation_record_id, situation_record_creation_time, situation_record_version_time, probability_of_occurrence, "source", validity_status, validity_overall_start_time, validity_overall_end_time, impact_capacity_remaining, impact_number_of_lanes_restricted, impact_number_of_operational_lanes, impact_original_number_of_lanes, impact_traffic_constriction_type, impact_delays_type, impact_delay_time_value, cause, general_public_comment, group_of_locations_type, supplementary_positional_description, destination, alert_c_linear, linear_within_linear_element, global_network_linear, linear_extension, geom_gn_line, geom_openlr_line, situation_record_extension, number_of_obstructions, mobility_of_obstruction, compliance_option, applicable_for_traffic_direction, applicable_for_traffic_type, places_at_which_applicable, for_vehicles_with_characteristics_of, roadworks_duration, roadworks_scale, under_traffic, urgent_roadworks, mobility, subjects, maintenance_vehicles, abnormal_traffic_type, accident_type, group_of_vehicles_involved, car_park_identity, car_park_occupancy, number_of_vacant_parking_spaces, driving_condition_type, construction_work_type, disturbance_activity_type, environmental_obstruction_type, general_instruction_to_road_users_type, general_message_to_road_users, general_network_management_type, traffic_manually_directed_by, infrastructure_damage_type, road_maintenance_type, non_weather_related_road_condition_type, poor_environment_type, public_event_type, rerouting_management_type, rerouting_itinerary_description, signed_rerouting, entry, "exit", road_or_junction_number, road_or_carriageway_or_lane_management_type, minimum_car_occupancy, roadside_assistance_type, speed_management_type, temporary_speed_limit, vehicle_obstruction_type, obstructing_vehicle, winter_equipment_management_type, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, geom_alert_c_line, alert_c_direction)
|
|
8
8
|
VALUES('{"supplierIdentification":{"country":"cz","nationalIdentifier":"DIC"}}'::json, '2021-06-21 09:53:37.000', '{"country":"cz","nationalIdentifier":"NDIC"}'::json, 'd5321261-0cf1-47ae-a1d6-39cb8aab3874', '6', '2021-06-21 09:52:49.000', 'noRestriction', 'real', 'urgent', '6', 'RoadOrCarriagewayOrLaneManagement', 'd5321261-0cf1-47ae-a1d6-39cb8aab3874_RoadOrCarriagewayOrLaneManagement', '2021-06-21 09:53:27.000', '2021-06-21 09:52:49.000', 'certain', '{"sourceIdentification":"SSU","sourceName":{"values":{"value":{"$":{"lang":"cs"}}}}}', 'definedByValidityTimeSpec', '2021-06-21 07:15:00.000', '2024-06-21 10:00:00.000', NULL, NULL, 2, 2, NULL, NULL, NULL, NULL, '{"comment":{"values":{"value":{"_":"D1 ve směru Praha, mezi 52 a 49 km, v termínu od 21. 06. 2021 07:15 do 21. 06. 2021 10:00, sekání trávy a údržba travních porostů, rozsah: zpevněná krajnice (1),přídatný pruh (2) - pro pomalá vozidla, připojovací, odbočovací, počet průjezdných pruhů: 2","$":{"lang":"cs"}}}}}', 'Linear', NULL, NULL, '{"$":{"xsi:type":"AlertCMethod2Linear"},"alertCLocationCountryCode":"CZ","alertCLocationTableNumber":"25","alertCLocationTableVersion":"8.0","alertCDirection":{"alertCDirectionCoded":"negative"},"alertCMethod2PrimaryPointLocation":{"alertCLocation":{"specificLocation":"1279"}},"alertCMethod2SecondaryPointLocation":{"alertCLocation":{"specificLocation":"25540"}}}'::json, '{"directionRelativeOnLinearSection":"opposite","linearElement":{"roadNumber":"D1"},"fromPoint":{"$":{"xsi:type":"DistanceFromLinearElementStart"},"distanceAlong":"52000"},"toPoint":{"$":{"xsi:type":"DistanceFromLinearElementStart"},"distanceAlong":"48999"}}'::json, '{"networkVersion":{"values":{"value":{"_":"20.12","$":{"lang":"cs"}}}},"linearGeometryType":"continuous","startPoint":{"sjtskPointCoordinates":{"sjtskX":"-705368","sjtskY":"-1085484"}},"endPoint":{"sjtskPointCoordinates":{"sjtskX":"-708220","sjtskY":"-1085241"}},"linearWithinLinearGNElement":[{"sectionId":"716168","directionRelativeOnLinearSection":"aligned","orderOfSection":"0","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0.25"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3731284","directionRelativeOnLinearSection":"aligned","orderOfSection":"1","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3731283","directionRelativeOnLinearSection":"aligned","orderOfSection":"2","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3776298","directionRelativeOnLinearSection":"aligned","orderOfSection":"3","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3737940","directionRelativeOnLinearSection":"aligned","orderOfSection":"4","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3709908","directionRelativeOnLinearSection":"aligned","orderOfSection":"5","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3709909","directionRelativeOnLinearSection":"aligned","orderOfSection":"6","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3663080","directionRelativeOnLinearSection":"aligned","orderOfSection":"7","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"1358023","directionRelativeOnLinearSection":"aligned","orderOfSection":"8","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3663072","directionRelativeOnLinearSection":"aligned","orderOfSection":"9","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3721196","directionRelativeOnLinearSection":"aligned","orderOfSection":"10","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3721193","directionRelativeOnLinearSection":"aligned","orderOfSection":"11","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3513651","directionRelativeOnLinearSection":"aligned","orderOfSection":"12","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0.801408450704281"}}]}'::json, '{"openlrExtendedLinear":{"firstDirection":{"openlrLocationReferencePoint":{"openlrCoordinate":{"latitude":"49.751823499059107","longitude":"15.024250722599788"},"openlrLineAttributes":{"openlrFunctionalRoadClass":"FRC0","openlrFormOfWay":"motorway","openlrBearing":"304"},"openlrPathAttributes":{"openlrLowestFRCToNextLRPoint":"FRC0","openlrDistanceToNextLRPoint":"3918"}},"openlrLastLocationReferencePoint":{"openlrCoordinate":{"latitude":"49.754080738289225","longitude":"14.973070308369639"},"openlrLineAttributes":{"openlrFunctionalRoadClass":"FRC0","openlrFormOfWay":"motorway","openlrBearing":"128"}},"openlrOffsets":{"openlrPositiveOffset":"606","openlrNegativeOffset":"321"}}}}'::json, NULL, NULL, NULL, NULL, NULL, 'mandatory', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'laneClosures', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '2021-06-21 09:53:37.380', NULL, NULL, '2021-06-21 09:53:37.380', NULL, NULL, NULL);
|
|
9
|
-
INSERT INTO
|
|
9
|
+
INSERT INTO ndic_traffic_restrictions
|
|
10
10
|
(exchange, publication_time, publication_creator, situation_id, situation_version, situation_version_time, situation_confidentiality, situation_information_status, situation_urgency, situation_record_version, situation_record_type, situation_record_id, situation_record_creation_time, situation_record_version_time, probability_of_occurrence, "source", validity_status, validity_overall_start_time, validity_overall_end_time, impact_capacity_remaining, impact_number_of_lanes_restricted, impact_number_of_operational_lanes, impact_original_number_of_lanes, impact_traffic_constriction_type, impact_delays_type, impact_delay_time_value, cause, general_public_comment, group_of_locations_type, supplementary_positional_description, destination, alert_c_linear, linear_within_linear_element, global_network_linear, linear_extension, geom_gn_line, geom_openlr_line, situation_record_extension, number_of_obstructions, mobility_of_obstruction, compliance_option, applicable_for_traffic_direction, applicable_for_traffic_type, places_at_which_applicable, for_vehicles_with_characteristics_of, roadworks_duration, roadworks_scale, under_traffic, urgent_roadworks, mobility, subjects, maintenance_vehicles, abnormal_traffic_type, accident_type, group_of_vehicles_involved, car_park_identity, car_park_occupancy, number_of_vacant_parking_spaces, driving_condition_type, construction_work_type, disturbance_activity_type, environmental_obstruction_type, general_instruction_to_road_users_type, general_message_to_road_users, general_network_management_type, traffic_manually_directed_by, infrastructure_damage_type, road_maintenance_type, non_weather_related_road_condition_type, poor_environment_type, public_event_type, rerouting_management_type, rerouting_itinerary_description, signed_rerouting, entry, "exit", road_or_junction_number, road_or_carriageway_or_lane_management_type, minimum_car_occupancy, roadside_assistance_type, speed_management_type, temporary_speed_limit, vehicle_obstruction_type, obstructing_vehicle, winter_equipment_management_type, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, geom_alert_c_line, alert_c_direction)
|
|
11
11
|
VALUES('{"supplierIdentification":{"country":"cz","nationalIdentifier":"DIC"}}'::json, '2021-06-21 09:53:37.000', '{"country":"cz","nationalIdentifier":"NDIC"}'::json, 'd5321261-0cf1-47ae-a1d6-39cb8aab3874', '6', '2021-06-21 09:52:49.000', 'noRestriction', 'real', 'urgent', '6', 'MaintenanceWorks', 'd5321261-0cf1-47ae-a1d6-39cb8aab3874_MaintenanceWorks', '2021-06-21 09:53:27.000', '2021-06-21 09:52:49.000', 'certain', '{"sourceIdentification":"RSD","sourceName":{"values":{"value":{"$":{"lang":"cs"}}}}}', 'definedByValidityTimeSpec', '2021-06-21 07:15:00.000', '2021-06-24 09:53:27.000', NULL, 1, 2, 2, NULL, NULL, NULL, NULL, '{"comment":{"values":{"value":{"_":"D1, mezi km 52 a 49, ve směru Praha, práce na silnici, zpevněná krajnice uzavřena, Od 21.06.2021 07:15 Do 21.06.2021 17:00, Sečení trávy strojně., sekání trávy a údržba travních porostů, pracovní místo DM - Krátkodobé pohyblivé (mobilní), zdroj: ŘSD","$":{"lang":"cs"}}}}}', 'Linear', '{"affectedCarriagewayAndLanes":{"carriageway":"mainCarriageway","lane":["hardShoulder","hardShoulder"]}}'::json, NULL, '{"$":{"xsi:type":"AlertCMethod2Linear"},"alertCLocationCountryCode":"CZ","alertCLocationTableNumber":"25","alertCLocationTableVersion":"8.0","alertCDirection":{"alertCDirectionCoded":"negative"},"alertCMethod2PrimaryPointLocation":{"alertCLocation":{"specificLocation":"1279"}},"alertCMethod2SecondaryPointLocation":{"alertCLocation":{"specificLocation":"25540"}}}'::json, '{"directionRelativeOnLinearSection":"opposite","linearElement":{"roadNumber":"D1"},"fromPoint":{"$":{"xsi:type":"DistanceFromLinearElementStart"},"distanceAlong":"52000"},"toPoint":{"$":{"xsi:type":"DistanceFromLinearElementStart"},"distanceAlong":"48999"}}'::json, '{"networkVersion":{"values":{"value":{"_":"20.12","$":{"lang":"cs"}}}},"linearGeometryType":"continuous","startPoint":{"sjtskPointCoordinates":{"sjtskX":"-705367.665475001","sjtskY":"-1085484.320675"}},"endPoint":{"sjtskPointCoordinates":{"sjtskX":"-708220.292120583","sjtskY":"-1085240.94330743"}},"linearWithinLinearGNElement":[{"sectionId":"716168","directionRelativeOnLinearSection":"aligned","orderOfSection":"0","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0.25"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3731284","directionRelativeOnLinearSection":"aligned","orderOfSection":"1","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3731283","directionRelativeOnLinearSection":"aligned","orderOfSection":"2","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3776298","directionRelativeOnLinearSection":"aligned","orderOfSection":"3","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3737940","directionRelativeOnLinearSection":"aligned","orderOfSection":"4","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3709908","directionRelativeOnLinearSection":"aligned","orderOfSection":"5","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3709909","directionRelativeOnLinearSection":"aligned","orderOfSection":"6","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3663080","directionRelativeOnLinearSection":"aligned","orderOfSection":"7","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"1358023","directionRelativeOnLinearSection":"aligned","orderOfSection":"8","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3663072","directionRelativeOnLinearSection":"aligned","orderOfSection":"9","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3721196","directionRelativeOnLinearSection":"aligned","orderOfSection":"10","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3721193","directionRelativeOnLinearSection":"aligned","orderOfSection":"11","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"1"}},{"sectionId":"3513651","directionRelativeOnLinearSection":"aligned","orderOfSection":"12","fromPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0"},"toPoint":{"$":{"xsi:type":"PercentageDistanceAlongLinearElement"},"percentageDistanceAlong":"0.801408450704281"}}]}'::json, '{"openlrExtendedLinear":{"firstDirection":{"openlrLocationReferencePoint":{"openlrCoordinate":{"latitude":"49.751823499059107","longitude":"15.024250722599788"},"openlrLineAttributes":{"openlrFunctionalRoadClass":"FRC0","openlrFormOfWay":"motorway","openlrBearing":"304"},"openlrPathAttributes":{"openlrLowestFRCToNextLRPoint":"FRC0","openlrDistanceToNextLRPoint":"3918"}},"openlrLastLocationReferencePoint":{"openlrCoordinate":{"latitude":"49.754080738289225","longitude":"14.973070308369639"},"openlrLineAttributes":{"openlrFunctionalRoadClass":"FRC0","openlrFormOfWay":"motorway","openlrBearing":"128"}},"openlrOffsets":{"openlrPositiveOffset":"606","openlrNegativeOffset":"321"}}}}'::json, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'roadworks', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '2021-06-21 09:53:37.380', NULL, NULL, '2021-06-21 09:53:37.380', NULL, NULL, NULL);
|
|
12
12
|
|
|
13
13
|
-- TO DO Add data for rsd_tmc_osm_mapping
|
|
14
14
|
INSERT INTO public.rsd_tmc_osm_mapping
|
|
15
15
|
(lt_start, lt_end, osm_path)
|
|
16
|
-
VALUES(
|
|
16
|
+
VALUES(1279, 25540, '[74256918, 191823166, 191823171, 74269338, 262869174, 189021819, 189021825, 74177021, 189021808, 191834725, 189021814, 189021813, 191834765, 191823161, 5506226185, 191823018, 74084348, 74282499, 1600950538, 156250951, 1600950600, 156250948, 1600950646, 74177697, 74238396, 74244807, 156250944, 156250941, 976485311, 74153579, 156250937, 156250932, 74168337, 74279965, 151003135]');
|
|
17
17
|
INSERT INTO public.rsd_tmc_osm_mapping
|
|
18
18
|
(lt_start, lt_end, osm_path)
|
|
19
|
-
VALUES(
|
|
19
|
+
VALUES(25631, 25632, '[156250932, 156250937, 74153579, 976485311]');
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var dbm;
|
|
4
|
+
var type;
|
|
5
|
+
var seed;
|
|
6
|
+
var fs = require('fs');
|
|
7
|
+
var path = require('path');
|
|
8
|
+
var Promise;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* We receive the dbmigrate dependency from dbmigrate initially.
|
|
12
|
+
* This enables us to not have to rely on NODE_PATH.
|
|
13
|
+
*/
|
|
14
|
+
exports.setup = function(options, seedLink) {
|
|
15
|
+
dbm = options.dbmigrate;
|
|
16
|
+
type = dbm.dataType;
|
|
17
|
+
seed = seedLink;
|
|
18
|
+
Promise = options.Promise;
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
exports.up = function(db) {
|
|
22
|
+
var filePath = path.join(__dirname, 'sqls', '20210531070318-ndic-init-up.sql');
|
|
23
|
+
return new Promise( function( resolve, reject ) {
|
|
24
|
+
fs.readFile(filePath, {encoding: 'utf-8'}, function(err,data){
|
|
25
|
+
if (err) return reject(err);
|
|
26
|
+
console.log('received data: ' + data);
|
|
27
|
+
|
|
28
|
+
resolve(data);
|
|
29
|
+
});
|
|
30
|
+
})
|
|
31
|
+
.then(function(data) {
|
|
32
|
+
return db.runSql(data);
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
exports.down = function(db) {
|
|
37
|
+
var filePath = path.join(__dirname, 'sqls', '20210531070318-ndic-init-down.sql');
|
|
38
|
+
return new Promise( function( resolve, reject ) {
|
|
39
|
+
fs.readFile(filePath, {encoding: 'utf-8'}, function(err,data){
|
|
40
|
+
if (err) return reject(err);
|
|
41
|
+
console.log('received data: ' + data);
|
|
42
|
+
|
|
43
|
+
resolve(data);
|
|
44
|
+
});
|
|
45
|
+
})
|
|
46
|
+
.then(function(data) {
|
|
47
|
+
return db.runSql(data);
|
|
48
|
+
});
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
exports._meta = {
|
|
52
|
+
"version": 1
|
|
53
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var dbm;
|
|
4
|
+
var type;
|
|
5
|
+
var seed;
|
|
6
|
+
var fs = require('fs');
|
|
7
|
+
var path = require('path');
|
|
8
|
+
var Promise;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* We receive the dbmigrate dependency from dbmigrate initially.
|
|
12
|
+
* This enables us to not have to rely on NODE_PATH.
|
|
13
|
+
*/
|
|
14
|
+
exports.setup = function(options, seedLink) {
|
|
15
|
+
dbm = options.dbmigrate;
|
|
16
|
+
type = dbm.dataType;
|
|
17
|
+
seed = seedLink;
|
|
18
|
+
Promise = options.Promise;
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
exports.up = function(db) {
|
|
22
|
+
var filePath = path.join(__dirname, 'sqls', '20210611010101-ndic-restrictions-up.sql');
|
|
23
|
+
return new Promise( function( resolve, reject ) {
|
|
24
|
+
fs.readFile(filePath, {encoding: 'utf-8'}, function(err,data){
|
|
25
|
+
if (err) return reject(err);
|
|
26
|
+
console.log('received data: ' + data);
|
|
27
|
+
|
|
28
|
+
resolve(data);
|
|
29
|
+
});
|
|
30
|
+
})
|
|
31
|
+
.then(function(data) {
|
|
32
|
+
return db.runSql(data);
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
exports.down = function(db) {
|
|
37
|
+
var filePath = path.join(__dirname, 'sqls', '20210611010101-ndic-restrictions-down.sql');
|
|
38
|
+
return new Promise( function( resolve, reject ) {
|
|
39
|
+
fs.readFile(filePath, {encoding: 'utf-8'}, function(err,data){
|
|
40
|
+
if (err) return reject(err);
|
|
41
|
+
console.log('received data: ' + data);
|
|
42
|
+
|
|
43
|
+
resolve(data);
|
|
44
|
+
});
|
|
45
|
+
})
|
|
46
|
+
.then(function(data) {
|
|
47
|
+
return db.runSql(data);
|
|
48
|
+
});
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
exports._meta = {
|
|
52
|
+
"version": 1
|
|
53
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var dbm;
|
|
4
|
+
var type;
|
|
5
|
+
var seed;
|
|
6
|
+
var fs = require('fs');
|
|
7
|
+
var path = require('path');
|
|
8
|
+
var Promise;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* We receive the dbmigrate dependency from dbmigrate initially.
|
|
12
|
+
* This enables us to not have to rely on NODE_PATH.
|
|
13
|
+
*/
|
|
14
|
+
exports.setup = function(options, seedLink) {
|
|
15
|
+
dbm = options.dbmigrate;
|
|
16
|
+
type = dbm.dataType;
|
|
17
|
+
seed = seedLink;
|
|
18
|
+
Promise = options.Promise;
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
exports.up = function(db) {
|
|
22
|
+
var filePath = path.join(__dirname, 'sqls', '20210702010000-ndic-add-geoms-up.sql');
|
|
23
|
+
return new Promise( function( resolve, reject ) {
|
|
24
|
+
fs.readFile(filePath, {encoding: 'utf-8'}, function(err,data){
|
|
25
|
+
if (err) return reject(err);
|
|
26
|
+
console.log('received data: ' + data);
|
|
27
|
+
|
|
28
|
+
resolve(data);
|
|
29
|
+
});
|
|
30
|
+
})
|
|
31
|
+
.then(function(data) {
|
|
32
|
+
return db.runSql(data);
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
exports.down = function(db) {
|
|
37
|
+
var filePath = path.join(__dirname, 'sqls', '20210702010000-ndic-add-geoms-down.sql');
|
|
38
|
+
return new Promise( function( resolve, reject ) {
|
|
39
|
+
fs.readFile(filePath, {encoding: 'utf-8'}, function(err,data){
|
|
40
|
+
if (err) return reject(err);
|
|
41
|
+
console.log('received data: ' + data);
|
|
42
|
+
|
|
43
|
+
resolve(data);
|
|
44
|
+
});
|
|
45
|
+
})
|
|
46
|
+
.then(function(data) {
|
|
47
|
+
return db.runSql(data);
|
|
48
|
+
});
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
exports._meta = {
|
|
52
|
+
"version": 1
|
|
53
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var dbm;
|
|
4
|
+
var type;
|
|
5
|
+
var seed;
|
|
6
|
+
var fs = require("fs");
|
|
7
|
+
var path = require("path");
|
|
8
|
+
var Promise;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* We receive the dbmigrate dependency from dbmigrate initially.
|
|
12
|
+
* This enables us to not have to rely on NODE_PATH.
|
|
13
|
+
*/
|
|
14
|
+
exports.setup = function (options, seedLink) {
|
|
15
|
+
dbm = options.dbmigrate;
|
|
16
|
+
type = dbm.dataType;
|
|
17
|
+
seed = seedLink;
|
|
18
|
+
Promise = options.Promise;
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
exports.up = function (db) {
|
|
22
|
+
var filePath = path.join(__dirname, "sqls", "20210927000001-ndic-constriction-fix-up.sql");
|
|
23
|
+
return new Promise(function (resolve, reject) {
|
|
24
|
+
fs.readFile(filePath, { encoding: "utf-8" }, function (err, data) {
|
|
25
|
+
if (err) return reject(err);
|
|
26
|
+
console.log("received data: " + data);
|
|
27
|
+
|
|
28
|
+
resolve(data);
|
|
29
|
+
});
|
|
30
|
+
}).then(function (data) {
|
|
31
|
+
return db.runSql(data);
|
|
32
|
+
});
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
exports.down = function (db) {
|
|
36
|
+
var filePath = path.join(__dirname, "sqls", "20210927000001-ndic-constriction-fix-down.sql");
|
|
37
|
+
return new Promise(function (resolve, reject) {
|
|
38
|
+
fs.readFile(filePath, { encoding: "utf-8" }, function (err, data) {
|
|
39
|
+
if (err) return reject(err);
|
|
40
|
+
console.log("received data: " + data);
|
|
41
|
+
|
|
42
|
+
resolve(data);
|
|
43
|
+
});
|
|
44
|
+
}).then(function (data) {
|
|
45
|
+
return db.runSql(data);
|
|
46
|
+
});
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
exports._meta = {
|
|
50
|
+
version: 1,
|
|
51
|
+
};
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
CREATE TABLE ndic_traffic_info (
|
|
2
|
+
exchange json,
|
|
3
|
+
publication_time timestamp with time zone,
|
|
4
|
+
publication_creator json,
|
|
5
|
+
situation_id varchar(100) NOT NULL,
|
|
6
|
+
situation_version varchar(100) NOT NULL,
|
|
7
|
+
situation_version_time timestamp with time zone,
|
|
8
|
+
-- Header --
|
|
9
|
+
situation_confidentiality varchar(100),
|
|
10
|
+
situation_information_status varchar(100),
|
|
11
|
+
situation_urgency varchar(100),
|
|
12
|
+
--- Situation record ---
|
|
13
|
+
-- identification
|
|
14
|
+
situation_record_version varchar(100) NOT NULL,
|
|
15
|
+
situation_record_type varchar(100) NOT NULL,
|
|
16
|
+
-- content
|
|
17
|
+
situation_record_creation_time timestamp with time zone NOT NULL,
|
|
18
|
+
situation_record_version_time timestamp with time zone NOT NULL,
|
|
19
|
+
probability_of_occurrence varchar(100),
|
|
20
|
+
source json,
|
|
21
|
+
-- validity JSON --
|
|
22
|
+
validity_status varchar(100),
|
|
23
|
+
validity_overall_start_time timestamp with time zone,
|
|
24
|
+
validity_overall_end_time timestamp with time zone,
|
|
25
|
+
-- impact JSON --
|
|
26
|
+
impact_capacity_remaining real,
|
|
27
|
+
impact_number_of_lanes_restricted int,
|
|
28
|
+
impact_number_of_operational_lanes int,
|
|
29
|
+
impact_original_number_of_lanes int,
|
|
30
|
+
impact_traffic_construction_type varchar(100),
|
|
31
|
+
impact_delays_type varchar(100),
|
|
32
|
+
impact_delay_time_value real,
|
|
33
|
+
cause json,
|
|
34
|
+
general_public_comment json,
|
|
35
|
+
-- group_of_locations JSON --
|
|
36
|
+
group_of_locations_type varchar(100),
|
|
37
|
+
supplementary_positional_description json,
|
|
38
|
+
destination json,
|
|
39
|
+
alert_c_linear json,
|
|
40
|
+
linear_within_linear_element json,
|
|
41
|
+
global_network_linear json,
|
|
42
|
+
linear_extension json,
|
|
43
|
+
geom_gn_line GEOMETRY,
|
|
44
|
+
geom_openlr_line GEOMETRY,
|
|
45
|
+
--- Situation record extension ---
|
|
46
|
+
situation_record_extension json,
|
|
47
|
+
--- Situation record abstract types ---
|
|
48
|
+
-- Obstruction
|
|
49
|
+
number_of_obstructions int,
|
|
50
|
+
mobility_of_obstruction json,
|
|
51
|
+
-- NetworkManagement
|
|
52
|
+
compliance_option varchar(100),
|
|
53
|
+
applicable_for_traffic_direction varchar(100),
|
|
54
|
+
applicable_for_traffic_type varchar(100),
|
|
55
|
+
places_at_which_applicable varchar(100),
|
|
56
|
+
for_vehicles_with_characteristics_of json,
|
|
57
|
+
-- RoadWorks
|
|
58
|
+
roadworks_duration varchar(100),
|
|
59
|
+
roadworks_scale varchar(100),
|
|
60
|
+
under_traffic bool,
|
|
61
|
+
urgent_roadworks bool,
|
|
62
|
+
mobility json,
|
|
63
|
+
subjects json,
|
|
64
|
+
maintenance_vehicles json,
|
|
65
|
+
--- Situation record types ---
|
|
66
|
+
-- AbnormalTraffic
|
|
67
|
+
abnormal_traffic_type varchar(100),
|
|
68
|
+
relative_traffic_flow varchar(100),
|
|
69
|
+
traffic_trend_type varchar(100),
|
|
70
|
+
-- Accident
|
|
71
|
+
accident_type varchar(100),
|
|
72
|
+
total_number_of_vehicles_involved int,
|
|
73
|
+
vehicle_involved json,
|
|
74
|
+
group_of_vehicles_involved json,
|
|
75
|
+
group_of_people_involved json,
|
|
76
|
+
-- AnimalPresenceObstruction
|
|
77
|
+
animal_presence_type varchar(100),
|
|
78
|
+
alive bool,
|
|
79
|
+
-- AuthorityOperation
|
|
80
|
+
authority_operation_type varchar(100),
|
|
81
|
+
-- CarParks
|
|
82
|
+
car_park_configuration varchar(100),
|
|
83
|
+
car_park_identity text,
|
|
84
|
+
car_park_occupancy varchar(100),
|
|
85
|
+
car_park_status varchar(100),
|
|
86
|
+
number_of_vacant_parking_spaces int,
|
|
87
|
+
occupied_spaces int,
|
|
88
|
+
total_capacity int,
|
|
89
|
+
-- Conditions
|
|
90
|
+
driving_condition_type varchar(100),
|
|
91
|
+
-- ConstructionWorks
|
|
92
|
+
construction_work_type varchar(100),
|
|
93
|
+
-- DisturbanceActivity
|
|
94
|
+
disturbance_activity_type varchar(100),
|
|
95
|
+
-- EnvironmentalObstruction
|
|
96
|
+
depth real,
|
|
97
|
+
environmental_obstruction_type varchar(100),
|
|
98
|
+
-- EquipmentOrSystemFault
|
|
99
|
+
equipment_or_system_fault_type varchar(100),
|
|
100
|
+
faulty_equipment_or_system_type varchar(100),
|
|
101
|
+
-- GeneralInstructionOrMessageToRoadUsers
|
|
102
|
+
general_instruction_to_road_users_type varchar(100),
|
|
103
|
+
general_message_to_road_users json,
|
|
104
|
+
-- GeneralNetworkManagement
|
|
105
|
+
general_network_management_type varchar(100),
|
|
106
|
+
traffic_manually_directed_by varchar(100),
|
|
107
|
+
-- GeneralObstruction
|
|
108
|
+
obstruction_type varchar(100),
|
|
109
|
+
--group_of_people_involved JSON, already in Accident
|
|
110
|
+
-- InfrastructureDamageObstruction
|
|
111
|
+
infrastructure_damage_type varchar(100),
|
|
112
|
+
-- MaintenanceWorks
|
|
113
|
+
road_maintenance_type varchar(100),
|
|
114
|
+
-- NonWeatherRelatedRoadConditions
|
|
115
|
+
non_weather_related_road_condition_type varchar(100),
|
|
116
|
+
-- PoorEnvironmentConditions
|
|
117
|
+
poor_environment_type varchar(100),
|
|
118
|
+
precipitation_detail json,
|
|
119
|
+
visibility json,
|
|
120
|
+
temperature json,
|
|
121
|
+
wind json,
|
|
122
|
+
-- PublicEvent
|
|
123
|
+
public_event_type varchar(100),
|
|
124
|
+
-- ReroutingManagement
|
|
125
|
+
rerouting_management_type varchar(100),
|
|
126
|
+
rerouting_itinerary_description json,
|
|
127
|
+
signed_rerouting bool,
|
|
128
|
+
entry text,
|
|
129
|
+
exit text,
|
|
130
|
+
road_or_junction_number text,
|
|
131
|
+
-- RoadOperatorServiceDisruption
|
|
132
|
+
road_operator_service_disruption_type varchar(100),
|
|
133
|
+
-- RoadOrCarriagewayOrLaneManagement
|
|
134
|
+
road_or_carriageway_or_lane_management_type varchar(100),
|
|
135
|
+
minimum_car_occupancy int,
|
|
136
|
+
-- RoadsideAssistance
|
|
137
|
+
roadside_assistance_type varchar(100),
|
|
138
|
+
-- RoadsideServiceDisruption
|
|
139
|
+
roadside_service_disruption_type varchar(100),
|
|
140
|
+
-- SpeedManagement
|
|
141
|
+
speed_management_type varchar(100),
|
|
142
|
+
temporary_speed_limit real,
|
|
143
|
+
-- TransitInformation
|
|
144
|
+
transit_service_information varchar(100),
|
|
145
|
+
transit_service_type varchar(100),
|
|
146
|
+
-- VehicleObstruction
|
|
147
|
+
vehicle_obstruction_type varchar(100),
|
|
148
|
+
obstructing_vehicle json,
|
|
149
|
+
-- WeatherRelatedRoadConditions;
|
|
150
|
+
weather_related_road_condition_type varchar(100),
|
|
151
|
+
road_surface_condition_measurements json,
|
|
152
|
+
-- WinterDrivingManagement
|
|
153
|
+
winter_equipment_management_type varchar(100),
|
|
154
|
+
|
|
155
|
+
-- Audit fields --
|
|
156
|
+
create_batch_id bigint,
|
|
157
|
+
created_at timestamp with time zone,
|
|
158
|
+
created_by varchar(150),
|
|
159
|
+
update_batch_id bigint,
|
|
160
|
+
updated_at timestamp with time zone,
|
|
161
|
+
updated_by varchar(150),
|
|
162
|
+
|
|
163
|
+
CONSTRAINT ndic_traffic_info_pk PRIMARY KEY (situation_id, situation_record_type, situation_record_version_time)
|
|
164
|
+
);
|