13 changed files with 247 additions and 40 deletions
@ -1,13 +1,55 @@ |
|||
package com.ping.chuan.apiservice.dao; |
|||
|
|||
import java.time.LocalDateTime; |
|||
import java.util.Date; |
|||
import java.util.List; |
|||
import java.util.Map; |
|||
|
|||
import com.ping.chuan.apiservice.model.domain.CoordinateInfo; |
|||
import com.ping.chuan.apiservice.model.vo.PointValue; |
|||
|
|||
/** |
|||
* @describe: 数据处理 数据接口 |
|||
* @author: xiaowuler |
|||
* @createTime: 2021-11-10 16:01 |
|||
*/ |
|||
public interface IDataRepository { |
|||
/** |
|||
* |
|||
* @param keyspace |
|||
* @param tableName |
|||
* @param initialTime |
|||
* @param forecastTime |
|||
* @param timeEffect |
|||
* @param columns |
|||
*/ |
|||
void insert(String keyspace, String tableName, Date initialTime, Date forecastTime, int timeEffect, Map<String, byte[]> columns); |
|||
|
|||
/** |
|||
* |
|||
* @param keyspace |
|||
* @param tableName |
|||
* @param initialTime |
|||
* @param forecastTime |
|||
* @param coordinateInfos |
|||
* @return |
|||
*/ |
|||
List<PointValue> findPoint(String keyspace, String tableName, LocalDateTime initialTime, LocalDateTime forecastTime, List<CoordinateInfo> coordinateInfos) throws Exception; |
|||
|
|||
/** |
|||
* |
|||
* @param keyspace |
|||
* @param tableName |
|||
* @return |
|||
*/ |
|||
List<Date> findInitialTime(String keyspace, String tableName); |
|||
|
|||
/** |
|||
* |
|||
* @param keyspace |
|||
* @param tableName |
|||
* @param initialTime |
|||
* @return |
|||
*/ |
|||
List<Date> findForecastTime(String keyspace, String tableName, Date initialTime); |
|||
} |
|||
|
@ -1,34 +0,0 @@ |
|||
package com.ping.chuan.apiservice.util; |
|||
|
|||
import io.swagger.annotations.Api; |
|||
import org.springframework.context.annotation.Bean; |
|||
import org.springframework.context.annotation.Configuration; |
|||
import springfox.documentation.builders.ApiInfoBuilder; |
|||
import springfox.documentation.builders.PathSelectors; |
|||
import springfox.documentation.builders.RequestHandlerSelectors; |
|||
import springfox.documentation.service.ApiInfo; |
|||
import springfox.documentation.spi.DocumentationType; |
|||
import springfox.documentation.spring.web.plugins.Docket; |
|||
import springfox.documentation.swagger2.annotations.EnableSwagger2; |
|||
|
|||
@Configuration |
|||
@EnableSwagger2 |
|||
public class SwaggerConfig { |
|||
@Bean |
|||
public Docket createRestApi() { |
|||
return new Docket(DocumentationType.SWAGGER_2) |
|||
.useDefaultResponseMessages(false) |
|||
.apiInfo(apiInfo()) |
|||
.select() |
|||
.apis(RequestHandlerSelectors.withClassAnnotation(Api.class)) |
|||
.paths(PathSelectors.any()) |
|||
.build(); |
|||
} |
|||
private ApiInfo apiInfo() { |
|||
return new ApiInfoBuilder() |
|||
.title("swagger2测试项目") |
|||
.description("初级版本") |
|||
.version("1.0") |
|||
.build(); |
|||
} |
|||
} |
@ -1 +1,2 @@ |
|||
|
|||
server: |
|||
port: 4557 |
|||
|
Loading…
Reference in new issue