@Autowired
private DtoConverterService dtoConverter;
@Test
public void testSplitPolygon() throws Exception {
SplitPolygonRequest request = new SplitPolygonRequest();
GeometryFactory factory = new GeometryFactory();
request.setGeometry(
dtoConverter.toDto(geoService.createCircle(factory.createPoint(new Coordinate(0, 0)), 10, 10)));
request.setSplitter(
dtoConverter.toDto(factory.createLineString(new Coordinate[] {
new Coordinate(-10, -10), new Coordinate(10, 10)
})));
SplitPolygonResponse response = (SplitPolygonResponse) dispatcher.execute(
SplitPolygonRequest.COMMAND, request, null, "en");