public class

RemoteListenerCache

extends Object
java.lang.Object
   ↳ com.davidluoye.support.link.RemoteListenerCache<T>

Class Overview

It is a convenient utils for communicating between two application processes. In normal binder is always be used between two processes communicate and the one is server and another is client. The two processes both can exit in any time in normal, and it may be caused by crash or killed by lmkd or ams and so on. But when client process register a callback into server process in order to listen some states or events, and then server process exit, the client should wake up the server right now and register the callback again. This is what this class utils do. This utils class is to register callback cache again into server which died and start up again. If you want to know how to awake server process, see RemoteServiceWakeLock

Summary

Nested Classes
interface RemoteListenerCache.ProcessMonitor  
Public Constructors
RemoteListenerCache(RemoteListenerCache.ProcessMonitor callBack)
Public Methods
List<T> getCacheCallBackList()
void register(IInterface service, T callback)
void unRegister(T callback)
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public RemoteListenerCache (RemoteListenerCache.ProcessMonitor callBack)

Public Methods

public List<T> getCacheCallBackList ()

public void register (IInterface service, T callback)

public void unRegister (T callback)