|
Elexis API documentationVersion 2.1.6 as of December 11 2011 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectch.elexis.actions.PersistentObjectLoader
public abstract class PersistentObjectLoader
This is a replacement for the former BackgroundJob-System. Since it became clear that the database access takes less than 10% of the total time needed for reload of a CommonViewer, the BackgroundJobs were not adequate for this task. Furthermore, there were several issues with those widely used jobs. PersistentObjectLoader is a much simpler replacement and does not load in background. Instead it uses a @see DelayableJob to perform loading.
Nested Class Summary | |
---|---|
static interface |
PersistentObjectLoader.QueryFilter
a QueryFilter can modify the Query of this Loader. |
Field Summary | |
---|---|
static java.lang.String |
PARAM_FIELDNAMES
|
static java.lang.String |
PARAM_VALUES
|
Constructor Summary | |
---|---|
PersistentObjectLoader(CommonViewer cv,
Query<? extends PersistentObject> qbe)
|
Method Summary | |
---|---|
void |
addQueryFilter(PersistentObjectLoader.QueryFilter fp)
|
void |
applyQueryFilters()
|
void |
changed(java.util.HashMap<java.lang.String,java.lang.String> values)
One or more of the ControlField's selectors habe been changed. |
void |
dispose()
|
java.lang.Object[] |
getElements(java.lang.Object inputElement)
|
Query<? extends PersistentObject> |
getQuery()
|
void |
init()
Called after all elements of the CommonViewer are created but before setting input |
void |
inputChanged(Viewer viewer,
java.lang.Object oldInput,
java.lang.Object newInput)
This will be called by the CommonViewer on construction |
boolean |
isSuspended()
|
void |
removeQueryFilter(PersistentObjectLoader.QueryFilter fp)
|
void |
reorder(java.lang.String field)
The user request reordering of the table |
void |
selected()
ENTER has been pressed |
void |
setOrderFields(java.lang.String... name)
|
void |
setSuspended(boolean bSuspend)
|
void |
startListening()
start listening the selector fields of the ControlField of the loader's CommonViewer. |
void |
stopListening()
stop listening the selector fields |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface ch.elexis.actions.DelayableJob.IWorker |
---|
work |
Field Detail |
---|
public static final java.lang.String PARAM_FIELDNAMES
public static final java.lang.String PARAM_VALUES
Constructor Detail |
---|
public PersistentObjectLoader(CommonViewer cv, Query<? extends PersistentObject> qbe)
Method Detail |
---|
public Query<? extends PersistentObject> getQuery()
public void startListening()
startListening
in interface ViewerConfigurer.ICommonViewerContentProvider
public void stopListening()
stopListening
in interface ViewerConfigurer.ICommonViewerContentProvider
public java.lang.Object[] getElements(java.lang.Object inputElement)
public void dispose()
public void inputChanged(Viewer viewer, java.lang.Object oldInput, java.lang.Object newInput)
public void changed(java.util.HashMap<java.lang.String,java.lang.String> values)
changed
in interface ViewerConfigurer.ControlFieldListener
values
- the new valuespublic void reorder(java.lang.String field)
reorder
in interface ViewerConfigurer.ControlFieldListener
field
- the field name after which the table should e reorderedpublic void selected()
ViewerConfigurer.ControlFieldListener
selected
in interface ViewerConfigurer.ControlFieldListener
public void addQueryFilter(PersistentObjectLoader.QueryFilter fp)
public void removeQueryFilter(PersistentObjectLoader.QueryFilter fp)
public void applyQueryFilters()
public void setOrderFields(java.lang.String... name)
public void setSuspended(boolean bSuspend)
public boolean isSuspended()
public void init()
ViewerConfigurer.ICommonViewerContentProvider
init
in interface ViewerConfigurer.ICommonViewerContentProvider
|
Elexis API documentationVersion 2.1.6 as of December 11 2011 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |