【发布时间】:2016-03-12 05:44:15
【问题描述】:
我想将hibernate-spatial 和postgis 添加到我的Maven 项目中。
这是我的pom.xml:
<properties>
<hibernate.version>4.3.6.Final</hibernate.version>
<hibernate.spatial.version>4.3</hibernate.spatial.version>
<hibernate.core.version>4.3.6.Final</hibernate.core.version>
<postgis-jdbc.version>2.2.0</postgis-jdbc.version>
</properties>
...
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-core</artifactId>
<version>${hibernate.core.version}</version>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-entitymanager</artifactId>
<version>${hibernate-entitymanager.version}</version>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-spatial</artifactId>
<version>${hibernate.spatial.version}</version>
</dependency>
<dependency>
<groupId>org.postgis</groupId>
<artifactId>postgis-jdbc</artifactId>
<version>${postgis-jdbc.version}</version>
</dependency>
对entity-manager 和hibernate-core 的引用有效。但是找不到hibernate-spatial 和postgis-jdbc:
org.hibernate:hibernate-spatial:4.3 not found 检查 Maven 模型 解决问题。
(postgis-jdbc 的错误相同)
如何在我的项目中包含这些库?
【问题讨论】:
标签: java hibernate maven pom.xml spatial