package com.iailab.module.data.api.point; import com.iailab.module.data.api.point.dto.*; import com.iailab.module.data.enums.ApiConstants; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.tags.Tag; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestParam; import java.util.List; import java.util.Map; /** * @author PanZhibao * @Description * @createTime 2024年08月19日 */ @FeignClient(name = ApiConstants.NAME) @Tag(name = "数据测点服务") public interface DataPointApi { String PREFIX = ApiConstants.PREFIX + "/point"; @PostMapping(PREFIX + "/point/{pointNo}") @Operation(summary = "查询测点信息") ApiPointDTO getPoint(@PathVariable("pointNo") String pointNo); @PostMapping(PREFIX + "/current") @Operation(summary = "查询多个测点当前值") Map pointsCurrent(@RequestParam("pointNos") List pointNos); @PostMapping(PREFIX + "/history") @Operation(summary = "查询多个测点历史值") Map>> pointsHistory(@RequestBody ApiPointsValueQueryDTO queryDto); @PostMapping(PREFIX + "/value/get") @Operation(summary = "查询单个测点历史值") List getValue(@RequestBody ApiPointValueQueryDTO queryDto); @PostMapping(PREFIX + "/value/set") @Operation(summary = "设置单个测点值") Boolean setValue(@RequestBody ApiPointValueWriteDTO queryDto); }