Skip to end of metadata
Go to start of metadata

The following is needed when upgrading to 2.3:

Transition to FeatureCollection

FeatureResults was deprecated for the 2.1 release, and it is passing out
of existence for 2.3. All methods were deprecated and their
replacements documented.

Before (GeoTools 2.1 Code)

Quick Alternative (GeoTools 2.3 Code)

  1. Search and replace:
    • search: FeatureResults replace: FeatureCollection
  2. Transition to:
    • results.size(); // was results.getCount()
    • results; // was results.collection()
    • FeatureIterator // was FeatureReader
    • results.features() // was results.reader()

You may need to remove IOException handling code.

Recommended Alternative (GeoTools 2.x Code)

You can also transition directly to use of java.util.Iterator; this will put you in better standing for the transition to GeoAPI FeatureCollection.

  1. Transition to Iterator
    • (Feature); // was;
    • results.close( reader ); // was reader.close();

Transition to GridCoverageRenderer

It seems we did not meet our guidlines here and the GridCoveargeAPI has been moved and completly changed!

BEFORE (GeoTools 2.2 code)

AFTER (GeoTools 2.3 code)

  • No labels