初始化
This commit is contained in:
parent
973326ae5c
commit
eddd4ce40f
49
pom.xml
49
pom.xml
@ -50,7 +50,7 @@
|
|||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<spring.version>4.2.4.RELEASE</spring.version>
|
<spring.version>4.3.6.RELEASE</spring.version>
|
||||||
<mybatis.version>3.3.1</mybatis.version>
|
<mybatis.version>3.3.1</mybatis.version>
|
||||||
<slf4j.version>1.7.18</slf4j.version>
|
<slf4j.version>1.7.18</slf4j.version>
|
||||||
<log4j.version>1.2.16</log4j.version>
|
<log4j.version>1.2.16</log4j.version>
|
||||||
@ -63,20 +63,55 @@
|
|||||||
<artifactId>guava</artifactId>
|
<artifactId>guava</artifactId>
|
||||||
<version>23.0</version>
|
<version>23.0</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>net.sf.json-lib</groupId>
|
||||||
|
<artifactId>json-lib</artifactId>
|
||||||
|
<version>2.4</version>
|
||||||
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.mybatis</groupId>
|
<groupId>org.mybatis</groupId>
|
||||||
<artifactId>mybatis</artifactId>
|
<artifactId>mybatis</artifactId>
|
||||||
<version>${mybatis.version}</version>
|
<version>${mybatis.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.postgresql</groupId>
|
<groupId>org.springframework</groupId>
|
||||||
<artifactId>postgresql</artifactId>
|
<artifactId>spring-beans</artifactId>
|
||||||
<version>42.1.0</version>
|
<version>${spring.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>net.sf.json-lib</groupId>
|
<groupId>org.springframework</groupId>
|
||||||
<artifactId>json-lib</artifactId>
|
<artifactId>spring-web</artifactId>
|
||||||
<version>2.4</version>
|
<version>${spring.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-oxm</artifactId>
|
||||||
|
<version>${spring.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-tx</artifactId>
|
||||||
|
<version>${spring.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-jdbc</artifactId>
|
||||||
|
<version>${spring.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-aop</artifactId>
|
||||||
|
<version>${spring.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-context-support</artifactId>
|
||||||
|
<version>${spring.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-test</artifactId>
|
||||||
|
<version>${spring.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.geotools</groupId>
|
<groupId>org.geotools</groupId>
|
||||||
|
|||||||
17
src/main/java/com/gis3c/spatial/App.java
Normal file
17
src/main/java/com/gis3c/spatial/App.java
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
package com.gis3c.spatial;
|
||||||
|
|
||||||
|
import org.springframework.context.ApplicationContext;
|
||||||
|
import org.springframework.context.support.ClassPathXmlApplicationContext;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by hukekuan on 2017/12/14.
|
||||||
|
*/
|
||||||
|
public class App {
|
||||||
|
public static ApplicationContext ApplicationInit(){
|
||||||
|
return new ClassPathXmlApplicationContext("classpath:spring-config.xml");
|
||||||
|
}
|
||||||
|
public static void main(String[] args) {
|
||||||
|
ApplicationContext context = ApplicationInit();
|
||||||
|
System.out.println("OK");
|
||||||
|
}
|
||||||
|
}
|
||||||
135
src/main/resources/init.sql
Normal file
135
src/main/resources/init.sql
Normal file
@ -0,0 +1,135 @@
|
|||||||
|
--地图表
|
||||||
|
create table c3gis_ol_map(
|
||||||
|
mapid varchar(50) not null PRIMARY KEY,
|
||||||
|
mapname varchar(50) not null,
|
||||||
|
view varchar(50) not null,
|
||||||
|
controls varchar(50) ARRAY,
|
||||||
|
pixelRatio integer,
|
||||||
|
interactions varchar(50) ARRAY,,
|
||||||
|
layers varchar(50) ARRAY,
|
||||||
|
logo boolean,
|
||||||
|
overlays varchar(50) ARRAY,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
--样式类型枚举值
|
||||||
|
CREATE TYPE c3gis_ol_vectorstyletype AS ENUM('entity', 'function');
|
||||||
|
|
||||||
|
|
||||||
|
--矢量图层表
|
||||||
|
create table c3gis_ol_layer_vector(
|
||||||
|
layerid varchar(50) not null PRIMARY KEY,
|
||||||
|
layername varchar(50) not null,
|
||||||
|
opacity real,
|
||||||
|
visible boolean,
|
||||||
|
extent decimal ARRAY[4],
|
||||||
|
zIndex integer,
|
||||||
|
minResolution decimal,
|
||||||
|
maxResolution decimal,
|
||||||
|
|
||||||
|
source varchar(50) not null,
|
||||||
|
styletype c3gis_ol_vectorstyletype not null,,
|
||||||
|
stylevalue varchar(50) not null,
|
||||||
|
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
--切片图层表
|
||||||
|
create table c3gis_ol_layer_tile(
|
||||||
|
layerid varchar(50) not null PRIMARY KEY,
|
||||||
|
layername varchar(50) not null,
|
||||||
|
opacity real,
|
||||||
|
visible boolean,
|
||||||
|
extent decimal ARRAY[4],
|
||||||
|
minResolution decimal,
|
||||||
|
maxResolution decimal,
|
||||||
|
source varchar(50) not null,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--ArcGIS切片服务
|
||||||
|
create table c3gis_ol_source_tilearcgisrest(
|
||||||
|
sourceid varchar(50) not null PRIMARY KEY,
|
||||||
|
sourcename varchar(50) not null,
|
||||||
|
crossOrigin varchar(50),
|
||||||
|
projection varchar(20),
|
||||||
|
url varchar(100) not null,
|
||||||
|
wrapX boolean,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--SuperMap切片服务
|
||||||
|
create table c3gis_ol_source_tilesupermaprest(
|
||||||
|
sourceid varchar(50) not null PRIMARY KEY,
|
||||||
|
sourcename varchar(50) not null,
|
||||||
|
url varchar(100) not null,
|
||||||
|
wrapX boolean,
|
||||||
|
opaque boolean,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--矢量数据
|
||||||
|
create table c3gis_ol_source_tilearcgisrest(
|
||||||
|
sourceid varchar(50) not null PRIMARY KEY,
|
||||||
|
sourcename varchar(50) not null,
|
||||||
|
url varchar(50) not null,
|
||||||
|
wrapX boolean,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--wmts服务
|
||||||
|
create table c3gis_ol_source_wmts(
|
||||||
|
sourceid varchar(50) not null PRIMARY KEY,
|
||||||
|
sourcename varchar(50) not null,
|
||||||
|
url varchar(50) not null,
|
||||||
|
layer varchar(50) not null,
|
||||||
|
style varchar(50) not null,
|
||||||
|
format varchar(50) not null,
|
||||||
|
matrixSet varchar(50) not null,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--样式表
|
||||||
|
create table c3gis_ol_style_style(
|
||||||
|
styleid varchar(50) not null,
|
||||||
|
stylename varchar(50) not null,
|
||||||
|
fill varchar(50),
|
||||||
|
image varchar(50),
|
||||||
|
stroke varchar(50),
|
||||||
|
text varchar(50),
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--填充面样式
|
||||||
|
create table c3gis_ol_style_fill(
|
||||||
|
styleid varchar(50) not null,
|
||||||
|
stylename varchar(50) not null,
|
||||||
|
color varchar(50) not null,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--边框样式
|
||||||
|
create table c3gis_ol_style_stroke(
|
||||||
|
styleid varchar(50) not null,
|
||||||
|
stylename varchar(50) not null,
|
||||||
|
color varchar(50) not null,
|
||||||
|
width integer,
|
||||||
|
lineCap varchar(50),
|
||||||
|
lineJoin varchar(50),
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
|
|
||||||
|
--图标样式
|
||||||
|
create table c3gis_ol_style_icon(
|
||||||
|
styleid varchar(50) not null,
|
||||||
|
stylename varchar(50) not null,
|
||||||
|
anchor real ARRAY,
|
||||||
|
anchorOrigin varchar(20),
|
||||||
|
anchorXUnits varchar(20),
|
||||||
|
anchorYUnits varchar(20),
|
||||||
|
color varchar(20),
|
||||||
|
crossOrigin real,
|
||||||
|
description varchar(50)
|
||||||
|
);
|
||||||
10
src/main/resources/resources.properties
Normal file
10
src/main/resources/resources.properties
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
gis.driverClassName=oracle.jdbc.driver.OracleDriver
|
||||||
|
gis.url=jdbc:oracle:thin:@172.16.6.13:1521:orcl
|
||||||
|
gis.username=spatial
|
||||||
|
gis.password=spatial
|
||||||
|
|
||||||
|
|
||||||
|
postgis.driverClassName=org.postgresql.Driver
|
||||||
|
postgis.url=jdbc:postgresql://localhost:5432/gisdb
|
||||||
|
postgis.username=postgres
|
||||||
|
postgis.password=postgres
|
||||||
30
src/main/resources/spring-config.xml
Normal file
30
src/main/resources/spring-config.xml
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xmlns:jee="http://www.springframework.org/schema/jee"
|
||||||
|
xmlns:tx="http://www.springframework.org/schema/tx"
|
||||||
|
xmlns:context="http://www.springframework.org/schema/context"
|
||||||
|
xmlns:aop="http://www.springframework.org/schema/aop"
|
||||||
|
xsi:schemaLocation="http://www.springframework.org/schema/beans
|
||||||
|
http://www.springframework.org/schema/beans/spring-beans.xsd
|
||||||
|
http://www.springframework.org/schema/tx
|
||||||
|
http://www.springframework.org/schema/tx/spring-tx.xsd
|
||||||
|
http://www.springframework.org/schema/jee
|
||||||
|
http://www.springframework.org/schema/jee/spring-jee.xsd
|
||||||
|
http://www.springframework.org/schema/context
|
||||||
|
http://www.springframework.org/schema/context/spring-context.xsd
|
||||||
|
http://www.springframework.org/schema/aop
|
||||||
|
http://www.springframework.org/schema/aop/spring-aop.xsd" default-lazy-init="true">
|
||||||
|
<bean id="configProperties" class="org.springframework.beans.factory.config.PropertiesFactoryBean">
|
||||||
|
<property name="fileEncoding" value="UTF-8" />
|
||||||
|
<property name="locations">
|
||||||
|
<list>
|
||||||
|
<value>classpath:resources.properties</value>
|
||||||
|
</list>
|
||||||
|
</property>
|
||||||
|
</bean>
|
||||||
|
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PreferencesPlaceholderConfigurer">
|
||||||
|
<property name="properties" ref="configProperties" />
|
||||||
|
</bean>
|
||||||
|
<context:component-scan base-package="com.gis3c.*"/>
|
||||||
|
</beans>
|
||||||
Loading…
Reference in New Issue
Block a user