Search in sources :

Example 6 with OperationDecoderKey

use of org.n52.svalbard.decode.OperationDecoderKey in project arctic-sea by 52North.

the class AbstractXmlBindingTest method test_GetObs.

@Test
public void test_GetObs() throws CodedException {
    DecoderKey decoderKey = binding.getDecoderKey(xmlStringGetObs, characterEncoding);
    if (decoderKey instanceof OperationDecoderKey) {
        assertThat(((OperationDecoderKey) decoderKey).getService(), is("SOS"));
        assertThat(((OperationDecoderKey) decoderKey).getVersion(), is("2.0.0"));
        assertThat(((OperationDecoderKey) decoderKey).getOperation(), is("GetObservation"));
    }
}
Also used : OperationDecoderKey(org.n52.svalbard.decode.OperationDecoderKey) XmlNamespaceOperationDecoderKey(org.n52.svalbard.decode.XmlNamespaceOperationDecoderKey) DecoderKey(org.n52.svalbard.decode.DecoderKey) OperationDecoderKey(org.n52.svalbard.decode.OperationDecoderKey) XmlNamespaceOperationDecoderKey(org.n52.svalbard.decode.XmlNamespaceOperationDecoderKey) Test(org.junit.Test)

Example 7 with OperationDecoderKey

use of org.n52.svalbard.decode.OperationDecoderKey in project arctic-sea by 52North.

the class AbstractXmlBindingTest method test_GetCaps.

@Test
public void test_GetCaps() throws CodedException {
    DecoderKey decoderKey = binding.getDecoderKey(xmlStringGetCaps, characterEncoding);
    if (decoderKey instanceof OperationDecoderKey) {
        assertThat(((OperationDecoderKey) decoderKey).getService(), is("SOS"));
        assertThat(((OperationDecoderKey) decoderKey).getOperation(), is("GetCapabilities"));
    }
}
Also used : OperationDecoderKey(org.n52.svalbard.decode.OperationDecoderKey) XmlNamespaceOperationDecoderKey(org.n52.svalbard.decode.XmlNamespaceOperationDecoderKey) DecoderKey(org.n52.svalbard.decode.DecoderKey) OperationDecoderKey(org.n52.svalbard.decode.OperationDecoderKey) XmlNamespaceOperationDecoderKey(org.n52.svalbard.decode.XmlNamespaceOperationDecoderKey) Test(org.junit.Test)

Aggregations

OperationDecoderKey (org.n52.svalbard.decode.OperationDecoderKey)7 DecoderKey (org.n52.svalbard.decode.DecoderKey)4 OwsServiceRequest (org.n52.shetland.ogc.ows.service.OwsServiceRequest)3 JsonNode (com.fasterxml.jackson.databind.JsonNode)2 IOException (java.io.IOException)2 HashSet (java.util.HashSet)2 Test (org.junit.Test)2 OwsDecodingException (org.n52.iceland.coding.decode.OwsDecodingException)2 XmlNamespaceDecoderKey (org.n52.svalbard.decode.XmlNamespaceDecoderKey)2 XmlNamespaceOperationDecoderKey (org.n52.svalbard.decode.XmlNamespaceOperationDecoderKey)2 XmlStringOperationDecoderKey (org.n52.svalbard.decode.XmlStringOperationDecoderKey)2 DecodingException (org.n52.svalbard.decode.exception.DecodingException)2 Strings (com.google.common.base.Strings)1 Collections (java.util.Collections)1 Locale (java.util.Locale)1 Map (java.util.Map)1 Set (java.util.Set)1 Collector (java.util.stream.Collector)1 Collectors.toMap (java.util.stream.Collectors.toMap)1 HttpServletRequest (javax.servlet.http.HttpServletRequest)1