|
Dashboard Builder Data Displayer API 6.0.0.CR2 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface KPIManager
Manager class that it allows for the retrieval of KPI instances as well as DataProvider's.
| Field Summary | |
|---|---|
static int |
EVENT_ALL
|
static int |
EVENT_KPI_CREATED
|
static int |
EVENT_KPI_DELETED
|
static int |
EVENT_KPI_SAVED
|
| Method Summary | |
|---|---|
void |
addKPIListener(KPIListener kpiListener,
int eventId)
Register a listener interested in all process events. |
KPI |
createKPI()
Factory method for the creation of a KPI brand new instance. |
Set |
getAllKPIs()
Get all KPIs defined. |
KPI |
getKPIByCode(String code)
Get a persistent KPI by its universal code. |
KPI |
getKPIById(Long id)
Get a persistent KPI by its identifier. |
Map<Integer,List<KPIListener>> |
getKPIListenerMap()
Retrieve registered kpi listeners. |
List<KPIListener> |
getKPIListeners(int eventId)
Retrieve registered kpi listeners for a specified event. |
void |
notifyKPIListener(int eventId,
KPI kpi)
Notify the specified event to the registered listeners. |
void |
removeKPIListener(KPIListener kpiListener)
Removes a registered listener. |
void |
removeKPIListener(KPIListener kpiListener,
int eventId)
Removes a registered listener. |
void |
sortKPIsByDescription(List<KPI> propList,
boolean ascending)
Sort a list of properties by name. |
| Field Detail |
|---|
static final int EVENT_ALL
static final int EVENT_KPI_CREATED
static final int EVENT_KPI_SAVED
static final int EVENT_KPI_DELETED
| Method Detail |
|---|
KPI createKPI()
Set getAllKPIs()
throws Exception
Exception
KPI getKPIById(Long id)
throws Exception
Exception
KPI getKPIByCode(String code)
throws Exception
Exception
void sortKPIsByDescription(List<KPI> propList,
boolean ascending)
Map<Integer,List<KPIListener>> getKPIListenerMap()
List<KPIListener> getKPIListeners(int eventId)
eventId - The event being listened.
void addKPIListener(KPIListener kpiListener,
int eventId)
WARNING: In order to solve the -lapsed listener- problem the reference to the listener stored by the manager is weak. This means that if the listener reference is lost then is also automatically removed from the listeners list. To avoid this issue ensure that your listener instance is referenced in your object model and exists as long as the manager is alive.
kpiListener - Be sure your listener instance added is referred by another object
instance in order to avoid garbage collector to finalize your listener unexpectedly.eventId - The event interested in.
void removeKPIListener(KPIListener kpiListener,
int eventId)
eventId - The event listener was interested in.void removeKPIListener(KPIListener kpiListener)
void notifyKPIListener(int eventId,
KPI kpi)
|
Dashboard Builder Data Displayer API 6.0.0.CR2 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||