From d4ffb13e0ecb15716e6a21f624564f4055103b0b Mon Sep 17 00:00:00 2001 From: CarstenHollmann Date: Thu, 17 Sep 2015 16:06:16 +0200 Subject: [PATCH] This fix #321 - Add check if parameter is OM_SpatialObservation samplingGeometry. If so, do not throw the not supported exception. --- .../n52/sos/ds/hibernate/dao/AbstractObservationDAO.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/hibernate/common/src/main/java/org/n52/sos/ds/hibernate/dao/AbstractObservationDAO.java b/hibernate/common/src/main/java/org/n52/sos/ds/hibernate/dao/AbstractObservationDAO.java index 9a2ab3084c..265cb3028d 100644 --- a/hibernate/common/src/main/java/org/n52/sos/ds/hibernate/dao/AbstractObservationDAO.java +++ b/hibernate/common/src/main/java/org/n52/sos/ds/hibernate/dao/AbstractObservationDAO.java @@ -31,7 +31,6 @@ import java.sql.Timestamp; import java.util.Collection; import java.util.Date; -import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Set; @@ -728,8 +727,12 @@ protected void finalizeObservationInsertion(OmObservation sosObservation, Abstra */ protected void insertParameter(Collection> parameter, AbstractObservation observation, Session session) throws OwsExceptionReport { - throw new OptionNotSupportedException().at("om:parameter").withMessage( - "The om:parameter support is not yet implemented!"); + for (NamedValue namedValue : parameter) { + if (!Sos2Constants.HREF_PARAMETER_SPATIAL_FILTERING_PROFILE.equals(namedValue.getName().getHref())) { + throw new OptionNotSupportedException().at("om:parameter").withMessage( + "The om:parameter support is not yet implemented!"); + } + } } /**