0fd093a2
李进
初始提交:手持车牌核销应用
|
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
|
package com.ectrip.checkincar.net;
import com.ectrip.checkincar.core.prefs.AppPrefs;
/** 核销/查询接口选择:按设置页「核销方式」分流(默认模拟核销,防误触发真实订单消费)。识别引擎与此无关。 */
public class VerifyApiFactory {
private VerifyApiFactory() {
}
/** 创建核销接口(会真实消费订单) */
public static VerifyApi create() {
if (AppPrefs.getVerifyMode() == AppPrefs.VERIFY_SERVER) {
return new HttpVerifyApi();
}
return new MockVerifyApi();
}
/** 创建预约查询接口(只查不消费,用于核销前弹窗确认) */
public static QueryApi createQuery() {
if (AppPrefs.getVerifyMode() == AppPrefs.VERIFY_SERVER) {
return new HttpQueryApi();
}
return new MockQueryApi();
}
}
|