wuxw7
2018-04-13 3de85d01308c5efa0bc77d4a02fdc9a16d5aa9fb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
package com.java110.feign.base;
 
import com.java110.entity.mapping.CodeMapping;
import feign.Param;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
 
import java.util.List;
 
/**
 * Created by wuxw on 2017/7/25.
 */
@FeignClient(name = "base-service", fallback = CommonServiceFallback.class)
public interface ICommonService {
 
    /**
     * 查询所有有效的映射数据
     *
     * @return
     */
    @RequestMapping("/commonService/getCodeMappingAll")
    public List<CodeMapping> getCodeMappingAll()  throws Exception;
 
    /**
     * 根据域查询对应的映射关系
     *
     * @param domain
     * @return
     */
    @RequestMapping("/commonService/getCodeMappingByDomain")
    public List<CodeMapping> getCodeMappingByDomain(@RequestParam("domain") String domain)  throws Exception;
 
    /**
     * 根据HCode查询映射关系
     *
     * @param hCode
     * @return
     */
    @RequestMapping("/commonService/getCodeMappingByHCode")
    public List<CodeMapping> getCodeMappingByHCode(@RequestParam("hCode") String hCode)  throws Exception;
 
 
    /**
     * 根据PCode查询映射关系
     *
     * @param pCode
     * @return
     */
    @RequestMapping("/commonService/getCodeMappingByHCode")
    public List<CodeMapping> getCodeMappingByPCode(@RequestParam("pCode") String pCode)  throws Exception;
 
    /**
     * 根据domain 和 hcode 查询映射关系
     *
     * @param pCode
     * @return
     */
    @RequestMapping("/commonService/getCodeMappingByDomainAndHCode")
    public List<CodeMapping> getCodeMappingByDomainAndHCode(@RequestParam("hCode") String hCode,@RequestParam("pCode") String pCode)  throws Exception;
 
    /**
     * 根据domain 和 pcode 查询映射关系
     *
     * @param domain
     * @return
     */
    @RequestMapping("/commonService/getCodeMappingByDomainAndPCode")
    public List<CodeMapping> getCodeMappingByDomainAndPCode(@RequestParam("domain") String domain,@RequestParam("pCode") String pCode)  throws Exception;
 
    /**
     * 常量域和h_code 查询
     * @param hCode
     * @return
     * @throws Exception
     */
    @RequestMapping("/commonService/getDynamicConstantValueByHCode")
    public List<CodeMapping> getDynamicConstantValueByHCode(@RequestParam("hCode") String hCode) throws Exception;
 
    /**
     * 常量域和h_code 查询
     * @param pCode
     * @return
     * @throws Exception
     */
    @RequestMapping("/commonService/getDynamicConstantValueByPCode")
    public List<CodeMapping> getDynamicConstantValueByPCode(@RequestParam("pCode") String pCode) throws Exception;
 
}