|
@@ -42,13 +42,10 @@ public class Network {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
public Network(HashMap<String, Object> data) {
|
|
public Network(HashMap<String, Object> data) {
|
|
|
- if (data.get("type") == null)
|
|
|
|
|
- throw new AssertionError("Type can't be null");
|
|
|
|
|
-
|
|
|
|
|
- active = (data.get("active") != null && (boolean)data.get("active"));
|
|
|
|
|
|
|
+ active = (Boolean)data.get("active");
|
|
|
state = (NetworkInfo.State)data.get("state");
|
|
state = (NetworkInfo.State)data.get("state");
|
|
|
- type = (int) data.get("type");
|
|
|
|
|
- ValidSSIDs =(List<String>)data.get("SSIDs");
|
|
|
|
|
|
|
+ type = (Integer)data.get("type");
|
|
|
|
|
+ ValidSSIDs =(List<String>)data.get("ValidSSIDs");
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|