NaturLotse ON Paket-Konventionen

Aus Offene Naturführer
Version vom 29. September 2012, 13:24 Uhr von Gregor Hagedorn (Diskussion | Beiträge)

(Diff.) ← Nächstältere Version | Aktuelle Version (Diff.) | Nächstjüngere Version → (Diff.)
Wechseln zu: Navigation, Suche

Struktur von Paketen mit Bestimmungshilfen (in Englisch)

Notes: this is first attempt to collect the requirements for a package to run on the Naturepilot/NaturLotse App. These notes require testing and further refinement when implementing alternative package sources.

1. The package must be available as a zip file.

Recommendation: The zipped folder should not use diacritical characters in folder or file names. These are presently unreliable when unzipping them on various smartphone devices. Zip files are known to be unreliable when used with unicode file names, and we experienced significant problems just with "äüöß". This recommendation may change over time, it is presented here only to clarify that Naturepilot/NaturLotse needs to use the native zip library (attempts to use the Unicode-safe-7zip where unsuccessful)

2. The zip file must contain a single first level folder (plus multiple folders inside). The first level folder must contain at least an index.html (the starting point) in the first level folder and a file mediaXXXXX.xml (TODO describe structure!!!)

3. Images inside the html files may point to files in a second-level "image" folder. However, the actual zip file should not contain a significant number of images. Instead the mediaXXXXX.xml file defines how to separately retrieve images. The app will retrieve the files from the URL given in the xml file, save it into the filenames given in the xml file and place the files in the /images/ folder.

4. The app supports several add-ons to a URL to trigger special actions.

  • if a URL contains a parameter "appcmd-return", as in "http://offene-naturfuehrer.de/web/Mobile_Nutzung_(Online)?appcmd-return" or "http://offene-naturfuehrer.de/web/Mobile_Nutzung_(Online)?x=2&appcmd-return", the App will stop displaying the nature guide and return to the primary panel or view of the App itself. At present the app will cancel the display of the package, i.e. you cannot go back inside the package, but in a future version of the app this is considered a desirable feature.
  • if the URL contains a parameter appcmd-occurrence the app will record the occurrence of a taxon or other object (with GPS coordinates). The appcmd-occurrence parameter is followed by (urlencoded) information about the identification result. Examples:
    • appcmd-occurrence=result text
    • appcmd-occurrence=result text/sn:Hyla_arborea/cn:Laubfrosch,_Quackfrosch
    • appcmd-occurrence=result text/sn:Hyla_arborea/cn:Laubfrosch,_Quackfrosch
    • appcmd-occurrence=result text/sn:Hyla_arborea/cn:Laubfrosch,_Quackfrosch&action=view
    • appcmd-occurrence=result text/sn:Hyla_arborea/cn:Laubfrosch,_Quackfrosch#pos1
    • A regular expression could be: .*appcmd-occurrence=([^#&]+).* where \1 would result in: "result text/sn:Hyla_arborea/cn:Laubfrosch,_Quackfrosch"

TEMPORARY NOTE: At the moment, the test position for testing the appcmd-occurrence is: Heuschreckenschlüssel, erste Option, erste Option, dann auch Bild klicken.


Zugriff auf Metadaten und Download der ON-NaturLotse-Pakete

Zugriff auf alle generierten Pakete ist möglich über einen Webservice als xml: http://offene-naturfuehrer.de/w/index.php?title=Special:TemplateParameterExport&action=submit&do=export&template=MobileKey (alle) oder http://offene-naturfuehrer.de/w/index.php?title=Special:TemplateParameterExport&action=submit&do=export&template=MobileKey&from=2011-01-01T15:00.00 (neue und Änderungen ab einem bestimmten Datum).



Siehe auch Erläuterungen und Hilfe zur Nutzung des NaturLotsen ON

Quelle: Offene Naturführer, Das Wiki zu Bestimmungsfragen: NaturLotse ON Paket-Konventionen (Zuletzt geändert:
Dieses Attribut ist ein Spezialattribut in diesem Wiki.
29 September 2012 12:24:42). Abgerufen am 23. Dezember 2024, 07:37 von https://offene-naturfuehrer.de/web/NaturLotse_ON_Paket-Konventionen