@@ -0,0 +1,1433 @@
+package info.izumin.android.bletia;%0A%0Aimport java.util.EnumMap;%0Aimport java.util.HashMap;%0Aimport java.util.Map;%0Aimport java.util.UUID;%0A%0A/**%0A * Created by izumin on 9/14/15.%0A */%0Apublic class BleEventStore %7B%0A    private EnumMap%3CBleEvent.Type, Map%3CUUID, BleEvent%3E%3E mWaitingEventMap;%0A    private EnumMap%3CBleEvent.Type, Map%3CUUID, BleEvent%3E%3E mRunningEventMap;%0A%0A    public BleEventStore() %7B%0A        mWaitingEventMap = new EnumMap%3C%3E(BleEvent.Type.class);%0A        mRunningEventMap = new EnumMap%3C%3E(BleEvent.Type.class);%0A    %7D%0A%0A    public void addEvent(BleEvent event) %7B%0A        if (!mWaitingEventMap.containsKey(event.getType())) %7B%0A            mWaitingEventMap.put(event.getType(), new HashMap%3CUUID, BleEvent%3E());%0A        %7D%0A        mWaitingEventMap.get(event.getType()).put(event.getUuid(), event);%0A    %7D%0A%0A    public BleEvent runEvent(BleEvent.Type type, UUID uuid) %7B%0A        BleEvent event = mWaitingEventMap.get(type).remove(uuid);%0A        if (!mRunningEventMap.containsKey(type)) %7B%0A            mRunningEventMap.put(type, new HashMap%3CUUID, BleEvent%3E());%0A        %7D%0A        mRunningEventMap.get(type).put(uuid, event);%0A        return event;%0A    %7D%0A%0A    public BleEvent closeEvent(BleEvent.Type type, UUID uuid) %7B%0A        return mRunningEventMap.get(type).remove(uuid);%0A    %7D%0A%0A    public boolean isRunning(BleEvent.Type type, UUID uuid) %7B%0A        return mRunningEventMap.containsKey(type) && mRunningEventMap.get(type).containsKey(uuid);%0A    %7D%0A%7D%0A

Add BleEventStore class