@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix nrl: <http://www.semanticdesktop.org/ontologies/2007/08/15/nrl#> .
@prefix nie: <http://www.semanticdesktop.org/ontologies/2007/01/19/nie#> .
@prefix nco: <http://www.semanticdesktop.org/ontologies/2007/03/22/nco#> .
@prefix mlo: <http://www.tracker-project.org/temp/mlo#> .
@prefix tracker: <http://www.tracker-project.org/ontologies/tracker#> .
@prefix nao: <http://www.semanticdesktop.org/ontologies/2007/08/15/nao#> .

mlo: a tracker:Namespace, tracker:Ontology ;
    tracker:prefix "mlo" ;
    nao:lastModified "2010-02-16T11:00:00Z" .

mlo:GeoLocation a rdfs:Class ;
    rdfs:label "Location" ;
    rdfs:comment "A place in the space, can be defined by coordinates, text or box";
    rdfs:subClassOf nie:InformationElement.

mlo:GeoPoint a rdfs:Class ;
    rdfs:label "Point on the earth" ;
    rdfs:comment "The inherited properties from InformationElement can be used to add details." ;
    rdfs:subClassOf nie:InformationElement .

mlo:GeoSphere a rdfs:Class ;
    rdfs:label "Spherical space" ;
    rdfs:comment "Point and radius to define an area in the space";
    rdfs:subClassOf mlo:GeoPoint .

mlo:GeoBoundingBox a rdfs:Class ;
    rdfs:label "Bounding box";
    rdfs:comment "Bounding box for a region in the space, defined with 2 points in 2D. We assume that the box is always aligned with parallels and meridians.";
    rdfs:subClassOf nie:InformationElement .

mlo:LocationBoundingBox a rdfs:Class ;
    rdfs:label "Box containing a relevant location (places that cannot be described in one concrete point)" ;
    nao:deprecated true ;
    rdfs:subClassOf mlo:GeoBoundingBox .


mlo:Route a rdfs:Class ;
    rdfs:label "Minimum box containing all the points traversed in sequence." ;
    rdfs:subClassOf mlo:GeoBoundingBox .


mlo:LandmarkCategory a rdfs:Class ;
    rdfs:label "Landmark category";
    rdfs:comment "Predefined set of instances for categories of landmarks";
    rdfs:subClassOf nie:InformationElement.

mlo:isRemovable a rdf:Property ;
    rdfs:label "Is removable";
    rdfs:comment "Flag to indicate if this instance is removable. This restriction is not enforced by tracker; it is API responsability to honor the value";
    rdfs:domain mlo:LandmarkCategory ;
    rdfs:range xsd:boolean.



mlo:Landmark a rdfs:Class ;
    rdfs:label "Point with special relevance for the user" ;
    rdfs:subClassOf nie:InformationElement ;
    rdfs:comment "Use the nie title, description, ... properties" .

mlo:PointOfInterest a rdfs:Class ;
    rdfs:label "Use mlo:Landmark instead" ;
    rdfs:subClassOf mlo:Landmark ;
    nao:deprecated true ;
    rdfs:comment "Use the nie title, description, ...  properties".

mlo:belongsToCategory a rdf:Property ;
    rdfs:label "Belongs to category";
    rdfs:comment "Relation of a landmark with a landmark category";
    rdfs:domain mlo:Landmark ;
    rdfs:range mlo:LandmarkCategory .





#Properties of GeoPoint
mlo:latitude a rdf:Property ;
    rdfs:label "Latitude";
    rdfs:comment "Positive values for the north hemisphere, negative for the south" ;
    rdfs:domain mlo:GeoPoint ;
    rdfs:range  xsd:double .

mlo:longitude a rdf:Property ;
    rdfs:label "Longitude" ;
    rdfs:comment "Positive to the East of the Greenwich meridian, negative to the West (following WGS-84)" ;
    rdfs:domain mlo:GeoPoint ;
    rdfs:range  xsd:double .

