The data sources are defined as ATOM feed entries in an ATOM feed xml file put in the root of ODAF.Website.

The important items are the <title />, <link /> and <id /> tags for the client apps.
<title> is where you define the title of the data source, such as "Libraries".
<link> is where you define the datasources with the "rel" attribute as "enclosure", "type" as the mime-type of the datasource, and "href" is the location of where to retrieve the data in that mime-type. A <link rel="enclosure" type="image/png" href="imagefile" /> is considered by the client apps as the 'icon' to use for the datasource, and used for the pin on the map. The "href" value is relative to the root of the web app site.
<id> is the GUID that uniquely identifies the datasource (this is the value in the PointDataLayer table in the database also).

PointSources.xml
This is an ATOM feed that lists the point data sources that are to be mapped in the client apps. For example, a data source could be placemarks for schools in KML or CSV format. Note that ODAF.SilverlightApp and ODAF.iPhoneApp can only handle KML sources.

RegionSources.xml
This is an ATOM feed that lists the region data sources that are to be mapped in the client apps. For example, a data source could be local boundary data for a city. Note that ODAF.SilverlightApp and ODAF.iPhoneApp can only handle KML sources, and only ODAF.SilverlightApp handles this feed.

CommunitySources.xml
This is an ATOM feed that lists the community sources available from our database, like landmarks added by users. Note that ODAF.SilverlightApp and ODAF.iPhoneApp can only handle JSON sources (which output arrays of PointDataSummary records). The results can be paged - note the %d in the source urls. To fix the page and pagesize, just replace the %d values by the appropriate numbers. Order of parameters is important - page must appear before pagesize.

Important Note:
The database record for the landmarks are lazily created, that is, they do not exist until the very first rating, comment, or tag is created for it.
See Lazy Create of Landmark Data for further details.

Last edited Mar 16, 2010 at 6:51 PM by Shazron, version 4

Comments

No comments yet.