use of org.geotools.referencing.crs.DefaultEngineeringCRS in project GeoGig by boundlessgeo.
the class BoundsFilteringDiffConsumer method createProjectedFilter.
private ReferencedEnvelope createProjectedFilter(ObjectId metadataId) {
final ReferencedEnvelope boundsFilter = this.boundsFilter;
RevFeatureType featureType = ftypeSource.getFeatureType(metadataId);
CoordinateReferenceSystem nativeCrs = featureType.type().getCoordinateReferenceSystem();
if (null == nativeCrs || nativeCrs instanceof DefaultEngineeringCRS) {
return boundsFilter;
}
ReferencedEnvelope transformedFilter;
try {
transformedFilter = boundsFilter.transform(nativeCrs, true);
} catch (TransformException | FactoryException e) {
throw Throwables.propagate(e);
}
return transformedFilter;
}
Aggregations