mlo:altitude a rdf:Property ;
    rdfs:label "Altitude" ;
    rdfs:comment "Altitude following WGS 84 reference";
    rdfs:domain mlo:GeoPoint ;
    rdfs:range  xsd:double .

mlo:timestamp a rdf:Property ;
    rdfs:label "Timestamp" ;
    rdfs:comment "Timestamp when the geopoint is referenced. Create subproperties for certain use cases" ;
    rdfs:domain mlo:GeoPoint ;
    rdfs:range xsd:dateTime .

# Properties of LocationBoundingBox
mlo:boxSouthWestCorner a rdf:Property ;
    rdfs:label "South-west corner of the bounding box" ;
    rdfs:domain mlo:LocationBoundingBox ;
    nao:deprecated true ;
    rdfs:range  mlo:GeoPoint.

mlo:boxEastLimit a rdf:Property ;
    rdfs:label "Length of the box in the East direction" ;
    rdfs:domain mlo:LocationBoundingBox ;
    nao:deprecated true ;
    rdfs:range mlo:GeoPoint.

mlo:boxVerticalLimit a rdf:Property ;
    rdfs:label "Length of the box in the Up direction (height)" ;
    rdfs:domain mlo:LocationBoundingBox ;
    nao:deprecated true ;
    rdfs:range mlo:GeoPoint.

mlo:boxNorthLimit a rdf:Property ;
    rdfs:label "Length of the box in the North direction" ;
    rdfs:domain mlo:LocationBoundingBox ;
    nao:deprecated true ;
    rdfs:range mlo:GeoPoint.

mlo:bbNorthWest a rdf:Property ;
    rdfs:label "North west corner";
    rdfs:comment "North west corner of a bounding box. The GeoPoint is interpreted in 2D";
    rdfs:domain mlo:GeoBoundingBox ;
    rdfs:range mlo:GeoPoint . 

mlo:bbSouthEast a rdf:Property ;
    rdfs:label "South east corner";
    rdfs:comment "South east corner of a bounding box. The GeoPoint is interpreted in 2D";
    rdfs:domain mlo:GeoBoundingBox ;
    rdfs:range mlo:GeoPoint . 

# Properties of Route
mlo:startTime a rdf:Property ;
    rdfs:label "Time when the first point in the route was saved" ;
    rdfs:domain mlo:Route ;
    rdfs:range  xsd:dateTime .

mlo:endTime a rdf:Property ;
    rdfs:label "Time when the last point in the route was saved" ;
    rdfs:domain mlo:Route ;
    rdfs:range  xsd:dateTime .

mlo:routeDetails a rdf:Property ;
    rdfs:label "Pointer to a file containing route details (e.g. KML file)." ;
    rdfs:comment "FIXME Domain can be resource if we handle map-files correctly in the ontology";
    rdfs:domain mlo:Route ;
    rdfs:range  xsd:string .

# Properties of GeoSphere
mlo:radius a rdf:Property ;
    rdfs:label "Radius";
    rdfs:comment "Radius from the center to define an area. Some applications can use it in 2D sense, making then a circle instead of a sphere" ;
    rdfs:domain mlo:GeoSphere ;
    rdfs:range xsd:double .


# FIXME Domain rdfs:Resource?? to link files and not only content?
mlo:location a rdf:Property ;
    tracker:writeback true ;
    rdfs:label "Property linking something to a location" ;
    rdfs:comment "This can be subclassed to add semantics" ;
    rdfs:domain nie:InformationElement ;
    rdfs:range mlo:GeoLocation .

# Properties of GeoLocation
mlo:asBoundingBox a rdf:Property ;
    rdfs:label "As bounding box" ;
    rdfs:comment "Representation of the location as bounding box" ;
    rdfs:domain mlo:GeoLocation ;
    rdfs:range mlo:GeoBoundingBox .

