public DispatcherManager(Context context) { a = new HashMap(); b = new ObjectBuilder(); c = new EventReader(); d = new PolicyHelper(); e = context; b.registerClass(com / xiaomi / miui / analyticstracker / service / XiaomiDispatcher, "xiaomi"); }
public void switchDispatcher(Map map) { a.clear(); if (map != null) { for (Iterator iterator = map.keySet().iterator(); iterator.hasNext(); ) { String s = (String) iterator.next(); Dispatchable dispatchable = (Dispatchable) b.buildObject(s); if (dispatchable == null) { Log.d("DispatcherManager", String.format("server:%s does not exist", new Object[] {s})); } else { a.put(dispatchable, map.get(s)); } } if (map.size() > 0) { Event.setDispatcher(new ArrayList(a.keySet())); } } }