On 10 May 2011, at 13:52, Andrea Aime wrote:

> On Tue, May 10, 2011 at 11:54 AM, Nicolas Malleson
> <[email protected]> wrote:
>> Can I just check, if you do "GridFormatFinder.getAvailableFormats()" do you 
>> also get an empty list?
> 
> If I run that code from within the arcgrid module I get this:
> 
> [org.geotools.gce.arcgrid.ArcGridFormatFactory@1386000]
> 
> If instead I run it from the gt-example module I get:
> 
> [org.geotools.gce.image.WorldImageFormatFactory@7bd9f2,
> org.geotools.gce.geotiff.GeoTiffFormatFactorySpi@eb7859]
> 
> My guess is that your classpath is not complete. Are you using maven
> to build your project?
> Manual configuration of the classpath may be painful.

This is interesting, it sounds like I have the wrong module configuration. I am 
using Maven (following the NetBeans getting started tutorial) and my pom.xml is 
below. These are the modules I'm currently importing: gt-swing, gt-epsg-hsql, 
gt-coverage, gt-geotiff, gt-image, gt-wms

I assume that the arcgrid module is part of gt-coverage? Or do I need to add an 
additional module?

Thanks,
Nick


***** pom.xml *******


<project xmlns="http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/maven-v4_0_0.xsd";>
   <modelVersion>4.0.0</modelVersion>
   <groupId>org.geotools</groupId>
   <artifactId>SpatialAnalysis</artifactId>
   <packaging>jar</packaging>
   <version>1.0-SNAPSHOT</version>
   <name>SpatialAnalysis</name>
   <url>http://maven.apache.org</url>

   <properties>
      <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
      <geotools.version>8.0-M0</geotools.version>
   </properties>

   <dependencies>
      <dependency>
         <groupId>junit</groupId>
         <artifactId>junit</artifactId>
         <version>3.8.1</version>
         <scope>test</scope>
      </dependency>

      <!-- Basic geotools depends -->
      <dependency>
         <groupId>org.geotools</groupId>
         <artifactId>gt-shapefile</artifactId>
         <version>${geotools.version}</version>
      </dependency>
      <dependency>
         <groupId>org.geotools</groupId>
         <artifactId>gt-swing</artifactId>
         <version>${geotools.version}</version>
      </dependency>


   <!-- For reading / writing shapefiles -->
      <dependency>
         <groupId>org.geotools</groupId>
         <artifactId>gt-epsg-hsql</artifactId>
         <version>${geotools.version}</version>
      </dependency>

        <!-- For reading raster -->
        <dependency>
         <groupId>org.geotools</groupId>
         <artifactId>gt-coverage</artifactId>
         <version>${geotools.version}</version>
      </dependency>

      
      <dependency>
         <groupId>org.geotools</groupId>
         <artifactId>gt-geotiff</artifactId>
         <version>${geotools.version}</version>
      </dependency>
      <dependency>
         <groupId>org.geotools</groupId>
         <artifactId>gt-image</artifactId>
         <version>${geotools.version}</version>
      </dependency>
      
      
      
      <!-- Not sure what this is for -->
      <dependency>
         <groupId>org.geotools</groupId>
         <artifactId>gt-wms</artifactId>
         <version>${geotools.version}</version>
      </dependency>


   </dependencies>


   <repositories>
      <repository>
         <id>maven2-repository.dev.java.net</id>
         <name>Java.net repository</name>
         <url>http://download.java.net/maven/2</url>
      </repository>
      <repository>
         <id>osgeo</id>
         <name>Open Source Geospatial Foundation Repository</name>
         <url>http://download.osgeo.org/webdav/geotools/</url>
      </repository>
   </repositories>


   <build>
      <plugins>
         <!-- To use Java 1.6 -->
         <plugin>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>2.3.2</version>
            <configuration>
               <source>1.6</source>
               <target>1.6</target>
            </configuration>
         </plugin>
      </plugins>
   </build>


</project>

***** END pom.xml *******



------------------------------------------------------------------------------
Achieve unprecedented app performance and reliability
What every C/C++ and Fortran developer should know.
Learn how Intel has extended the reach of its next-generation tools
to help boost performance applications - inlcuding clusters.
http://p.sf.net/sfu/intel-dev2devmay
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to