Commit 7123d98e by 111-PC\111

[+]aqara代码提交

1 parent 3279e020
......@@ -30,7 +30,7 @@ public class BussinessFactory implements ApplicationContextAware {
* @param <T>
* @return
*/
public static <T> T getInstance(String bustype,Class<T> requiredType){
public static <T> T getInstance(Integer bustype,Class<T> requiredType){
String handerType = BussinessType.getHanderType(bustype);
if(handerType==null){
return null;
......
package cn.com.glsx.common.BussinessFactory;
import io.swagger.models.auth.In;
/**
* @author zhouhaibao
* @date 2021/3/8 11:32
*/
public enum BussinessType {
tuya_hander("1", "deviceService"),
aqara_hander("2", "aqaraDeviceService");
private String busType;
tuya_hander(1, "deviceService"),
aqara_hander(2, "aqaraDeviceService");
private Integer busType;
private String handerImp;
BussinessType(String busType, String handerImp) {
BussinessType(Integer busType, String handerImp) {
this.busType = busType;
this.handerImp = handerImp;
}
public String getBusType() {
public Integer getBusType() {
return busType;
}
public void setBusType(String busType) {
public void setBusType(Integer busType) {
this.busType = busType;
}
......@@ -34,7 +36,7 @@ public enum BussinessType {
}
public static String getHanderType(String busType) {
public static String getHanderType(Integer busType) {
for (BussinessType m : BussinessType.values()) {
if (m.getBusType().equals(busType)) {
return m.getHanderImp();
......
......@@ -13,7 +13,7 @@ public class OrderRequest {
private String phone;
private String channel;
private Integer channel;
private String deviceId;
}
......@@ -12,7 +12,7 @@ public class RemoteRequest {
private String phone;
private String data;
private String channel;
private Integer channel;
private String deviceId;
private String remoteId;
}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!