diff options
Diffstat (limited to 'src/com/android/server/NetworkObserverRegistry.java')
-rw-r--r-- | src/com/android/server/NetworkObserverRegistry.java | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/com/android/server/NetworkObserverRegistry.java b/src/com/android/server/NetworkObserverRegistry.java index afe166b..b83bc5c 100644 --- a/src/com/android/server/NetworkObserverRegistry.java +++ b/src/com/android/server/NetworkObserverRegistry.java @@ -42,19 +42,13 @@ public class NetworkObserverRegistry extends INetdUnsolicitedEventListener.Stub private static final String TAG = NetworkObserverRegistry.class.getSimpleName(); /** - * Constructs a new NetworkObserverRegistry. - * - * <p>Only one registry should be used per process since netd will silently ignore multiple - * registrations from the same process. - */ - NetworkObserverRegistry() {} - - /** * Start listening for Netd events. * * <p>This should be called before allowing any observer to be registered. + * Note there is no unregister method. The only way to unregister is when the process + * terminates. */ - void register(@NonNull INetd netd) throws RemoteException { + public void register(@NonNull INetd netd) throws RemoteException { netd.registerUnsolicitedEventListener(this); } |