diff --git a/Creating_a_WZDx_Feed.md b/Creating_a_WZDx_Feed.md index 3abe19ff..01596b04 100644 --- a/Creating_a_WZDx_Feed.md +++ b/Creating_a_WZDx_Feed.md @@ -19,6 +19,7 @@ GeoJSON is the file format of choice because: WZDx defines the content and structure of several data feeds. Each feed is described by a single root object with many child objects. The output of a WZDx data feed is a GeoJSON file containing the feed object. WZDx defines the following feed objects: - [WZDxFeed Object](/spec-content/objects/WZDxFeed.md): describes high-level information about work zone events ocurring on roadways (called "road events") that impact the characteristics of the roadway and involve a change from the default state (such as a lane closure). This is the original work zone data exchange feed and the only feed that WZDx defined until [version 4.0](https://github.com/usdot-jpo-ode/wzdx/releases/tag/v4.0). +- [RoadRestrictionFeed Object](/spec-content/objects/RoadRestrictionFeed.md): describes the location and details of restrictions on roadways. - [SwzDeviceFeed Object](/spec-content/objects/SwzDeviceFeed.md): describes information (location, status, live data) about field devices deployed on the roadway in work zones. *See the [/spec-content/README.md](/spec-content/README.md) for detailed information on all objects defined by WZDx.* @@ -39,11 +40,12 @@ The following business rules help assure a standardized and interpretable use of ### JSON Schemas The WZDx Specification defines a JSON schema for each feed (WZDx v2.0 and later) within the [schemas](/schemas) directory. The repository contains schemas for the following feeds: -#### Current +#### Current Version (4.0) - [WZDx v4.0 WZDxFeed](/schemas/4.0/WZDxFeed.json) - [WZDx v4.0 SwzDeviceFeed](/schemas/4.0/SwzDeviceFeed.json) +- [WZDx v4.0 RoadRestrictionFeed](/schemas/4.0/RoadRestrictionFeed.json) -#### Previous +#### Previous Versions - [WZDx v2.0 WZDxFeed](/schemas/wzdx_v2.0_feed.json) - [WZDx v3.0 WZDxFeed](/schemas/wzdx_v3.0_feed.json) - [WZDx v3.1 WZDxFeed](/schemas/wzdx_v3.1_feed.json) diff --git a/README.md b/README.md index d6cf9ad2..6f21605c 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,8 @@ WZDx defines the structure and content of multiple distinct data feeds. Each fee ### List of Data Feeds Feed Name | Description | Producer | Consumer | Uses | Content --- | --- | --- | --- | --- | --- -`WZDxFeed` | Provides high-level information about events ocurring on roadways (called "road events"), primarily work zones, that impact the characteristics of the roadway and involve a change from the default state (such as a lane closure). The `WZDxFeed` is the original work zone data exchange feed. | Agencies responsible for managing roadways and road work, typically state and local DOTs. | Traveling public via third parties such as mapping companies and CAVs. | Route planning; increased awareness; "put work zones on the map". | Work zone and detour road events (see [RoadEventFeature](/spec-content/objects/RoadEventFeature.md)). +`WZDxFeed` | Provides high-level information about events ocurring on roadways (called "road events"), primarily work zones, that impact the characteristics of the roadway and involve a change from the default state (such as a lane closure). The `WZDxFeed` is the original work zone data exchange feed. | Agencies responsible for managing roadways and road work, typically state and local DOTs. | Traveling public via third parties such as mapping companies and CAVs. | Route planning; increased awareness; "put work zones on the map". | Work zone and detour road events (see [WorkZoneRoadEvent](/spec-content/objects/WorkZoneRoadEvent.md) and [DetourRoadEvent](/spec-content/objects/DetourRoadEvent.md)). +`RoadRestrictionFeed` | Provides information about sections of roadways that have restrictions. Restriction types described by this specification are listed in the [RestrictionType](/spec-content/enumerated-types/RestrictionType.md) enumerated type. | Transportation Authorities like Tribal, Local, State, or Federal Agencies. | Traveling public via third parties such as mapping companies and CAVs. | Increased awareness; Route planning; Driver, Passenger, and Road-User Safety; Increased Efficiency; Reduced Damage to Infrastructure. | Restriction road events (see [RestrictionRoadEvent](/spec-content/objects/RestrictionRoadEvent.md)). `SwzDeviceFeed` | Provides information (location, status, live data) about field devices deployed on the roadway in work zones. | Smart work zone equipment manufacturers or vendors. | Agencies responsible for managing roadways and permitting work, typically state and local DOTs. Third-parties such as mapping companies and CAVs may also be interested in field device information. | Simplifies design process for agencies wanting to interface with equipment manufacturers; aids in dynamically generating a `WZDxFeed` with accurate information; reduces effort for manufacturers to conform to different agencies requirements. | Field devices (see [FieldDeviceFeature](/spec-content/objects/FieldDeviceFeature.md)). ## Repostitory Organization @@ -115,11 +116,12 @@ The WZDWG welcomes feedback and comments on the WZDx 3.1 Specification. Comments ## JSON Schemas The WZDx Specification defines a JSON schema for each feed within the [schemas](/schemas) directory. Schemas can be used to validate a WZDx feed document for compliance to the specification. The repository contains schemas for the following feeds: -### Current +### Current Version (4.0) - [WZDx v4.0 WZDxFeed](/schemas/4.0/WZDxFeed.json) - [WZDx v4.0 SwzDeviceFeed](/schemas/4.0/SwzDeviceFeed.json) +- [WZDx v4.0 RoadRestrictionFeed](/schemas/4.0/RoadRestrictionFeed.json) -### Previous +### Previous Version - [WZDx v2.0 WZDxFeed](/schemas/wzdx_v2.0_feed.json) - [WZDx v3.0 WZDxFeed](/schemas/wzdx_v3.0_feed.json) - [WZDx v3.1 WZDxFeed](/schemas/wzdx_v3.1_feed.json) diff --git a/examples/README.md b/examples/README.md index 5d303a03..4c162c4b 100644 --- a/examples/README.md +++ b/examples/README.md @@ -1,5 +1,5 @@ # WZDx Example Feeds -This directory contains example GeoJSON documents from WZDx data feeds. The examples cover a range of common scenarios. There are examples for both the `WZDxFeed` and `SwzDeviceFeed`, contained within the respective subdirectories. +This directory contains example GeoJSON documents from WZDx data feeds. The examples cover a range of common scenarios. There are examples for the `WZDxFeed`, `RoadRestrictionFeed`, and `SwzDeviceFeed`, contained within the respective subdirectories. ## WZDxFeed Examples The following `WZDxFeed` examples represent a variety of common scenarios when creating road events. Most of the examples are modeled after work zone scenarios used in [previous WZDx discussion](https://github.com/usdot-jpo-ode/jpo-wzdx/discussions/131). Optional fields are not included in all examples but represented at least once across the various examples. Each scenario is provided as a single GeoJSON file which may contain multiple work zones documenting differences in representing road events at varying levels of complexity. All example scenarios are provided for the `LineString` geometry type. as well as one `MultiPoint` geometry type for scenario 1. @@ -53,4 +53,14 @@ The [local access only example](/examples/WZDxFeed/local_access_only_bidirection The following example `SwzDeviceFeed`s are provided: 1. [Arrow Board "ok" Example](/examples/SwzDeviceFeed/arrow_board_ok_example.geojson): A simple feed that includes a single arrow board with an `ok` status and several optional properties provided. -2. [Camera "error" Example](/examples/SwzDeviceFeed/camera_error_example): A simple feed that includes a single camera with an `error` status, associated `status_messages`, and a few optional properties provided. \ No newline at end of file +2. [Camera "error" Example](/examples/SwzDeviceFeed/camera_error_example): A simple feed that includes a single camera with an `error` status, no image data, associated `status_messages`, and a few optional properties provided. + +## RoadRestrictionFeed Examples +The following example `RoadrestrictionFeed`s are provided: + +### 1. Bridge Height Restriction +The [Bridge Height Restriction Example](/examples/RoadRestrictionFeed/bridge_restriction_linestring_example.geojson) shows the use of a [RestrictionRoadEvent](/spec-content/objects/RestrictionRoadEvent.md) to define a bridge clearance on a roadway. + +- Defines three bridge height restrictions. +- Two restrictions (`id`s: `Bridge2`, `Bridge3`) are defined using only the required core details and basic event-level information. +- One restriction (`id`: `Bridge1`) also includes lane-level details with additional height restrictions values for individual lanes. \ No newline at end of file diff --git a/examples/RoadRestrictionFeed/bridge_height_restriction_linestring_example.geojson b/examples/RoadRestrictionFeed/bridge_height_restriction_linestring_example.geojson new file mode 100644 index 00000000..7f786a4b --- /dev/null +++ b/examples/RoadRestrictionFeed/bridge_height_restriction_linestring_example.geojson @@ -0,0 +1,249 @@ +{ + "feed_info": { + "update_date": "2021-07-01T15:00:00Z", + "publisher": "New York State DOT", + "contact_name": "Frederick Francis Feedmanager", + "contact_email": "fred.feedmanager@testdot.gov", + "update_frequency": 300, + "version": "4.0", + "data_sources": [ + { + "data_source_id": "1", + "organization_name": "New York City DOT", + "contact_name": "Solomn Soliel Sourcefeed", + "contact_email": "solomon.sourcefeed@testcity1.gov", + "update_frequency": 60, + "update_date": "2021-07-01T00:00:00Z" + } + ] + }, + "type": "FeatureCollection", + "features": [ + { + "id": "Bridge1", + "type": "Feature", + "properties": { + "core_details": { + "event_type": "restriction", + "data_source_id": "1", + "road_names": [ + "HRP", + "Hutchinson Parkway", + "Hutchinson River Parkway" + ], + "direction": "northbound" + }, + "restrictions": [ + { + "type": "reduced-height", + "value": 10.5, + "unit": "feet" + } + ], + "lanes": [ + { + "order": 1, + "status": "open", + "type": "general", + "restrictions": [ + { + "type": "reduced-height", + "value": 10.5, + "unit": "feet" + } + ] + }, + { + "order": 2, + "status": "open", + "type": "general", + "restrictions": [ + { + "type": "reduced-height", + "value": 11, + "unit": "feet" + } + ] + }, + { + "order": 3, + "status": "open", + "type": "general", + "restrictions": [ + { + "type": "reduced-height", + "value": 10.5, + "unit": "feet" + } + ] + } + ] + }, + "geometry": { + "type": "LineString", + "coordinates": [ + [ + -73.83857488632202, + 40.83782481579416 + ], + [ + -73.8385534286499, + 40.83905758069452 + ], + [ + -73.83834958076477, + 40.84045773030475 + ], + [ + -73.83817791938782, + 40.841269397695825 + ], + [ + -73.83692264556885, + 40.84498467829638 + ], + [ + -73.83683949708939, + 40.84519569836051 + ], + [ + -73.83674025535583, + 40.84555483673242 + ], + [ + -73.83666649460793, + 40.84582976902955 + ], + [ + -73.83646667003632, + 40.84667890696712 + ] + ] + } + }, + { + "id": "Bridge2", + "type": "Feature", + "properties": { + "core_details": { + "event_type": "restriction", + "data_source_id": "1", + "road_names": [ + "HRP", + "Hutchinson Parkway", + "Hutchinson River Parkway" + ], + "direction": "southbound" + }, + "restrictions": [ + { + "type": "reduced-height", + "value": 9.0, + "unit": "feet" + } + ] + }, + "geometry": { + "type": "LineString", + "coordinates": [ + [ + -73.83725792169571, + 40.84455654898646 + ], + [ + -73.8378158211708, + 40.84294748850873 + ], + [ + -73.83808672428131, + 40.84214192905569 + ], + [ + -73.83834153413773, + 40.84133635981177 + ] + ] + } + }, + { + "id": "Bridge3", + "type": "Feature", + "properties": { + "core_details": { + "event_type": "restriction", + "data_source_id": "1", + "road_names": [ + "HRP", + "Hutchinson Parkway", + "Hutchinson River Parkway" + ], + "direction": "southbound" + }, + "restrictions": [ + { + "type": "reduced-height", + "value": 11, + "unit": "feet" + } + ] + }, + "geometry": { + "type": "LineString", + "coordinates": [ + [ + -73.83834153413773, + 40.841335852523244 + ], + [ + -73.8384260237217, + 40.84103300059402 + ], + [ + -73.83847497403622, + 40.84082856207721 + ], + [ + -73.83851654827595, + 40.84063071775089 + ], + [ + -73.83855678141117, + 40.84045722300951 + ], + [ + -73.83865937590599, + 40.83983324694044 + ], + [ + -73.83872039616108, + 40.8393289888175 + ], + [ + -73.83875325322151, + 40.838710582522424 + ], + [ + -73.83877135813236, + 40.838443230352674 + ], + [ + -73.83877202868462, + 40.83817942829337 + ], + [ + -73.83877471089363, + 40.83773502091179 + ], + [ + -73.83877538144588, + 40.83721857114785 + ], + [ + -73.83877336978912, + 40.83710442404608 + ] + ] + } + } + ] +} \ No newline at end of file diff --git a/schemas/4.0/BoundingBox.json b/schemas/4.0/BoundingBox.json index 37fc804a..ec2e0372 100644 --- a/schemas/4.0/BoundingBox.json +++ b/schemas/4.0/BoundingBox.json @@ -1,5 +1,5 @@ { - "$id": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/BoundingBox.json", + "$id": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/BoundingBox.json", "$schema": "http://json-schema.org/draft-07/schema#", "title": "GeoJSON Bounding Box", "description": "Information on the coordinate range for a Geometry, Feature, or FeatureCollection", diff --git a/schemas/4.0/FeedInfo.json b/schemas/4.0/FeedInfo.json index ca615254..f874b4ed 100644 --- a/schemas/4.0/FeedInfo.json +++ b/schemas/4.0/FeedInfo.json @@ -1,5 +1,5 @@ { - "$id": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/FeedInfo.json", + "$id": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/FeedInfo.json", "$schema": "http://json-schema.org/draft-07/schema#", "title": "WZDx Feed Information", "description": "Describes WZDx feed header information such as metadata, contact information, and data sources", diff --git a/schemas/4.0/RoadEventFeature.json b/schemas/4.0/RoadEventFeature.json new file mode 100644 index 00000000..00b96e24 --- /dev/null +++ b/schemas/4.0/RoadEventFeature.json @@ -0,0 +1,621 @@ + +{ + "$id": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/RoadEventFeature.json", + "$schema": "http://json-schema.org/draft-07/schema#", + "title": "Road Event Feature (GeoJSON Feature)", + "description": "The container object for a specific WZDx road event; an instance of a GeoJSON Feature", + "type": "object", + "properties": { + "id": { + "description": "A unique identifier issued by the data feed provider to identify the WZDx road event", + "type": "string" + }, + "type": { + "description": "The GeoJSON object type; must be 'Feature'", + "enum": ["Feature"] + }, + "properties": { + "type": "object", + "properties": { + "core_details": { + "$ref": "#/definitions/RoadEventCoreDetails" + } + }, + "required": ["core_details"], + "oneOf": [ + { + "$ref": "#/definitions/WorkZoneRoadEvent" + }, + { + "$ref": "#/definitions/DetourRoadEvent" + }, + { + "$ref": "#/definitions/RestrictionRoadEvent" + } + ] + }, + "geometry": { + "oneOf": [ + { + "$ref": "https://geojson.org/schema/LineString.json" + }, + { + "$ref": "https://geojson.org/schema/MultiPoint.json" + } + ] + }, + "bbox": { + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/BoundingBox.json" + } + }, + "required": ["id","type","properties","geometry"], + "definitions": { + "WorkZoneRoadEvent": { + "title": "Work Zone Road Event", + "description": "Descibes a work zone road event including where, when, and what activities are taking place within a work zone on a roadway", + "type": "object", + "allOf": [ + { + "properties": { + "core_details": { + "properties": { + "event_type": { + "const": "work-zone" + } + }, + "required": ["event_type"] + } + }, + "required": ["core_details"] + }, + { + "properties": { + "core_details": { + "$ref": "#/definitions/RoadEventCoreDetails" + }, + "beginning_cross_street": { + "description": "Name or number of the nearest cross street along the roadway where the event begins", + "type": "string" + }, + "ending_cross_street": { + "description": "Name or number of the nearest cross street along the roadway where the event ends", + "type": "string" + }, + "beginning_milepost": { + "description": "The linear distance measured against a milepost marker along a roadway where the event begins", + "type": "number", + "minimum": 0 + }, + "ending_milepost": { + "description": "The linear distance measured against a milepost marker along a roadway where the event ends", + "type": "number", + "minimum": 0 + }, + "beginning_accuracy": { + "$ref": "#/definitions/SpatialVerification" + }, + "ending_accuracy": { + "$ref": "#/definitions/SpatialVerification" + }, + "start_date": { + "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event begins (e.g. 2020-11-03T19:37:00Z)", + "type": "string", + "format": "date-time" + }, + "end_date": { + "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event ends (e.g. 2020-11-03T19:37:00Z)", + "type": "string", + "format": "date-time" + }, + "start_date_accuracy": { + "$ref": "#/definitions/TimeVerification" + }, + "end_date_accuracy": { + "$ref": "#/definitions/TimeVerification" + }, + "event_status": { + "$ref": "#/definitions/EventStatus" + }, + "vehicle_impact": { + "$ref": "#/definitions/VehicleImpact" + }, + "location_method": { + "$ref": "#/definitions/LocationMethod" + }, + "worker_presence": { + "$ref": "#/definitions/WorkerPresence" + }, + "reduced_speed_limit_kph": { + "description": "If applicable, the reduced speed limit posted within the road event, in kilometers per hour", + "type": "number", + "minimum": 0 + }, + "restrictions": { + "description": "A list of zero or more restrictions applying to the road event", + "type": "array", + "items": { + "$ref": "#/definitions/Restriction" + } + }, + "types_of_work": { + "description": "A list of the types of work being done in a road event", + "type": "array", + "items": { + "$ref": "#/definitions/TypeOfWork" + } + }, + "lanes": { + "description": "A list of individual lanes within a road event (roadway segment)", + "type": "array", + "items": { + "$ref": "#/definitions/Lane" + } + } + }, + "required": [ + "core_details", + "beginning_accuracy", + "ending_accuracy", + "start_date", + "end_date", + "start_date_accuracy", + "end_date_accuracy", + "vehicle_impact", + "location_method" + ] + } + ] + }, + "DetourRoadEvent": { + "title": "Detour Road Event", + "description": "Descibes a detour on a roadway", + "type": "object", + "allOf": [ + { + "properties": { + "core_details": { + "properties": { + "event_type": { + "const": "detour" + } + }, + "required": ["event_type"] + } + }, + "required": ["core_details"] + }, + { + "properties": { + "core_details": { + "$ref": "#/definitions/RoadEventCoreDetails" + }, + "beginning_cross_street": { + "description": "Name or number of the nearest cross street along the roadway where the event begins", + "type": "string" + }, + "ending_cross_street": { + "description": "Name or number of the nearest cross street along the roadway where the event ends", + "type": "string" + }, + "beginning_milepost": { + "description": "The linear distance measured against a milepost marker along a roadway where the event begins", + "type": "number", + "minimum": 0 + }, + "ending_milepost": { + "description": "The linear distance measured against a milepost marker along a roadway where the event ends", + "type": "number", + "minimum": 0 + }, + "start_date": { + "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event begins (e.g. 2020-11-03T19:37:00Z)", + "type": "string", + "format": "date-time" + }, + "end_date": { + "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event ends (e.g. 2020-11-03T19:37:00Z)", + "type": "string", + "format": "date-time" + }, + "start_date_accuracy": { + "$ref": "#/definitions/TimeVerification" + }, + "end_date_accuracy": { + "$ref": "#/definitions/TimeVerification" + }, + "event_status": { + "$ref": "#/definitions/EventStatus" + } + }, + "required": [ + "core_details", + "start_date", + "end_date", + "start_date_accuracy", + "end_date_accuracy" + ] + } + ] + }, + "RestrictionRoadEvent": { + "title": "Restriction Road Event", + "description": "A road event describing a section of roadway and the limitations of how that section can be used", + "type": "object", + "allOf": [ + { + "properties": { + "core_details": { + "properties": { + "event_type": { + "const": "restriction" + } + }, + "required": ["event_type"] + } + }, + "required": ["core_details"] + }, + { + "properties": { + "core_details": { + "$ref": "#/definitions/RoadEventCoreDetails" + }, + "restrictions": { + "description": "A list of zero or more restrictions applying to the road event", + "type": "array", + "items": { + "$ref": "#/definitions/Restriction" + } + }, + "lanes": { + "description": "A list of individual lanes within a road event (roadway segment)", + "type": "array", + "items": { + "$ref": "#/definitions/Lane" + } + } + }, + "required": [ + "core_details" + ], + "anyOf": [ + { + "required": [ + "restrictions" + ] + }, + { + "required": [ + "lanes" + ] + } + ] + } + ] + }, + "RoadEventCoreDetails": { + "title": "Road Event Core Details", + "description": "The core details of an event occurring on a roadway (i.e. a road event) that is shared by all types of road events", + "type": "object", + "properties": { + "data_source_id": { + "description": "Identifies the data source from which the road event data is sourced from", + "type": "string" + }, + "event_type": { + "$ref": "#/definitions/EventType" + }, + "relationship": { + "$ref": "#/definitions/Relationship" + }, + "road_names": { + "description": "A list of publicly known names of the road on which the event occurs. This may include the road number designated by a jurisdiction such as a county, state or interstate (e.g. I-5, VT 133)", + "type": "array", + "minItems": 1, + "items": { + "type": "string" + } + }, + "direction": { + "$ref": "#/definitions/Direction" + }, + "description": { + "description": "Short free text description of the road event", + "type": "string" + }, + "creation_date": { + "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event was created (e.g. 2020-11-03T19:37:00Z)", + "type": "string", + "format": "date-time" + }, + "update_date": { + "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event was last updated (e.g. 2020-11-03T19:37:00Z)", + "type": "string", + "format": "date-time" + } + }, + "required": [ + "event_type", + "data_source_id", + "direction", + "road_names" + ] + }, + "LocationMethod": { + "title": "Location Method Enumerated Type", + "description": "The typical method used to locate the beginning and end of a work zone impact area", + "enum": [ + "channel-device-method", + "sign-method", + "junction-method", + "other", + "unknown" + ] + },"Relationship": { + "title": "Relationship", + "description": "Identifies both sequential and hierarchical relationships between road events and other entities. For example, a relationship can be used to link multiple road events to a common 'parent', such as a project or phase, or identify a sequence of road events", + "type": "object", + "properties": { + "first": { + "description": "Indicates the first (can be multiple) road event in a sequence of road events by RoadEventFeature 'id'", + "type": "array", + "minItems": 1, + "items": { + "type": "string" + } + }, + "next": { + "description": "Indicates the next (can be multiple) road event in a sequence of road events by RoadEventFeature 'id'", + "type": "array", + "minItems": 1, + "items": { + "type": "string" + } + }, + "parents": { + "description": "Indicates entities that the road event with this relationship is a part of, such as a work zone project or phase. Values can but do not have to correspond to a WZDx entity", + "type": "array", + "minItems": 1, + "items": { + "type": "string" + } + }, + "children": { + "description": "Indicates entities that are part of the road event with this relationship, such as a detour or piece of equipment. Values can but do not have to correspond to a WZDx entity", + "type": "array", + "minItems": 1, + "items": { + "type": "string" + } + } + } + }, + "TypeOfWork": { + "title": "Type of Work", + "description": "A description of the type of work being done in a road event and an indication of if that work will result in an architectural change to the roadway", + "type": "object", + "properties": { + "type_name": { + "$ref": "#/definitions/WorkTypeName" + }, + "is_architectural_change": { + "description": "A flag indicating whether the type of work will result in an architectural change to the roadway", + "type": "boolean" + } + }, + "required": ["type_name"] + }, + "Lane": { + "title": "Lane", + "description": "An individual lane within a road event", + "type": "object", + "properties": { + "order": { + "description": "The position (index) of the lane in sequence on the roadway, where '1' represents the left-most lane", + "type": "integer", + "minimum": 1 + }, + "status": { + "$ref": "#/definitions/LaneStatus" + }, + "type": { + "$ref": "#/definitions/LaneType" + }, + "lane_number": { + "description": "***DEPRECATED*** The number assigned to the lane to help identify its position. Flexible, but usually used for regular, driveable lanes", + "type": "integer", + "minimum": 1 + }, + "restrictions": { + "description": "A list of zero or more restrictions specific to the lane", + "type": "array", + "items": { + "$ref": "#/definitions/Restriction" + } + } + }, + "required": ["status", "type", "order"] + }, + "Restriction": { + "title": "Restriction", + "description": "A restriction on a roadway or lane, including type and value", + "type": "object", + "properties": { + "type": { + "$ref": "#/definitions/RestrictionType" + }, + "value": { + "type": "number" + }, + "unit": { + "$ref": "#/definitions/UnitOfMeasurement" + } + }, + "required": ["type"], + "dependencies": { + "value": ["unit"] + } + }, + "WorkerPresence": { + "title": "Worker Presence", + "description": "Information about the presence of workers in the work zone event area", + "type": "object", + "properties": { + "are_workers_present": { + "description": "Whether workers are present in the work zone event area, following the definition provided in the ‘worker_presence_definition’ property on the RoadEventDataSource object", + "type": "boolean" + }, + "method": { + "$ref": "#/definitions/WorkerPresenceMethod" + }, + "worker_presence_last_confirmed_date": { + "description": "Datetime at which the presence of workers was last confirmed using the 'source'", + "type": "string", + "format": "date-time" + }, + "confidence": { + "$ref": "#/definitions/WorkerPresenceConfidence" + }, + "definition": { + "description": "A list of situations in which workers are considered to be present in the jurisdiction of the data provider", + "type": "array", + "items": { + "$ref": "#/definitions/WorkerPresenceDefinition" + }, + "uniqueItems": true + } + }, + "required": ["are_workers_present"] + }, + "EventType": { + "title": "Road Event Type Enumerated Type", + "description": "The type of WZDx road event", + "enum": ["work-zone", "detour", "restriction"] + }, + "Direction": { + "title": "Direction Enumerated Type", + "description": "The direction for a road event based on standard naming for US roads; indicates the direction the traffic flow regardless of the real heading angle", + "enum": ["northbound", "eastbound", "southbound", "westbound"] + }, + "SpatialVerification": { + "title": "Spatial Verification Enumerated Type", + "description": "An indication of how a geographical coordinate was defined", + "enum": ["estimated", "verified"] + }, + "TimeVerification": { + "title": "Time Verification Enumerated Type", + "description": "A measure of how accurate a date-time is", + "enum": ["estimated", "verified"] + }, + "EventStatus": { + "title": "Event Status Enumerated Type", + "description": "The status of the road event", + "enum": ["planned", "pending", "active", "completed", "cancelled"] + }, + "VehicleImpact": { + "title": "Vehicle Impact Enumerated Type", + "description": "The impact to vehicular lanes along a single road in a single direction", + "enum": ["all-lanes-closed", "some-lanes-closed", "all-lanes-open", "alternating-one-way", "some-lanes-closed-merge-left", "some-lanes-closed-merge-right", "all-lanes-open-shift-left", "all-lanes-open-shift-right", "some-lanes-closed-split", "flagging", "temporary-traffic-signal", "unknown"] + }, + "RestrictionType": { + "title": "Restriction Type Enumerated Type", + "description": "The type of vehicle restriction on a roadway", + "enum": [ + "no-trucks", + "travel-peak-hours-only", + "hov-3", + "hov-2", + "no-parking", + "reduced-width", + "reduced-height", + "reduced-length", + "reduced-weight", + "axle-load-limit", + "gross-weight-limit", + "towing-prohibited", + "permitted-oversize-loads-prohibited", + "local-access-only" + ] + }, + "WorkTypeName": { + "title": "Work Type Name Enumerated Type", + "description": "A high-level text description of the type of work being done in a road event", + "enum": [ + "maintenance", + "minor-road-defect-repair", + "roadside-work", + "overhead-work", + "below-road-work", + "barrier-work", + "surface-work", + "painting", + "roadway-relocation", + "roadway-creation" + ] + }, + "LaneStatus": { + "title": "Lane Status Enumerated Type", + "description": "The status of the lane for the traveling public", + "enum": ["open", "closed", "shift-left", "shift-right", "merge-left", "merge-right", "alternating-flow"] + }, + "LaneType": { + "title": "Lane Type Enumerated Type", + "description": "An indication of the type of lane or shoulder", + "enum": [ + "general", + "exit-lane", + "exit-ramp", + "entrance-lane", + "entrance-ramp", + "sidewalk", + "bike-lane", + "shoulder", + "parking", + "median", + "center-left-turn-lane" + ] + }, + "UnitOfMeasurement": { + "title": "Unit of Measurement Enumerated Type", + "description": "Unit of measurement, used when providing a unit to accompany a value", + "enum": ["feet", "inches", "centimeters", "pounds", "tons", "kilograms"] + }, + "WorkerPresenceMethod": { + "title": "Worker Presence Method Enumerated Type", + "description": "Describes methods for how worker presence in a work zone event area is determined", + "enum": [ + "camera-monitoring", + "arrow-board-present", + "cones-present", + "maintenance-vehicle-present", + "wearables-present", + "mobile-device-present", + "check-in-app", + "check-in-verbal", + "scheduled" + ] + }, + "WorkerPresenceDefinition": { + "title": "Worker Presence Definition Enumerated Type", + "description": "Situations in which workers may be considered present in a work zone", + "enum": [ + "workers-in-work-zone-working", + "workers-in-work-zone-not-working", + "mobile-equipment-in-work-zone-moving", + "mobile-equipment-in-work-zone-not-working", + "fixed-equipment-in-work-zone", + "humans-behind-barrier", + "humans-in-right-of-way" + ] + }, + "WorkerPresenceConfidence": { + "title": "Worker Presence Confidence Enumerated Type", + "description": "A high-level description of the feed publisher's confidence in the reported WorkerPresence value of are_workers_present", + "enum": [ + "low", + "medium", + "high" + ] + } + } +} \ No newline at end of file diff --git a/schemas/4.0/RoadRestrictionFeed.json b/schemas/4.0/RoadRestrictionFeed.json new file mode 100644 index 00000000..2f1edcf8 --- /dev/null +++ b/schemas/4.0/RoadRestrictionFeed.json @@ -0,0 +1,55 @@ +{ + "$id": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/RoadRestrictionFeed.json", + "$schema": "http://json-schema.org/draft-07/schema#", + "title": "WZDx v4.0 Road Restriction Feed", + "description": "The GeoJSON output of a WZDx road restriction data feed (v4.0)", + "type": "object", + "properties": { + "feed_info": { + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/FeedInfo.json" + }, + "type": { + "description": "The GeoJSON type", + "enum": [ + "FeatureCollection" + ] + }, + "features": { + "description": "An array of GeoJSON Feature objects which represent WZDx restriction road events", + "type": "array", + "items": { + "allOf": [ + { + "properties": { + "properties": { + "properties": { + "core_details": { + "properties": { + "event_type": { + "const": "restriction" + } + }, + "required": ["event_type"] + } + }, + "required": ["core_details"] + } + }, + "required": ["properties"] + }, + { + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/RoadEventFeature.json" + } + ] + } + }, + "bbox": { + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/BoundingBox.json" + } + }, + "required": [ + "feed_info", + "type", + "features" + ] +} \ No newline at end of file diff --git a/schemas/4.0/SwzDeviceFeed.json b/schemas/4.0/SwzDeviceFeed.json index df7a5cfe..d53766a5 100644 --- a/schemas/4.0/SwzDeviceFeed.json +++ b/schemas/4.0/SwzDeviceFeed.json @@ -1,12 +1,12 @@ { - "$id": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/SwzDeviceFeed.json", + "$id": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/SwzDeviceFeed.json", "$schema": "http://json-schema.org/draft-07/schema#", "title": "WZDx v4.0 SwzDeviceFeed", "description": "The GeoJSON output of a WZDx smart work zone device data feed (v4.0)", "type": "object", "properties": { "feed_info": { - "$ref": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/FeedInfo.json" + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/FeedInfo.json" }, "type": { "description": "The GeoJSON type", @@ -20,7 +20,7 @@ } }, "bbox": { - "$ref": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/BoundingBox.json" + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/BoundingBox.json" } }, "required": ["feed_info", "type", "features"], @@ -78,7 +78,7 @@ ] }, "bbox": { - "$ref": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/BoundingBox.json" + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/BoundingBox.json" } }, "required": ["id","type","properties","geometry"] diff --git a/schemas/4.0/WZDxFeed.json b/schemas/4.0/WZDxFeed.json index ac89b43e..9b8e00a2 100644 --- a/schemas/4.0/WZDxFeed.json +++ b/schemas/4.0/WZDxFeed.json @@ -1,13 +1,12 @@ - { - "$id": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/WZDxFeed.json", + "$id": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/WZDxFeed.json", "$schema": "http://json-schema.org/draft-07/schema#", "title": "WZDx v4.0 WZDxFeed", "description": "The GeoJSON output of a WZDx feed data feed (v4.0)", "type": "object", "properties": { "road_event_feed_info": { - "$ref": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/FeedInfo.json" + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/FeedInfo.json" }, "type": { "description": "The GeoJSON type", @@ -17,572 +16,34 @@ "description": "An array of GeoJSON Feature objects which represent WZDx road events", "type": "array", "items": { - "$ref": "#/definitions/RoadEventFeature" - } - }, - "bbox": { - "$ref": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/BoundingBox.json" - } - }, - "required": ["road_event_feed_info", "type", "features"], - "definitions": { - "LocationMethod": { - "title": "Location Method Enumerated Type", - "description": "The typical method used to locate the beginning and end of a work zone impact area", - "enum": [ - "channel-device-method", - "sign-method", - "junction-method", - "other", - "unknown" - ] - }, - "RoadEventFeature": { - "title": "Road Event Feature (GeoJSON Feature)", - "description": "The container object for a specific WZDx road event; an instance of a GeoJSON Feature", - "type": "object", - "properties": { - "id": { - "description": "A unique identifier issued by the data feed provider to identify the WZDx road event", - "type": "string" - }, - "type": { - "description": "The GeoJSON object type; must be 'Feature'", - "enum": ["Feature"] - }, - "properties": { - "type": "object", - "properties": { - "core_details": { - "$ref": "#/definitions/RoadEventCoreDetails" - } - }, - "required": ["core_details"], - "oneOf": [ - { - "$ref": "#/definitions/WorkZoneRoadEvent" - }, - { - "$ref": "#/definitions/DetourRoadEvent" - } - ] - }, - "geometry": { - "oneOf": [ - { - "$ref": "https://geojson.org/schema/LineString.json" - }, - { - "$ref": "https://geojson.org/schema/MultiPoint.json" - } - ] - }, - "bbox": { - "$ref": "https://raw.githubusercontent.com/usdot-jpo-ode/wzdx/field-devices/schemas/4.0/BoundingBox.json" - } - }, - "required": ["id","type","properties","geometry"] - }, - "RoadEventCoreDetails": { - "title": "Road Event Core Details", - "description": "The core details of an event occurring on a roadway (i.e. a road event) that is shared by all types of road events", - "type": "object", - "properties": { - "data_source_id": { - "description": "Identifies the data source from which the road event data is sourced from", - "type": "string" - }, - "event_type": { - "$ref": "#/definitions/EventType" - }, - "relationship": { - "$ref": "#/definitions/Relationship" - }, - "road_names": { - "description": "A list of publicly known names of the road on which the event occurs. This may include the road number designated by a jurisdiction such as a county, state or interstate (e.g. I-5, VT 133)", - "type": "array", - "minItems": 1, - "items": { - "type": "string" - } - }, - "direction": { - "$ref": "#/definitions/Direction" - }, - "description": { - "description": "Short free text description of the road event", - "type": "string" - }, - "creation_date": { - "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event was created (e.g. 2020-11-03T19:37:00Z)", - "type": "string", - "format": "date-time" - }, - "update_date": { - "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event was last updated (e.g. 2020-11-03T19:37:00Z)", - "type": "string", - "format": "date-time" - } - }, - "required": [ - "event_type", - "data_source_id", - "direction", - "road_names" - ] - }, - "WorkZoneRoadEvent": { - "title": "Work Zone Road Event", - "description": "Descibes a work zone road event including where, when, and what activities are taking place within a work zone on a roadway", - "type": "object", - "allOf": [ - { - "properties": { - "core_details": { + "allOf": [ + { + "properties": { "properties": { - "event_type": { - "const": "work-zone" - } - }, - "required": ["event_type"] - } - }, - "required": ["core_details"] - }, - { - "properties": { - "core_details": { - "$ref": "#/definitions/RoadEventCoreDetails" - }, - "beginning_cross_street": { - "description": "Name or number of the nearest cross street along the roadway where the event begins", - "type": "string" - }, - "ending_cross_street": { - "description": "Name or number of the nearest cross street along the roadway where the event ends", - "type": "string" - }, - "beginning_milepost": { - "description": "The linear distance measured against a milepost marker along a roadway where the event begins", - "type": "number", - "minimum": 0 - }, - "ending_milepost": { - "description": "The linear distance measured against a milepost marker along a roadway where the event ends", - "type": "number", - "minimum": 0 - }, - "beginning_accuracy": { - "$ref": "#/definitions/SpatialVerification" - }, - "ending_accuracy": { - "$ref": "#/definitions/SpatialVerification" - }, - "start_date": { - "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event begins (e.g. 2020-11-03T19:37:00Z)", - "type": "string", - "format": "date-time" - }, - "end_date": { - "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event ends (e.g. 2020-11-03T19:37:00Z)", - "type": "string", - "format": "date-time" - }, - "start_date_accuracy": { - "$ref": "#/definitions/TimeVerification" - }, - "end_date_accuracy": { - "$ref": "#/definitions/TimeVerification" - }, - "event_status": { - "$ref": "#/definitions/EventStatus" - }, - "vehicle_impact": { - "$ref": "#/definitions/VehicleImpact" - }, - "location_method": { - "$ref": "#/definitions/LocationMethod" - }, - "worker_presence": { - "$ref": "#/definitions/WorkerPresence" - }, - "reduced_speed_limit_kph": { - "description": "If applicable, the reduced speed limit posted within the road event, in kilometers per hour", - "type": "number", - "minimum": 0 - }, - "restrictions": { - "description": "A list of zero or more restrictions applying to the road event", - "type": "array", - "items": { - "$ref": "#/definitions/Restriction" + "properties": { + "core_details": { + "properties": { + "event_type": { + "enum": ["work-zone", "detour"] + } + }, + "required": ["event_type"] + } + }, + "required": ["core_details"] } }, - "types_of_work": { - "description": "A list of the types of work being done in a road event", - "type": "array", - "items": { - "$ref": "#/definitions/TypeOfWork" - } - }, - "lanes": { - "description": "A list of individual lanes within a road event (roadway segment)", - "type": "array", - "items": { - "$ref": "#/definitions/Lane" - } - } + "required": ["properties"] }, - "required": [ - "core_details", - "beginning_accuracy", - "ending_accuracy", - "start_date", - "end_date", - "start_date_accuracy", - "end_date_accuracy", - "vehicle_impact", - "location_method" - ] - } - ] - }, - "DetourRoadEvent": { - "title": "Detour Road Event", - "description": "Descibes a detour on a roadway", - "type": "object", - "allOf": [ - { - "properties": { - "core_details": { - "properties": { - "event_type": { - "const": "detour" - } - }, - "required": ["event_type"] - } - }, - "required": ["core_details"] - }, - { - "properties": { - "core_details": { - "$ref": "#/definitions/RoadEventCoreDetails" - }, - "beginning_cross_street": { - "description": "Name or number of the nearest cross street along the roadway where the event begins", - "type": "string" - }, - "ending_cross_street": { - "description": "Name or number of the nearest cross street along the roadway where the event ends", - "type": "string" - }, - "beginning_milepost": { - "description": "The linear distance measured against a milepost marker along a roadway where the event begins", - "type": "number", - "minimum": 0 - }, - "ending_milepost": { - "description": "The linear distance measured against a milepost marker along a roadway where the event ends", - "type": "number", - "minimum": 0 - }, - "start_date": { - "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event begins (e.g. 2020-11-03T19:37:00Z)", - "type": "string", - "format": "date-time" - }, - "end_date": { - "description": "The UTC date and time (formatted according to RFC 3339, Section 5.6) when the road event ends (e.g. 2020-11-03T19:37:00Z)", - "type": "string", - "format": "date-time" - }, - "start_date_accuracy": { - "$ref": "#/definitions/TimeVerification" - }, - "end_date_accuracy": { - "$ref": "#/definitions/TimeVerification" - }, - "event_status": { - "$ref": "#/definitions/EventStatus" - } - }, - "required": [ - "core_details", - "start_date", - "end_date", - "start_date_accuracy", - "end_date_accuracy" - ] - } - ] - }, - "Relationship": { - "title": "Relationship", - "description": "Identifies both sequential and hierarchical relationships between road events and other entities. For example, a relationship can be used to link multiple road events to a common 'parent', such as a project or phase, or identify a sequence of road events", - "type": "object", - "properties": { - "first": { - "description": "Indicates the first (can be multiple) road event in a sequence of road events by RoadEventFeature 'id'", - "type": "array", - "minItems": 1, - "items": { - "type": "string" - } - }, - "next": { - "description": "Indicates the next (can be multiple) road event in a sequence of road events by RoadEventFeature 'id'", - "type": "array", - "minItems": 1, - "items": { - "type": "string" - } - }, - "parents": { - "description": "Indicates entities that the road event with this relationship is a part of, such as a work zone project or phase. Values can but do not have to correspond to a WZDx entity", - "type": "array", - "minItems": 1, - "items": { - "type": "string" + { + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/RoadEventFeature.json" } - }, - "children": { - "description": "Indicates entities that are part of the road event with this relationship, such as a detour or piece of equipment. Values can but do not have to correspond to a WZDx entity", - "type": "array", - "minItems": 1, - "items": { - "type": "string" - } - } - } - }, - "TypeOfWork": { - "title": "Type of Work", - "description": "A description of the type of work being done in a road event and an indication of if that work will result in an architectural change to the roadway", - "type": "object", - "properties": { - "type_name": { - "$ref": "#/definitions/WorkTypeName" - }, - "is_architectural_change": { - "description": "A flag indicating whether the type of work will result in an architectural change to the roadway", - "type": "boolean" - } - }, - "required": ["type_name"] - }, - "Lane": { - "title": "Lane", - "description": "An individual lane within a road event", - "type": "object", - "properties": { - "order": { - "description": "The position (index) of the lane in sequence on the roadway, where '1' represents the left-most lane", - "type": "integer", - "minimum": 1 - }, - "status": { - "$ref": "#/definitions/LaneStatus" - }, - "type": { - "$ref": "#/definitions/LaneType" - }, - "lane_number": { - "description": "***DEPRECATED*** The number assigned to the lane to help identify its position. Flexible, but usually used for regular, driveable lanes", - "type": "integer", - "minimum": 1 - }, - "restrictions": { - "description": "A list of zero or more restrictions specific to the lane", - "type": "array", - "items": { - "$ref": "#/definitions/Restriction" - } - } - }, - "required": ["status", "type", "order"] - }, - "Restriction": { - "title": "Restriction", - "description": "A restriction on a roadway or lane, including type and value", - "type": "object", - "properties": { - "type": { - "$ref": "#/definitions/RestrictionType" - }, - "value": { - "type": "number" - }, - "unit": { - "$ref": "#/definitions/UnitOfMeasurement" - } - }, - "required": ["type"], - "dependencies": { - "value": ["unit"] + ] } }, - "WorkerPresence": { - "title": "Worker Presence", - "description": "Information about the presence of workers in the work zone event area", - "type": "object", - "properties": { - "are_workers_present": { - "description": "Whether workers are present in the work zone event area, following the definition provided in the ‘worker_presence_definition’ property on the RoadEventDataSource object", - "type": "boolean" - }, - "method": { - "$ref": "#/definitions/WorkerPresenceMethod" - }, - "worker_presence_last_confirmed_date": { - "description": "Datetime at which the presence of workers was last confirmed using the 'source'", - "type": "string", - "format": "date-time" - }, - "confidence": { - "$ref": "#/definitions/WorkerPresenceConfidence" - }, - "definition": { - "description": "A list of situations in which workers are considered to be present in the jurisdiction of the data provider", - "type": "array", - "items": { - "$ref": "#/definitions/WorkerPresenceDefinition" - }, - "uniqueItems": true - } - }, - "required": ["are_workers_present"] - }, - "EventType": { - "title": "Road Event Type Enumerated Type", - "description": "The type of WZDx road event", - "enum": ["work-zone", "detour"] - }, - "Direction": { - "title": "Direction Enumerated Type", - "description": "The direction for a road event based on standard naming for US roads; indicates the direction the traffic flow regardless of the real heading angle", - "enum": ["northbound", "eastbound", "southbound", "westbound"] - }, - "SpatialVerification": { - "title": "Spatial Verification Enumerated Type", - "description": "An indication of how a geographical coordinate was defined", - "enum": ["estimated", "verified"] - }, - "TimeVerification": { - "title": "Time Verification Enumerated Type", - "description": "A measure of how accurate a date-time is", - "enum": ["estimated", "verified"] - }, - "EventStatus": { - "title": "Event Status Enumerated Type", - "description": "The status of the road event", - "enum": ["planned", "pending", "active", "completed", "cancelled"] - }, - "VehicleImpact": { - "title": "Vehicle Impact Enumerated Type", - "description": "The impact to vehicular lanes along a single road in a single direction", - "enum": ["all-lanes-closed", "some-lanes-closed", "all-lanes-open", "alternating-one-way", "some-lanes-closed-merge-left", "some-lanes-closed-merge-right", "all-lanes-open-shift-left", "all-lanes-open-shift-right", "some-lanes-closed-split", "flagging", "temporary-traffic-signal", "unknown"] - }, - "RestrictionType": { - "title": "Restriction Type Enumerated Type", - "description": "The type of vehicle restriction on a roadway", - "enum": [ - "no-trucks", - "travel-peak-hours-only", - "hov-3", - "hov-2", - "no-parking", - "reduced-width", - "reduced-height", - "reduced-length", - "reduced-weight", - "axle-load-limit", - "gross-weight-limit", - "towing-prohibited", - "permitted-oversize-loads-prohibited", - "local-access-only" - ] - }, - "WorkTypeName": { - "title": "Work Type Name Enumerated Type", - "description": "A high-level text description of the type of work being done in a road event", - "enum": [ - "maintenance", - "minor-road-defect-repair", - "roadside-work", - "overhead-work", - "below-road-work", - "barrier-work", - "surface-work", - "painting", - "roadway-relocation", - "roadway-creation" - ] - }, - "LaneStatus": { - "title": "Lane Status Enumerated Type", - "description": "The status of the lane for the traveling public", - "enum": ["open", "closed", "shift-left", "shift-right", "merge-left", "merge-right", "alternating-flow"] - }, - "LaneType": { - "title": "Lane Type Enumerated Type", - "description": "An indication of the type of lane or shoulder", - "enum": [ - "general", - "exit-lane", - "exit-ramp", - "entrance-lane", - "entrance-ramp", - "sidewalk", - "bike-lane", - "shoulder", - "parking", - "median", - "center-left-turn-lane" - ] - }, - "UnitOfMeasurement": { - "title": "Unit of Measurement Enumerated Type", - "description": "Unit of measurement, used when providing a unit to accompany a value", - "enum": ["feet", "inches", "centimeters", "pounds", "tons", "kilograms"] - }, - "WorkerPresenceMethod": { - "title": "Worker Presence Method Enumerated Type", - "description": "Describes methods for how worker presence in a work zone event area is determined", - "enum": [ - "camera-monitoring", - "arrow-board-present", - "cones-present", - "maintenance-vehicle-present", - "wearables-present", - "mobile-device-present", - "check-in-app", - "check-in-verbal", - "scheduled" - ] - }, - "WorkerPresenceDefinition": { - "title": "Worker Presence Definition Enumerated Type", - "description": "Situations in which workers may be considered present in a work zone", - "enum": [ - "workers-in-work-zone-working", - "workers-in-work-zone-not-working", - "mobile-equipment-in-work-zone-moving", - "mobile-equipment-in-work-zone-not-working", - "fixed-equipment-in-work-zone", - "humans-behind-barrier", - "humans-in-right-of-way" - ] - }, - "WorkerPresenceConfidence": { - "title": "Worker Presence Confidence Enumerated Type", - "description": "A high-level description of the feed publisher's confidence in the reported WorkerPresence value of are_workers_present", - "enum": [ - "low", - "medium", - "high" - ] + "bbox": { + "$ref": "https://raw.githubusercontent.com/DeraldDudley/wzdx/RestrictionEvent/schemas/4.0/BoundingBox.json" } - } -} + }, + "required": ["road_event_feed_info", "type", "features"] +} \ No newline at end of file diff --git a/spec-content/README.md b/spec-content/README.md index 6782c548..f6e7d085 100644 --- a/spec-content/README.md +++ b/spec-content/README.md @@ -2,6 +2,7 @@ The WZDx specification defines the content and structure of several GeoJSON documents, each intended to be distributed as a data feed. Each GeoJSON document (colloquially "feed") contains a single feed root object. WZDx v4.0 defines the following feed objects: - [WZDxFeed](/spec-content/objects/WZDxFeed.md): describes high-level information about work zone events ocurring on roadways (called "road events") that impact the characteristics of the roadway and involve a change from the default state (such as a lane closure). This is the original work zone data exchange feed and the only feed that WZDx defined until [version 4.0](https://github.com/usdot-jpo-ode/wzdx/releases/tag/v4.0). +- [RoadRestrictionFeed](/spec-content/objects/RoadRestrictionFeed.md): describes the location and details of restrictions on roadways. - [SwzDeviceFeed](/spec-content/objects/SwzDeviceFeed.md): describes information (location, status, live data) about field devices deployed on the roadway in work zones. Each feed object contains many layers of child objects. Together all the objects define the WZDx feed. All WZDx objects are located in the [objects](/spec-content/objects) subdirectory and listed in the [Objects](#objects) section of this document. @@ -30,6 +31,7 @@ Object | Description --- | --- [FeedDataSource](/spec-content/objects/FeedDataSource.md) | Information about a specific data source used to build a work zone data feed. [FeedInfo](/spec-content/objects/FeedInfo.md) | Information about a WZDx feed such as metadata, contact information, and data sources. +[RoadRestrictionFeed](/spec-content/objects/RoadRestrictionFeed.md) | The root (highest-level) object of a **Road Restriction Feed** GeoJSON document. [SwzDeviceFeed](/spec-content/objects/SwzDeviceFeed.md) | The root (highest-level) object of **Smart Work Zone Device Feed** GeoJSON document. [WZDxFeed](/spec-content/objects/WZDxFeed.md) | The root (highest-level) object of a **WZDx Feed** GeoJSON document. @@ -40,8 +42,9 @@ Object | Description --- | --- [DetourRoadEvent](/spec-content/objects/DetourRoadEvent.md) | A detour on a roadway. [Lane](/spec-content/objects/Lane.md) | An individual lane within a road event. -[Restriction](/spec-content/objects/Restriction.md) | A restriction on a road event or lane, including type and value. [Relationship](/spec-content/objects/Relationship.md) | Identification of both sequential and hierarchical relationships between road events and other entities. +[Restriction](/spec-content/objects/Restriction.md) | A restriction on a road event or lane, including type and value. +[RestrictionRoadEvent](/spec-content/objects/RestrictionRoadEvent.md) | Describes a section of roadway and the limitations of how that section can be used. [RoadEventCoreDetails](/spec-content/objects/RoadEventCoreDetails.md) | The core details of an event occurring on a roadway (i.e. a road event) that is shared by all types of road events. [RoadEventDataSource](/spec-content/objects/RoadEventDataSource.md) | Information about a specific data source used to build a work zone data feed. [RoadEventFeature](/spec-content/objects/RoadEventFeature.md) | The GeoJSON `Feature` container object for a WZDx `RoadEvent`. @@ -74,6 +77,10 @@ The object diagrams below depict the relationship between the data objects for e ![Object Diagram](/images/wzdx_object_diagram.jpg) +#### RoadRestrictionFeed + +[TBD] + #### SwzDeviceFeed [TBD] diff --git a/spec-content/enumerated-types/EventType.md b/spec-content/enumerated-types/EventType.md index cf253ae1..c5831f5d 100644 --- a/spec-content/enumerated-types/EventType.md +++ b/spec-content/enumerated-types/EventType.md @@ -6,6 +6,7 @@ Value | Description --- | --- `work-zone` | An area of a trafficway with highway construction, maintenance, or utility-work activities. A work zone is typically marked by signs, channeling devices, barriers, pavement markings, and/or work vehicles. It extends from the first warning sign or flashing lights on a vehicle to the "End of Road Work" sign or the last traffic control device. A work zone may be for short or long durations and may include stationary or moving activities.
Inclusions:
  1. Long-term stationary highway construction such as building a new bridge, adding travel lanes to the roadway, and extending an existing trafficway.
  2. Mobile highway maintenance such as striping the roadway, median, and roadside grass mowing/landscaping, and pothole repair.
  3. Short-term stationary utility work such as repairing electric, gas, or water lines within the trafficway.
Exclusions:
  1. Private construction, maintenance, or utility work outside the trafficway.
*The AASHTO term equivalent to roadway is traveled way.
*The AASHTO term equivalent to trafficway is highway, street, or road.

Source: https://www.fhwa.dot.gov/publications/publicroads/99mayjun/workzone.cfm `detour` | A temporary rerouting of road users onto an existing trafficway to avoid a work zone or other impedance.

Source: https://mutcd.fhwa.dot.gov/htm/2009/part6/part6c.htm +`restriction` | A section of roadway that has limitations of how that section can be used. ## Used By Property | Object diff --git a/spec-content/enumerated-types/RestrictionType.md b/spec-content/enumerated-types/RestrictionType.md index 45dd1774..183264d7 100644 --- a/spec-content/enumerated-types/RestrictionType.md +++ b/spec-content/enumerated-types/RestrictionType.md @@ -22,4 +22,4 @@ Value | Description ## Used By Property | Object --- | --- -`type` | [Restriction](/spec-content/objects/Restriction.md) +`type` | [Restriction](/spec-content/objects/Restriction.md) \ No newline at end of file diff --git a/spec-content/objects/FeedInfo.md b/spec-content/objects/FeedInfo.md index d2703b6f..5bc07046 100644 --- a/spec-content/objects/FeedInfo.md +++ b/spec-content/objects/FeedInfo.md @@ -16,4 +16,6 @@ Name | Type | Description | Conformance | Notes ## Used By Property | Object --- | --- +`feed_info` | [RoadRestrictionFeed](/spec-content/objects/RoadRestrictionFeed.md) +`feed_info` | [SwzDeviceFeed](/spec-content/objects/SwzDeviceFeed.md) `road_event_feed_info` | [WZDxFeed](/spec-content/objects/WZDxFeed.md) diff --git a/spec-content/objects/Lane.md b/spec-content/objects/Lane.md index bbdad4f9..6975e6b6 100644 --- a/spec-content/objects/Lane.md +++ b/spec-content/objects/Lane.md @@ -14,3 +14,4 @@ Name | Type | Description | Conformance | Notes Property | Object --- | --- `lanes` | [WorkZoneRoadEvent](/spec-content/objects/WorkZoneRoadEvent.md) +`lanes` | [RestrictionRoadEvent](/spec-content/objects/RestrictionRoadEvent.md) diff --git a/spec-content/objects/Restriction.md b/spec-content/objects/Restriction.md index f507be70..786e2f17 100644 --- a/spec-content/objects/Restriction.md +++ b/spec-content/objects/Restriction.md @@ -1,5 +1,5 @@ # Restriction Object -The `Restriction` object describes a restriction on a roadway or lane. This object is used by both the [RoadEvent](/spec-content/objects/RoadEvent.md) and [Lane](/spec-content/objects/Lane.md) objects. +The `Restriction` object describes a restriction on a roadway or lane. This object is used by the [WorkZoneRoadEvent](/spec-content/objects/WorkZoneRoadEvent.md), [RestrictionRoadEvent](/spec-content/objects/RestrictionRoadEvent.md), and [Lane](/spec-content/objects/Lane.md) objects. ## Properties Name | Type | Description | Conformance | Notes @@ -13,3 +13,4 @@ Property | Object --- | --- `restrictions` | [WorkZoneRoadEvent](/spec-content/objects/WorkZoneRoadEvent.md) `restrictions` | [Lane](/spec-content/objects/Lane.md) +`restrictions` | [RestrictionRoadEvent](/spec-content/objects/RestrictionRoadEvent.md) diff --git a/spec-content/objects/RestrictionRoadEvent.md b/spec-content/objects/RestrictionRoadEvent.md new file mode 100644 index 00000000..43f6ba05 --- /dev/null +++ b/spec-content/objects/RestrictionRoadEvent.md @@ -0,0 +1,19 @@ +# RestrictionRoadEvent Object +The `RestrictionRoadEvent` object describes one or more restrictions on a section of a roadway. It describes the location of the road section and the limitations on how it can be used. The `RestrictionRoadEvent` is a linear road event intended to represent persistent restrictions without a defined start or event date, such as bridge clearances. + +The `RestrictionRoadEvent` is a type of road event; it has a `core_details` property which contains the [RoadEventCoreDetails](/spec-content/objects/RoadEventCoreDetails.md) and exists within a [RoadEventFeature](/spec-content/objects/RoadEventFeature.md). + +For representing restrictions due to road work, see the [WorkZoneRoadEvent](/spec-content/objects/WorkZoneRoadEvent.md) and [WZDxFeed](/spec-content/objects/WZDxFeed.md). + +## Properties +Name | Type | Description | Conformance | Notes +--- | --- | --- | --- | --- +`core_details` | [RoadEventCoreDetails](/spec-content/objects/RoadEventCoreDetails.md) | Describes the basic characterisitics of a Road Event. | Required | +`restrictions` | Array; [[Restriction](/spec-content/objects/Restriction.md)] | A list of zero or more road restrictions that apply to the roadway segment described by this road event. | Conditional: required if `lanes` property is not provided. | Restrictions can also be provided on an individual lane. +`lanes` | Array; \[[Lane](/spec-content/objects/Lane.md)\] | A list of individual lanes within a road event (roadway segment) | Conditional: required if `restrictions` property is not provided. | + +## Used By +Property | Object +--- | --- +`properties` | [RoadEventFeature](/spec-content/objects/RoadEventFeature.md) + diff --git a/spec-content/objects/RoadEventFeature.md b/spec-content/objects/RoadEventFeature.md index 6fe2521a..c016535d 100644 --- a/spec-content/objects/RoadEventFeature.md +++ b/spec-content/objects/RoadEventFeature.md @@ -6,7 +6,7 @@ Name | Type | Description | Conformance | Notes --- | --- | --- | --- | --- `id` | String | A unique identifier issued by the data feed provider to identify the WZDx road event. | Required | This is a GeoJSON property. `type` | String; `"Feature"` | The GeoJSON object type. This MUST be the string `Feature`. | Required | This is a GeoJSON property. -`properties` | One of: [WorkZoneRoadEvent](/spec-content/objects/WorkZoneRoadEvent.md), [DetourRoadEvent](/spec-content/objects/DetourRoadEvent.md) | The specific details of the road event. | Required | This is a GeoJSON property. +`properties` | One of: [WorkZoneRoadEvent](/spec-content/objects/WorkZoneRoadEvent.md), [DetourRoadEvent](/spec-content/objects/DetourRoadEvent.md), [RestrictionRoadEvent](/spec-content/objects/RestrictionRoadEvent.md) | The specific details of the road event. | Required | This is a GeoJSON property. `geometry` | GeoJSON [Geometry](https://tools.ietf.org/html/rfc7946#section-3.1) object with `type` of [LineString](https://tools.ietf.org/html/rfc7946#section-3.1.4) or [MultiPoint](https://tools.ietf.org/html/rfc7946#section-3.1.3) | The geometry of the road event. The Geometry object's `type` property MUST be [LineString](https://tools.ietf.org/html/rfc7946#section-3.1.4) or [MultiPoint](https://tools.ietf.org/html/rfc7946#section-3.1.3). `LineString` allows specifying the entire road event path and should be preferred. `MultiPoint` should be used when only the start and end coordinates are known. | Required | This is a GeoJSON property. `bbox` | GeoJSON [Bounding Box](https://tools.ietf.org/html/rfc7946#section-5) | Information on the coordinate range for this RoadEventFeature. Must be an array of length `2n` where `n` is the number of dimensions represented in the `geometry` property, with all axes of the most southwesterly point followed by all axes of the more northeasterly point. The axes order of a bbox follows the axes order of the `geometry`. | Optional | This is a GeoJSON property. @@ -14,3 +14,4 @@ Name | Type | Description | Conformance | Notes Property | Object --- | --- `features` | [WZDx Feed](/spec-content/objects/WZDxFeed.md) +`features` | [RoadRestrictionFeed](spec-content/objects/RoadRestrictionFeed.md) diff --git a/spec-content/objects/RoadRestrictionFeed.md b/spec-content/objects/RoadRestrictionFeed.md new file mode 100644 index 00000000..0905b0e0 --- /dev/null +++ b/spec-content/objects/RoadRestrictionFeed.md @@ -0,0 +1,13 @@ +# RoadRestrictionFeed Object (GeoJSON FeatureCollection) +The `RoadRestrictionFeed` object is the root (highest level) object of a WZDx road restriction feed. There is one `RoadRestrictionFeed` object per road restriction feed GeoJSON document. The `RoadRestrictionFeed` is a [GeoJSON FeatureCollection](https://tools.ietf.org/html/rfc7946#section-3.3). + +## Properties +Name | Type | Description | Conformance | Notes +--- | --- | --- | --- | --- +`feed_info` | [RoadEventFeedInfo](/spec-content/objects/RoadEventFeedInfo.md) | Information about the WZDx road restriction feed. | Required | This is a WZDx-specific [foreign member](https://tools.ietf.org/html/rfc7946#section-6.1) and is not part of the GeoJSON specification. +`type` | String; `"FeatureCollection"` | The GeoJSON object type. For WZDx, this must be the string `FeatureCollection`. | Required | This is a GeoJSON property. +`features` | Array; \[[RoadEventFeature](/spec-content/objects/RoadEventFeature.md)\] | An array of GeoJSON [Feature](https://tools.ietf.org/html/rfc7946#section-3.2) objects which represent WZDx road events. | Required | +`bbox` | GeoJSON [Bounding Box](https://tools.ietf.org/html/rfc7946#section-5) | Information on the coordinate range for all RoadEventFeatures in the WZDx feed. Must be an array of length 2*n where n is the number of dimensions represented in the contained geometries, with all axes of the most southwesterly point followed by all axes of the more northeasterly point. The axes order of a bbox follows the axes order of geometries. | Optional | This is a GeoJSON property. + +## Used By +Road Restriction GeoJSON document (one `RoadRestrictionFeed` object per file).