Overview | Package | Class | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.exist.storage
Class NotificationService

    java.lang.Object
      java.util.AbstractMap
          java.util.IdentityHashMap
              org.exist.storage.NotificationService

All Implemented Interfaces:
  java.lang.Cloneable, java.util.Map, java.io.Serializable

public class NotificationService
extends java.util.IdentityHashMap

Global notification service for document updates. Other classes can subscribe to this service to be notified of document modifications, removals or additions.

Author:
  wolf
See Also:
  Serialized Form

Nested Class Summary

Nested classes inherited from class java.util.Map
`java.util.Map.Entry`

Constructor Summary
`NotificationService()`

Method Summary
`void` | `debug()`
`void` | `notifyUpdate(DocumentImpl document, int event)` Notify all subscribers that a document has been updated/removed or a new document has been added.
`void` | `subscribe(UpdateListener listener)` Subscribe an `UpdateListener` to receive notifications.
`void` | `unsubscribe(UpdateListener listener)` Unsubscribe an `UpdateListener`.

Methods inherited from class java.util.IdentityHashMap
`clear, clone, containsKey, containsValue, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, remove, size, values`

Methods inherited from class java.util.AbstractMap
`toString`

Methods inherited from class java.lang.Object
`getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### NotificationService

    public NotificationService()

Method Detail

### subscribe

    public void subscribe(UpdateListener listener)

  Subscribe an `UpdateListener` to receive notifications.

  Parameters:
    `listener` -

### unsubscribe

    public void unsubscribe(UpdateListener listener)

  Unsubscribe an `UpdateListener`.

  Parameters:
    `listener` -

### notifyUpdate

    public void notifyUpdate(DocumentImpl document,
                             int event)

  Notify all subscribers that a document has been updated/removed or a new document has been added.

  Parameters:
    `document` -
    `event` -

### debug

    public void debug()

Overview | Package | Class | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (C) Wolfgang Meier. All rights reserved.