use of org.geotoolkit.ogc.xml.v100.UnaryLogicOpType in project ddf by codice.
the class WfsFilterDelegateTest method testDwithinAsNotBeyond.
@Test
public void testDwithinAsNotBeyond() {
WfsFilterDelegate delegate = setupFilterDelegate(SPATIAL_OPERATORS.BEYOND.getValue(), new LatLonCoordinateStrategy());
FilterType filter = delegate.dwithin(Metacard.ANY_GEO, POLYGON, DISTANCE);
assertThat(filter.getLogicOps().getValue(), is(instanceOf(UnaryLogicOpType.class)));
UnaryLogicOpType type = (UnaryLogicOpType) filter.getLogicOps().getValue();
assertThat(type.getSpatialOps().getValue(), is(instanceOf(DistanceBufferType.class)));
}
use of org.geotoolkit.ogc.xml.v100.UnaryLogicOpType in project ddf by codice.
the class WfsFilterDelegateTest method testIntersectsAsNotDisjoint.
@Test
public void testIntersectsAsNotDisjoint() {
WfsFilterDelegate delegate = setupFilterDelegate(SPATIAL_OPERATORS.DISJOINT.getValue(), new LatLonCoordinateStrategy());
FilterType filter = delegate.intersects(Metacard.ANY_GEO, POLYGON);
assertThat(filter.isSetLogicOps(), is(true));
assertThat(filter.getLogicOps().getValue(), is(instanceOf(UnaryLogicOpType.class)));
UnaryLogicOpType type = (UnaryLogicOpType) filter.getLogicOps().getValue();
assertThat(type.isSetSpatialOps(), is(true));
assertThat(type.getSpatialOps().getValue(), is(instanceOf(BinarySpatialOpType.class)));
}
use of org.geotoolkit.ogc.xml.v100.UnaryLogicOpType in project ddf by codice.
the class WfsFilterDelegateTest method testBeyondAsNotDwithin.
@Test
public void testBeyondAsNotDwithin() {
WfsFilterDelegate delegate = setupFilterDelegate(SPATIAL_OPERATORS.DWITHIN.getValue(), new LatLonCoordinateStrategy());
FilterType filter = delegate.beyond(Metacard.ANY_GEO, POLYGON, DISTANCE);
assertThat(filter.getLogicOps().getValue(), is(instanceOf(UnaryLogicOpType.class)));
UnaryLogicOpType type = (UnaryLogicOpType) filter.getLogicOps().getValue();
assertThat(type.getSpatialOps().getValue(), is(instanceOf(DistanceBufferType.class)));
}
use of org.geotoolkit.ogc.xml.v100.UnaryLogicOpType in project ddf by codice.
the class TestCswFilterDelegate method testPropertyIsLikeNot.
@Test
public void testPropertyIsLikeNot() throws JAXBException, SAXException, IOException {
FilterType propertyIsLikeFilter = cswFilterDelegateLatLon.propertyIsLike(propertyName, likeLiteral, isCaseSensitive);
FilterType filter = cswFilterDelegateLatLon.not(propertyIsLikeFilter);
assertThat(filter, notNullValue());
assertThat(filter.getLogicOps().getName(), is(NOT_LOGIC_OPS_NAME));
UnaryLogicOpType ulot = (UnaryLogicOpType) filter.getLogicOps().getValue();
assertThat(ulot, notNullValue());
}
use of org.geotoolkit.ogc.xml.v100.UnaryLogicOpType in project ddf by codice.
the class TestWfsFilterDelegate method testBeyondAsNotDwithin.
@Test
public void testBeyondAsNotDwithin() {
WfsFilterDelegate delegate = setupFilterDelegate(SPATIAL_OPERATORS.DWithin.toString());
FilterType filter = delegate.beyond(Metacard.ANY_GEO, POLYGON, DISTANCE);
assertTrue(filter.getLogicOps().getValue() instanceof UnaryLogicOpType);
UnaryLogicOpType type = (UnaryLogicOpType) filter.getLogicOps().getValue();
assertTrue(type.getSpatialOps().getValue() instanceof DistanceBufferType);
}
Aggregations