puzhibing
2026-03-03 2b16a4c512804ed48825d272a996f0d31eb3d1a3
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
package com.xiaopeng.api.factory.operation;
 
import com.xiaopeng.api.dto.map.XpPointExportExcelQuery;
import com.xiaopeng.api.dto.operation.*;
import com.xiaopeng.api.dto.order.HistoryEndPointsDto;
import com.xiaopeng.api.dto.order.HistoryStartPointsDto;
import com.xiaopeng.api.feignClient.operation.XpCruisePlanClient;
import com.xiaopeng.api.feignClient.operation.XpPointClient;
import com.xiaopeng.api.model.operation.XpCruisePlanVehicle;
import com.xiaopeng.api.model.operation.XpElectronicFenceArea;
import com.xiaopeng.api.model.operation.XpPoint;
import com.xiaopeng.api.model.order.XpCruiseOrder;
import com.xiaopeng.api.query.operation.PointListQuery;
import com.xiaopeng.api.query.operation.PointPageListListQuery;
import com.xiaopeng.api.vo.order.XpHistoryEndPointsVo;
import com.xiaopeng.api.vo.order.XpHistoryStartPointsVo;
import com.xiaopeng.common.core.domain.R;
import com.xiaopeng.common.core.web.page.PageInfo;
import lombok.extern.slf4j.Slf4j;
import org.springframework.cloud.openfeign.FallbackFactory;
import org.springframework.stereotype.Component;
 
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
 
@Slf4j
@Component
public class XpCruisePlanClientFallbackFactory implements FallbackFactory<XpCruisePlanClient> {
    @Override
    public XpCruisePlanClient create(Throwable cause) {
        return new XpCruisePlanClient() {
            @Override
            public R<XpCruiseOrder> getCruisePoint(CruisePointDto dto) {
                log.error("XpCruisePlanClientFallbackFactory getCruisePoint error:{}", cause.getMessage());
                return null;
            }
 
            @Override
            public R<XpCruiseOrder> getNewCruiseOrder(NewCruiseOrderDto dto) {
                log.error("XpCruisePlanClientFallbackFactory getNewCruiseOrder error:{}", cause.getMessage());
                return null;
            }
 
            @Override
            public R<XpCruiseOrder> findReturnCruisePoint(XpCruiseOrder xpCruiseOrder) {
                log.error("XpCruisePlanClientFallbackFactory findReturnCruisePoint error:{}", cause.getMessage());
                return null;
            }
 
            @Override
            public R<XpCruisePlanVehicle> getCruisePlan(Long vehicleId) {
                log.error("XpCruisePlanClientFallbackFactory getCruisePlan error:{}", cause.getMessage());
                return null;
            }
 
 
        };
    }
}