DeviceFindFactory constructor
DeviceFindFactory({
- OnStateListener? onState,
- dynamic type = DEVICE_FOUND_BROADCAST_SSDP,
- bool? showLog,
Implementation
DeviceFindFactory(
{OnStateListener? onState, type = DEVICE_FOUND_BROADCAST_SSDP, bool? showLog}) {
switch (type) {
case DEVICE_FOUND_BROADCAST:
mDeviceFindList.add(BroadcastDeviceFind(stateListener: onState, showLog: showLog));
break;
case DEVICE_FOUND_SSDP:
mDeviceFindList.add(SSDPDeviceFind(stateListener: onState, showLog: showLog));
break;
case DEVICE_FOUND_BROADCAST_SSDP:
mDeviceFindList.add(BroadcastDeviceFind(stateListener: onState, showLog: showLog));
mDeviceFindList.add(SSDPDeviceFind(stateListener: onState, showLog: showLog));
break;
}
}