mlo:asGeoPoint a rdf:Property ;
    rdfs:label "As geo point" ;
    rdfs:comment "Representation of the location as geo point" ;
    rdfs:domain mlo:GeoLocation ;
    rdfs:range mlo:GeoPoint .

mlo:asPostalAddress a rdf:Property ;
    rdfs:label "As postal address" ;
    rdfs:comment "Representation of the location as text address" ;
    rdfs:domain mlo:GeoLocation ;
    rdfs:range nco:PostalAddress .

# TODO: These are ad-hoc added by Philip to support writeback of locations
mlo:city a rdf:Property ;
    tracker:writeback true ;
    rdfs:label "City" ;
    nao:deprecated true;
    rdfs:domain mlo:GeoPoint ;
    rdfs:range  xsd:string .

mlo:country a rdf:Property ;
    tracker:writeback true ;
    rdfs:label "Country" ;
    nao:deprecated true ;
    rdfs:domain mlo:GeoPoint ;
    rdfs:range  xsd:string .

mlo:state a rdf:Property ;
    tracker:writeback true ;
    rdfs:label "State" ;
    nao:deprecated true ;
    rdfs:domain mlo:GeoPoint ;
    rdfs:range  xsd:string .

mlo:address a rdf:Property ;
    tracker:writeback true ;
    rdfs:label "Address" ;
    nao:deprecated true ;
    rdfs:domain mlo:GeoPoint ;
    rdfs:range  xsd:string .

# Properties of Point of Interest
mlo:poiLocation a rdf:Property ;
    rdfs:label "POI Location" ;
    rdfs:comment "Coordinates of the point (Use the mlo:location property inherited from IE" ;
    nao:deprecated true;
    rdfs:domain mlo:Landmark ;
    rdfs:range mlo:GeoPoint .

###############################################
#  Predefined categories coming from Symbian 
#    - move to a different file?
###############################################

mlo:predefined-landmark-category-accommodation a mlo:LandmarkCategory ;
	mlo:isRemovable false ;
	nie:title "Accommodation";
	nie:description "Hotel, Camping site".

mlo:predefined-landmark-category-business a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Business";
	nie:description "Bank, Factory, Office".

mlo:predefined-landmark-category-communication a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Communication";
	nie:description "Internet Access Point, Public Telephone, Wireless LAN Hot Spot".

mlo:predefined-landmark-category-educational-institute a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Educational institute";
	nie:description "School, College".

mlo:predefined-landmark-category-entertainment a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Entertainment";
	nie:description "Amusement park, Cinema, Concert hall, Night club".

mlo:predefined-landmark-category-food-beverage a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Food & Beverage";
	nie:description "Fast food, Restaurant, Café, Bar".

mlo:predefined-landmark-category-geographical-area a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Geographical area";
	nie:description "City, City center, Town".

mlo:predefined-landmark-category-outdoor-activities a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Outdoor activities";
	nie:description "Camping site, Fishing place, Hunting, National park, Playground".

mlo:predefined-landmark-category-people a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "People";
	nie:description "My home, My friends home, Fathers summer cottage, Childs school".

mlo:predefined-landmark-category-public-service a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Public service";
	nie:description "Tourist information office, Government office, Library, Post office, Hospital, Police ".

mlo:predefined-landmark-category-religious-places a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Religious places";
	nie:description "Church, Mosque".

mlo:predefined-landmark-category-shopping a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Shopping";
	nie:description "Market Place, Pharmacy, Shop, Shopping Center".

mlo:predefined-landmark-category-sightseeing a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Sightseeing";
	nie:description "Monument, Mountain top, Museum".

mlo:predefined-landmark-category-sports a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Sports";
	nie:description "Bowling, Golf course, Ice hockey hall, Stadium".

mlo:predefined-landmark-category-transport a mlo:LandmarkCategory ;
	mlo:isRemovable False ;
	nie:title "Transport";
	nie:description "Airport, Bus stop, Harbour, Railway Station, Rest area".
