The Mapbox vector tile specification provides structure for including data values as properties associated with a feature, but no mechanism for interpreting the meaning or intended use. As such, GIBS has developed a specification for defining each property contained within MVTs in its vector products. Each vector product has an associated JSON vector metadata file which provides the following information:
Note |
---|
The current vector metadata JSON schema may be found here. |
The following table outlines the fields in the GIBS vector metadata specification.
Name | Description | Type | Required? | Sample Value |
---|---|---|---|---|
Identifier | The unique identifier of the MVT property. | String | FRP | |
Title | A human readable title for the property. | String | Fire Radiative Power | |
Description | A human readable description for the property. | String | A measure of the rate of radiant heat output from a fire. | |
Units | The units value to be applied to the actual value of this property. | String | MW | |
DataType | The data type of this property. Possible values include int, float, string, or datetime. | Enumeration | float | |
ValueList | A listing of the possible valid values for a 'string' property type, if the property has a controlled list. | Array | Only one may be used | [ "Lake Ice", "Sea Ice", "Not Ice" ] |
ValueRanges | A listing of mutually exclusive min and max value pairs representing ranges of valid values for the 'Integer', 'float', and 'datetime' property types. | Array of Objects | [ { "Min": 0, "Max": 99999999 } ] | |
ValueMap | A map of the possible valid values for 'string' or 'int' property types, and their associated description. This facilitates a key-value lookup table allowing for a simplified property value (i.e. the ‘key’). | Object | { 10 : “Processed Fire Pixel”, 20 : “Saturated Fire Pixel” } | |
Function | The property’s intended function as a part of the visualization product. Possible values include:
| Enumeration | Describe | |
IsOptional | Indicates whether the property is optional. | Boolean | true | |
IsLabel | Indicates whether the property should be used to label the point in a user interface. | Boolean | true |
All vector metadata file are validated against the following "business logic" rules that extend beyond the basic individual property constraints.
A vector metadata file is a list of content blocks defining each property. The following snippet shows an example of a single property's definition within the vector metadata file.
Code Block | ||||
---|---|---|---|---|
| ||||
{ "Identifier" : "NumReactor", "Title" : "Number of Reactors", "Description": "Number of Active Reactors at a given Plant", "Units" : "Reactors", "DataType" : "int", "ValueRanges": [ { "Min": 1, "Max": 9 } ], "Function" : "Style", "IsOptional" : false, "IsLabel" : false } |
The following block provides a full example of a vector metadata file.
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
{ "id": "Nuclear_Power_Plant_Locations", "mvt_properties": [ { "Identifier" : "Plant", "Title" : "Plant Site Name", "Description": "Name of Nuclear Plant", "DataType" : "string", "Function" : "Identify", "IsOptional" : false, "IsLabel" : true }, { "Identifier" : "NumReactor", "Title" : "Number of Reactors", "Description": "Number of Active Reactors at a given Plant", "Units" : "Reactors", "DataType" : "int", "ValueRanges": [ { "Min": 1, "Max": 9 } ], "Function" : "Style", "IsOptional" : false, "IsLabel" : false }, { "Identifier" : "p10_30", "Title" : "Population within 30km (2010)", "Description": "Total population within a 30km radius of the nuclear plant (2010)", "Units" : "Persons", "DataType" : "int", "ValueRanges": [ { "Min": 275, "Max": 7170590 } ], "Function" : "Describe", "IsOptional" : false, "IsLabel" : false } } |
Hide comments |
---|