public abstract class ObservingCourier extends Object implements ObservingCourier, Observer
ObservingCourier is an observer which uses the courier service to notify when things change.
| Modifier and Type | Field and Description |
|---|---|
protected CourierService |
m_courierService
Constructor discovered injected CourierService.
|
protected String |
m_deliveryId
The key identifying the Portal PageSession.
|
protected String |
m_elementId
The key identifying the element on the Portal Page.
|
protected boolean |
m_enabled
The enabled state.
|
protected String |
m_location
The location (id not ref).
|
| Constructor and Description |
|---|
ObservingCourier(String location,
String elementId)
Construct.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
check(Object arg)
Check to see if we want to process or ignore this update.
|
void |
disable() |
void |
enable() |
String |
getDeliveryId() |
String |
getElementId() |
boolean |
getEnabled() |
String |
getLocation()
Access the location this observer is observing.
|
void |
justDelivered()
Accept notification that the portal element has just been delivered.
|
void |
setDeliveryId(String id) |
void |
setElementId(String id) |
void |
update(Observable o,
Object arg)
This method is called whenever the observed object is changed.
|
protected CourierService m_courierService
protected String m_location
protected String m_deliveryId
protected String m_elementId
protected boolean m_enabled
public ObservingCourier(String location, String elementId)
location - The key identifying the client window to which this courier delivers updates.elementId - The key identifying the element on the Portal Page that would need a courier delivered message when things change.public String getDeliveryId()
getDeliveryId in interface ObservingCourierpublic void setDeliveryId(String id)
setDeliveryId in interface ObservingCourierpublic String getElementId()
getElementId in interface ObservingCourierpublic void setElementId(String id)
setElementId in interface ObservingCourierpublic boolean getEnabled()
getEnabled in interface ObservingCourierpublic void enable()
enable in interface ObservingCourierpublic void disable()
disable in interface ObservingCourierpublic void justDelivered()
justDelivered in interface ObservingCourierpublic boolean check(Object arg)
check in interface ObservingCourierarg - The arg from the update.public String getLocation()
getLocation in interface ObservingCourierpublic void update(Observable o, Object arg)
notifyObservers method to have all the object's observers notified of the change. default implementation is to
cause the courier service to deliver to the interface controlled by my controller. Extensions can override.Copyright © 2003–2016 The Sakai Foundation. All rights reserved.