package com.hdkj.lt.feign;

import com.hdkj.lt.base.constants.SystemGlobalConstant;
import com.hdkj.lt.feign.fallback.CityFeederTopoApiClientFallBack;
import com.hdkj.hussar.ApiResponse;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
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;


/**
 * @author Annie
 */
@FeignClient(value = SystemGlobalConstant.SERVICE_NAME_LOAD_TRANSFER_SI,contextId = "ICityFeederTopoApiClient", fallbackFactory = CityFeederTopoApiClientFallBack.class)
public interface ICityFeederTopoApiClient {
    // 处理拓扑数据
    String API_MAPPING_SERVICE_TOPO_GET = "feign/topo/doCityFeederTopo";
    String API_MAPPING_SERVICE_TOPO_GET_SVG = "feign/topo/getCityFeederSvg";
    String API_MAPPING_SERVICE_TOPO_SEND_MSG = "feign/topo/sendMessageDealLineFile";

    @PostMapping(API_MAPPING_SERVICE_TOPO_GET_SVG)
    ApiResponse<List<String>> getCityFeederSvg();

    @PostMapping(API_MAPPING_SERVICE_TOPO_GET)
    ApiResponse<Object> doCityFeederTopo(@RequestBody List<String> list);

    @GetMapping(API_MAPPING_SERVICE_TOPO_SEND_MSG)
    ApiResponse<String> sendMessage2LineFile(@RequestParam("topoVersion") String topoVersion);
}
