rNews 0.5: The Location Class

The Location Class
Figure: Attributes of the Location class.

The Location class is a subclass of the Concept class used for annotating geographic real-world entities. To ensure maximum compatability with existing standards for representing geographic metadata, the Location class borrows the majority of its attributes from the existing GeoRSS standard. These attributes include: point, line, polygon, box, circle, and elevation.

The Location class specifies one attribute not found in the GeoRSS specification: featureCode. This attribute is used to indicate what kind of geographic entity is indicated by a Location object. The IPTC suggests, but does not require, that implementors of rNews populate this field with values drawn from the controlled vocabulary of feature codes provided by geonames.org.

Location Attribute Summary

The table below enumerates all attributes of the Location class and provides the expected data type, category (core/power) and a definition of each attribute.

Attribute Type Category Definition Example
point String core A point is a physical location on Earth. A point is expressed as a latitude and longitude separated by a space character. 40.672 -73.983
line String power A line is a point-to-point path consisting of two or more points. A line is expressed as a series of two or more point objects separated by space. 38.92 -94.64 42.71 -73.2
polygon String power A polygon is the area enclosed by a point-to-point path for which the starting and ending points are the same. A polygon is expressed as a series of four or more space-delimited points where the first and final points are identical. 40.764161 -73.972836 40.768062 -73.981419 40.800296 -73.958416 40.796918 -73.94949 40.764161 -73.972836
box String power A box is the area enclosed by the rectangle formed by two points. The first point is the lower corner, the second point is the upper corner. A box is expressed as two points separated by a space character. 38.920952 -94.645443 38.951797 -94.680439
circle String power A circle is the circular region of a specified radius centered at a specified latitude and longitude. A circle is expressed as a pair followed by a radius in meters. 38.920952 -94.645443 500
elevation String power The elevation is the height above sea level of a specified point. An Elevation attribute must be specified in conjunction with a Point attribute. 807.79
featureCode String power A code indicating the type of the geographic entity specified by a Location object. The IPTC suggests, but does not require, that implementors of rNews populate this field with values drawn from the controlled vocabulary of feature codes provided by geonames.org. TNKD

 

Applying the Location Class
Our sample article contains five locations:
  • Libya
  • France
  • Great Britain
  • United States
  • Turkey
For illustrative purposes we'll also consider two additional locations mentioned in the article.
  • Tripoli
  • White House
To express these concepts in RDF/Turtle using attributes from the rnews Concept and Location classes, we would write the following:
      
        @prefix rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>  .
        @prefix rnews: <http://iptc.org/std/rNews/2011-05-17#> .
      
        <http://data.nytimes.com/66285699086722007041>  
          a  rnews:Location ;
          rnews:point "25.0 17.0" ;
          rnews:name  "Libya" ; 
          rnews:featureCode "PCLI".
          
        <http://data.nytimes.com/67127587134490296321>  
          a  rnews:Location ;
          rnews:point "46.0 2.0" ;
          rnews:name  "France" ; 
          rnews:featureCode "PCLI". 
       
        <http://data.nytimes.com/42273881931420178781>  
          a  rnews:Location ;
          rnews:point "54.0 "-4.0" ;
          rnews:name  "Great Britain" ; 
          rnews:featureCode "PCLI".
           
        <http://data.nytimes.com/N84789043836346105961>  
          a  rnews:Location ;
          rnews:point "39.76 -98.5" ;
          rnews:name "United States" ; 
          rnews:featureCode "PCLI".
           
        <http://data.nytimes.com/55791562732592005121>  
          a  rnews:Location ;
          rnews:point "39.0 35.0" ;
          rnews:name  "Turkey" ; 
          rnews:featureCode "PCLI".
          
        <http://data.nytimes.com/55791562732592005121>  
          a  rnews:Location ;
          rnews:point "39.0 35.0" ;
          rnews:name  "Turkey" ; 
          rnews:featureCode "PCLI".
          
        <http://www.geonames.org/2210247>  
          a  rnews:Location ;
          rnews:point "32.87519 13.18746" ;
          rnews:name  "Tripoli" ;
          rnews:featureCode "PPLC".
          
        <http://www.geonames.org/4140704>  
          a  rnews:Location ;
          rnews:point "38.89761 -77.03637" ;
          rnews:name  "The White House" ;
          rnews:featureCode "BLDG".
      

 

Want to comment on rNews: we invite you to post your comment to the rNews Forum.