初めてMavenを使用しています。私は、一見よく文書化された「はじめに」ページがある「GeoTools」( http://www.geotools.org/ )を構築しようとしています。NetBeans 7.3.1 を使用しています。プロジェクトをビルドすると、「ビルドの失敗」が表示されます。
Failed to execute goal on project tutorial: Could not resolve dependencies for project org.geotools:tutorial:jar:0.0.1-SNAPSHOT: The following artifacts could not be resolved: org.geotools:gt-shapefile:jar:10-SNAPSHOT, org.geotools:gt-swing:jar:10-SNAPSHOT: Failure to find org.geotools:gt-shapefile:jar:10-SNAPSHOT in http://download.java.net/maven/2 was cached in the local repository, resolution will not be reattempted until the update interval of maven2-repository.dev.java.net has elapsed or updates are forced -> [Help 1]
To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.
それが何を意味するのかよくわかりません。私のコードには、存在しないと見なされるインポートがいくつかありますが、pom.xml の指示に従って手紙を書きました。例えば:
import org.geotools.data.FileDataStore;
上記には、次のようなエラーのある読み取りの下線があります。
package org.geotools.data does not exist
これが私の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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.geotools</groupId>
<artifactId>tutorial</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>tutorial</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<geotools.version>10-SNAPSHOT</geotools.version>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
<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>
</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>
このツールを実行するためのアドバイスをくれる人はいますか? 基本的な Maven エラーを起こしているのでしょうか、それともツール固有のものでしょうか? JAR は「依存関係」の下に表示されるので、なぜ問題があるのかわかりません。
前もって感謝します。