org.apache.wicket.util.watch
Interface IModificationWatcher

All Known Implementing Classes:
ModificationWatcher

public interface IModificationWatcher

Monitors one or more IModifiable objects, calling a IChangeListener when a given object's modification time changes.

Author:
Juergen Donnerstag

Method Summary
 boolean add(IModifiable modifiable, IChangeListener listener)
          Adds an IModifiable object and an IChangeListener object to call when the modifiable object is modified.
 void destroy()
          Stops this ModificationWatcher.
 java.util.Set<IModifiable> getEntries()
          Retrieves a key set of all IModifiable objects currently being monitored.
 IModifiable remove(IModifiable modifiable)
          Removes all entries associated with an IModifiable object.
 void start(Duration pollFrequency)
          Starts watching at a given Duration polling rate.
 

Method Detail

add

boolean add(IModifiable modifiable,
            IChangeListener listener)
Adds an IModifiable object and an IChangeListener object to call when the modifiable object is modified.

Parameters:
modifiable - an IModifiable object to monitor
listener - an IChangeListener to call if the IModifiable object is modified
Returns:
true if the set did not already contain the specified element

remove

IModifiable remove(IModifiable modifiable)
Removes all entries associated with an IModifiable object.

Parameters:
modifiable - an IModifiable object
Returns:
the IModifiable object that was removed, else null

start

void start(Duration pollFrequency)
Starts watching at a given Duration polling rate.

Parameters:
pollFrequency - the polling rate Duration

destroy

void destroy()
Stops this ModificationWatcher.


getEntries

java.util.Set<IModifiable> getEntries()
Retrieves a key set of all IModifiable objects currently being monitored.

Returns:
a Set of all IModifiable entries currently maintained


Copyright © 2006-2011 Apache Software Foundation. All Rights Reserved.