Problems with some "sos4R" commands

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Problems with some "sos4R" commands

Aniruddha Mukherjee

Hello Members,

I was executing commands from the "cheat-sheet" to learn sos4R.. Please look into the following :-
> mySOS
Object of class SOS_1.0.0 [ POST ,  http://v-swe.uni-muenster.de:8080/WeatherSOS/sos ,  IFGI WeatherSOS

> myOffering <- sosOfferings(mySOS)[[1]]
> myOffering
Object of class SosObservationOffering;  id:  RAIN_GAUGE , name:  Rain
        time:  GmlTimePeriod: [ GmlTimePosition [ time: 2008-11-20 15:35:22 ]
                --> GmlTimePosition [ time: 2011-08-17 11:46:00 ] ]
        procedure(s):  urn:ogc:object:feature:OSIRIS-HWS:2f673b97-c7ce-48df-b2d2-10b4ecf0cf85, urn:ogc:object:feature:OSIRIS-HWS:302ab595-5840-41b1-a11b-a0cb14fc3df4, urn:ogc:object:feature:OSIRIS-HWS:33df75fe-1f7c-4ed3-8062-01d49a134257, urn:ogc:object:feature:OSIRIS-HWS:3d3b239f-7696-4864-9d07-15447eae2b93, urn:ogc:object:feature:OSIRIS-HWS:4fdde076-8080-43b0-9efa-4e3efd4fcc8e, urn:ogc:object:feature:OSIRIS-HWS:55f02637-e61f-41f4-b1d3-452816197ee5, urn:ogc:object:feature:OSIRIS-HWS:75e85e64-2d9f-48a9-90c6-8f0008c74ff4, urn:ogc:object:feature:OSIRIS-HWS:b3f0384c-6aa8-48e5-9dda-d537029b7a95, urn:ogc:object:feature:OSIRIS-HWS:b4b9d260-f238-456a-b5cb-ca9dc0564601, urn:ogc:object:feature:OSIRIS-HWS:efeb807b-bd24-4128-a920-f6729bcdd111
        observedProperty(s):  urn:x-ogc:def:property:OGC::Precipitation1Hour, urn:ogc:def:property:OGC::Precipitation1Hour
        feature(s)OfInterest:  urn:ogc:object:feature:OSIRIS-HWS:3d3b239f-7696-4864-9d07-15447eae2b93, urn:ogc:object:feature:OSIRIS-HWS:efeb807b-bd24-4128-a920-f6729bcdd111
        responseFormat(s):  text/xml;subtype="om/1.0.0", application/zip , responseMode(s):  inline, resultTemplate
        intendedApplication:  NA
        resultModel(s):  ns:Measurement, ns:Observation
        boundedBy:  urn:ogc:def:crs:EPSG:4326, 46.611644 7.6103, 51.9412 13.883498
>

Then I tried sosResponseFormats as follows, but that resulted in an error (given below) :
> sosResponseFormats({mySOS, myOffering})
Error: unexpected ',' in "sosResponseFormats({mySOS,"

However, following kind of worked (please go thru) :
> sosResponseFormats(myOffering)
           responseFormat                  responseFormat
"text/xml;subtype=\"om/1.0.0\""               "application/zip"
>
> sosResponseFormats(mySOS)
$GetCapabilities
NULL

$GetObservation
$GetObservation[[1]]
[1] "text/xml;subtype=\"om/1.0.0\""

$GetObservation[[2]]
[1] "application/zip"

$DescribeSensor
NULL

$GetFeatureOfInterest
NULL

$RegisterSensor
NULL

$InsertObservation
NULL

$GetFeatureOfInterestTime
NULL

$GetObservationById
$GetObservationById[[1]]
[1] "text/xml;subtype=\"om/1.0.0\""

$GetObservationById[[2]]
[1] "application/zip"

$GetResult
NULL

$DescribeFeatureOfInterest
NULL

Similarly, sosResponseMode, sosResultModels did not work as stated in the "Cheat-sheet";

And also these three commands
> sosProcedures({mySOS, myOffering, sosOfferings(mySOS)})
> sosObservedProperties({mySOS, myOffering, sosOfferings(mySOS)})
> sosFeaturesOfInterest({mySOS, myOffering, sosOfferings(mySOS)})
did not work.

Please advise, what is the correct way to use sosResponseFormats (and also sosResponseMode, sosResultModels)
and for the sosProcedures, sosObservedProperties & sosFeaturesOfInterest.

- Anirud -

Aniruddha Mukherjee
Tata Consultancy Services
Ph:- +91 33 6636 7215
Cell:- +91 983 029 4353
____________________________________________
=====-----=====-----=====
Notice: The information contained in this e-mail
message and/or attachments to it may contain
confidential or privileged information. If you are
not the intended recipient, any dissemination, use,
review, distribution, printing or copying of the
information contained in this e-mail message
and/or attachments to it are strictly prohibited. If
you have received this communication in error,
please notify us by reply e-mail or telephone and
immediately and permanently delete the message
and any attachments. Thank you



_______________________________________________
Geostatistics mailing list
[hidden email]
http://list.52north.org/mailman/listinfo/geostatistics
http://geostatistics.forum.52north.org
Reply | Threaded
Open this post in threaded view
|

Re: Problems with some "sos4R" commands

Daniel Nüst - 52N
Administrator
Hello Anirud!

Thanks for pointing out an obvious shortcoming of the cheat sheet - it
is too short! I will explain the usage of the {}-brackets in the next
version. Find my answers inline.

Am 19.08.2011 13:46, schrieb Aniruddha Mukherjee:
> Then I tried *sosResponseFormats* as follows, but that resulted in an
> error (given below) :
>> sosResponseFormats({mySOS, myOffering})

The { is suppossed to depict different options of input for the methods.
In that case both of the following calls:

sosResponseFormats(mySOS)
sosResponseFormats(myOffering)

The same applies for all other occurences of { and }.

> However, following kind of worked (please go thru) :
>> sosResponseFormats(myOffering)

Yes, you found the solution.

I hoped that syntax would be relatively obvious, as the code is not
valid R code, too. But I will clarifiy that in the next release.

Best,
Daniel


--
Daniel Nüst
52° North Initiative for Geospatial Open Source Software GmbH
Martin-Luther-King-Weg 24
48155 Münster, Germany
E-Mail: [hidden email]
Fon: +49-(0)-251–396371-0
Fax: +49-(0)-251–396371-11
http://52north.org/
General Managers: Dr. Albert Remke, Dr. Andreas Wytzisk
Local Court Muenster HRB 10849
_______________________________________________
Geostatistics mailing list
[hidden email]
http://list.52north.org/mailman/listinfo/geostatistics
http://geostatistics.forum.52north.org