| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Event
An event fired by the observation mechanism.
| Field Summary | |
|---|---|
| static int | NODE_ADDEDGenerated on persist when a node is added. | 
| static int | NODE_MOVEDGenerated on persist when a node is moved. | 
| static int | NODE_REMOVEDGenerated on persist when a node is removed. | 
| static int | PERSISTIf event bundling is supported, this event is used to indicate a bundle boundary within the event journal. | 
| static int | PROPERTY_ADDEDGenerated on persist when a property is added. | 
| static int | PROPERTY_CHANGEDGenerated on persist when a property is changed. | 
| static int | PROPERTY_REMOVEDGenerated on persist when a property is removed. | 
| Method Summary | |
|---|---|
|  long | getDate()Returns the date when the change was persisted that caused this event. | 
|  java.lang.String | getIdentifier()Returns the identifier associated with this event or nullif
 this event has no associated identifier. | 
|  java.util.Map | getInfo()Returns the information map associated with this event. | 
|  java.lang.String | getPath()Returns the absolute path associated with this event or nullif this event has no associated identifier. | 
|  int | getType()Returns the type of this event: a constant defined by this interface. | 
|  java.lang.String | getUserData()Returns the user data set through ObservationManager.setUserData(java.lang.String)on theObservationManagerbound to theSessionthat caused the event. | 
|  java.lang.String | getUserID()Returns the user ID connected with this event. | 
| Field Detail | 
|---|
static final int NODE_ADDED
getPath()
 returns the absolute path of the node that was added.getIdentifier() returns the identifier of the node that was added.getInfo() returns an empty Map object.
static final int NODE_REMOVED
getPath()
 returns the absolute path of the node that was removed.getIdentifier() returns the identifier of the node that was removed.getInfo() returns an empty Map object.
static final int PROPERTY_ADDED
getPath()
 returns the absolute path of the property that was added.getIdentifier() returns the identifier of the parent node of the property
 that was added. getInfo() returns an empty Map
 object.
static final int PROPERTY_REMOVED
getPath() returns the absolute path of the property that was
 removed.getIdentifier() returns the identifier of the
 parent node of the property that was removed. getInfo()
 returns an empty Map object.
static final int PROPERTY_CHANGED
getPath() returns the absolute path of the property that was
 changed.getIdentifier() returns the identifier of the
 parent node of the property that was changed. getInfo()
 returns an empty Map object.
static final int NODE_MOVED
getPath()
 returns the absolute path of the destination of the move.getIdentifier() returns the identifier of the moved node. getInfo() If the method that caused this event was a Session.move or Workspace.move then the returned Map has keys
 srcAbsPath and destAbsPath with values
 corresponding to the parameters passed to the move method.
 
 If the method that caused this event was a Node.orderBefore then the returned
 Map has keys srcChildRelPath and
 destChildRelPath with values corresponding to the parameters
 passed to the orderBefore method. 
static final int PERSIST
getPath() returns
 null.getIdentifier() returns
 null.getInfo() returns an empty
 Map object.
| Method Detail | 
|---|
int getType()
NODE_ADDEDNODE_REMOVEDPROPERTY_ADDEDPROPERTY_REMOVEDPROPERTY_CHANGEDNODE_MOVEDPERSIST
java.lang.String getPath()
                         throws RepositoryException
null
 if this event has no associated identifier. The meaning of the associated
 path depends upon the type of the event. See event type constants above.
RepositoryException - if an error occurs.java.lang.String getUserID()
Session.getUserID() of the session that
 caused the event.
java.lang.String getIdentifier()
                               throws RepositoryException
null if
 this event has no associated identifier. The meaning of the associated
 identifier depends upon the type of the event. See event type constants
 above.
null.
RepositoryException - if an error occurs.
java.util.Map getInfo()
                      throws RepositoryException
Map containing parameter information for instances
         of a NODE_MOVED event.
RepositoryException - if an error occurs.
java.lang.String getUserData()
                             throws RepositoryException
ObservationManager.setUserData(java.lang.String)
 on the ObservationManager bound to the Session
 that caused the event.
RepositoryException - if an error occurs.
long getDate()
             throws RepositoryException
RepositoryException - if an error occurs.| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||