skrueger.geotools
Class GeomFilterGenerator.BoundingBoxFilterGenerator

java.lang.Object
  extended by skrueger.geotools.GeomFilterGenerator
      extended by skrueger.geotools.GeomFilterGenerator.BoundingBoxFilterGenerator
Enclosing class:
GeomFilterGenerator

public static class GeomFilterGenerator.BoundingBoxFilterGenerator
extends GeomFilterGenerator

GeomFilterGenerator for a bounding box constraint.

Author:
Martin Schmitz

Nested Class Summary
 
Nested classes/interfaces inherited from class skrueger.geotools.GeomFilterGenerator
GeomFilterGenerator.BoundingBoxFilterGenerator, GeomFilterGenerator.PointFilterGenerator
 
Field Summary
protected  Envelope baseEnv
          Holds the base constraint (bounding box Envelope) relative to the base CRS.
 
Fields inherited from class skrueger.geotools.GeomFilterGenerator
baseCRS
 
Constructor Summary
GeomFilterGenerator.BoundingBoxFilterGenerator(Envelope baseEnv, CoordinateReferenceSystem baseCrs)
          Creates a new filter generator.
 
Method Summary
protected  GeometryFilterImpl prepareFilter(CoordinateReferenceSystem crs, Class<?> geomClass)
          Prepares a filter with the bounding box transformed to the given CoordinateReferenceSystem as the "right" argument.
 
Methods inherited from class skrueger.geotools.GeomFilterGenerator
adaptFilter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

baseEnv

protected Envelope baseEnv
Holds the base constraint (bounding box Envelope) relative to the base CRS.

Constructor Detail

GeomFilterGenerator.BoundingBoxFilterGenerator

public GeomFilterGenerator.BoundingBoxFilterGenerator(Envelope baseEnv,
                                                      CoordinateReferenceSystem baseCrs)
Creates a new filter generator.

Parameters:
baseEnv - defines the bounding box
baseCrs - defines the CRS of the bounding box
Method Detail

prepareFilter

protected GeometryFilterImpl prepareFilter(CoordinateReferenceSystem crs,
                                           Class<?> geomClass)
Prepares a filter with the bounding box transformed to the given CoordinateReferenceSystem as the "right" argument.

Specified by:
prepareFilter in class GeomFilterGenerator
Parameters:
crs - the CoordinateReferenceSystem the bounding box is transformed to * @param Class the geometry class we are testing against. For point against polygon for example, an intersects is much faster that the bbox filter