David Adler wrote:
> I installed Maven 2.0.4 and managed (I think) to get a successful build.
>
> Now I trying to migrate my GeoTools 2.1 sample application that does a
> simple BBOX spatial query but it appears that there has been considerable
> restructuring in GT 2.2. Are there GT 2.2 examples somewhere that are
> similar to the 2.1 examples?
>
Are you on GeoTools 2.2.x or trunk?
> The following is what I am using in 2.1:
>
> FeatureSource fsCounties =
> db2Store.getFeatureSource("COUNTIES");
> FeatureType ft = fsCounties.getSchema();
>
> FilterFactory ff = FilterFactory.createFilterFactory();
> GeometryFilter gf =
> ff.createGeometryFilter(AbstractFilter.GEOMETRY_BBOX);
> LiteralExpression envelope = ff.createBBoxExpression(new
> Envelope(-76.0,-74.0,41.0,42.0));
> AttributeExpression spatialColumn =
> ff.createAttributeExpression(ft,"SHAPE");
> gf.addLeftGeometry(spatialColumn);
> gf.addRightGeometry(envelope);
>
> It looks like the Expression classes have moved to
> org.geotools.filter.expression.
>
> It isn't clear what is going on with FilterFactory and org.opengis.filter
> vs org.geotools.filter.
>
>
It really sounds like you are on trunk, we have migrated to the GeoAPI
filter interfaces, for GeoTools 2.2.x we cleaned up the use of
FilterFactory (it was an abstract class rather then an interface) and
introduced FilterFactoryFinder as per the devleopers guide.
> Is there any documentation for getting started other than diving into the
> JavaDocs?
>
Yes there are some notes for migration, links available from the Home
page. Please add to these pages :-)
- http://docs.codehaus.org/display/GEOTOOLS/2.2.x
-
http://docs.codehaus.org/display/GEOTOOLS/Transitioning+from+2.2.x+to+2.3.x
Cheers,
Jody
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users