当前位置: 首页>>代码示例>>Java>>正文


Java IMXEventListener类代码示例

本文整理汇总了Java中org.matrix.androidsdk.listeners.IMXEventListener的典型用法代码示例。如果您正苦于以下问题:Java IMXEventListener类的具体用法?Java IMXEventListener怎么用?Java IMXEventListener使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


IMXEventListener类属于org.matrix.androidsdk.listeners包,在下文中一共展示了IMXEventListener类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onStoreReady

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
/**
 * Dispatch that the store is ready.
 */
public void onStoreReady() {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onStoreReady();
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onStoreReady();
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onStoreReady " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:24,代码来源:MXDataHandler.java

示例2: onAccountInfoUpdate

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onAccountInfoUpdate(final MyUser myUser) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onAccountInfoUpdate(myUser);
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onAccountInfoUpdate(myUser);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onAccountInfoUpdate " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:22,代码来源:MXDataHandler.java

示例3: onPresenceUpdate

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onPresenceUpdate(final Event event, final User user) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onPresenceUpdate(event, user);
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onPresenceUpdate(event, user);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onPresenceUpdate " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:22,代码来源:MXDataHandler.java

示例4: onLiveEventsChunkProcessed

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onLiveEventsChunkProcessed(final String startToken, final String toToken) {
    refreshUnreadCounters();

    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onLiveEventsChunkProcessed(startToken, toToken);
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onLiveEventsChunkProcessed(startToken, toToken);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onLiveEventsChunkProcessed " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:24,代码来源:MXDataHandler.java

示例5: onBingEvent

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onBingEvent(final Event event, final RoomState roomState, final BingRule bingRule) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onBingEvent(event, roomState, bingRule);
    }

    if (ignoreEvent(event.roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onBingEvent(event, roomState, bingRule);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onBingEvent " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:26,代码来源:MXDataHandler.java

示例6: onEventSentStateUpdated

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onEventSentStateUpdated(final Event event) {
    if (ignoreEvent(event.roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onEventSentStateUpdated(event);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onEventSentStateUpdated " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:22,代码来源:MXDataHandler.java

示例7: onEventSent

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onEventSent(final Event event, final String prevEventId) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onEventSent(event, prevEventId);
    }

    if (ignoreEvent(event.roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onEventSent(event, prevEventId);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onEventSent " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:26,代码来源:MXDataHandler.java

示例8: onBingRulesUpdate

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onBingRulesUpdate() {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onBingRulesUpdate();
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onBingRulesUpdate();
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onBingRulesUpdate " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:22,代码来源:MXDataHandler.java

示例9: dispatchOnInitialSyncComplete

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
/**
 * Dispatch the onInitialSyncComplete event.
 */
private void dispatchOnInitialSyncComplete(final String toToken) {
    mInitialSyncToToken = toToken;

    refreshUnreadCounters();

    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onInitialSyncComplete(toToken);
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onInitialSyncComplete(mInitialSyncToToken);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onInitialSyncComplete " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:28,代码来源:MXDataHandler.java

示例10: dispatchOnCryptoSyncComplete

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
/**
 * Dispatch the OnCryptoSyncComplete event.
 */
private void dispatchOnCryptoSyncComplete() {
    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onCryptoSyncComplete();
                } catch (Exception e) {
                    Log.e(LOG_TAG, "OnCryptoSyncComplete " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:20,代码来源:MXDataHandler.java

示例11: onNewRoom

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onNewRoom(final String roomId) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onNewRoom(roomId);
    }

    if (ignoreEvent(roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onNewRoom(roomId);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onNewRoom " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:26,代码来源:MXDataHandler.java

示例12: onJoinRoom

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onJoinRoom(final String roomId) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onJoinRoom(roomId);
    }

    if (ignoreEvent(roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onJoinRoom(roomId);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onJoinRoom " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:26,代码来源:MXDataHandler.java

示例13: onRoomInitialSyncComplete

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onRoomInitialSyncComplete(final String roomId) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onRoomInitialSyncComplete(roomId);
    }

    if (ignoreEvent(roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onRoomInitialSyncComplete(roomId);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onRoomInitialSyncComplete " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:26,代码来源:MXDataHandler.java

示例14: onRoomInternalUpdate

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onRoomInternalUpdate(final String roomId) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onRoomInternalUpdate(roomId);
    }

    if (ignoreEvent(roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onRoomInternalUpdate(roomId);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onRoomInternalUpdate " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:26,代码来源:MXDataHandler.java

示例15: onNotificationCountUpdate

import org.matrix.androidsdk.listeners.IMXEventListener; //导入依赖的package包/类
@Override
public void onNotificationCountUpdate(final String roomId) {
    if (null != mCryptoEventsListener) {
        mCryptoEventsListener.onNotificationCountUpdate(roomId);
    }

    if (ignoreEvent(roomId)) {
        return;
    }

    final List<IMXEventListener> eventListeners = getListenersSnapshot();

    mUiHandler.post(new Runnable() {
        @Override
        public void run() {
            for (IMXEventListener listener : eventListeners) {
                try {
                    listener.onNotificationCountUpdate(roomId);
                } catch (Exception e) {
                    Log.e(LOG_TAG, "onNotificationCountUpdate " + e.getMessage());
                }
            }
        }
    });
}
 
开发者ID:matrix-org,项目名称:matrix-android-sdk,代码行数:26,代码来源:MXDataHandler.java


注:本文中的org.matrix.androidsdk.listeners.IMXEventListener类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。