|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.bpe.jsf.handler.BPCListHandler
This class can be used as a Faces Managed Bean which provides the data shown in a List Component. In order
to link a Managed Bean of the type BPCListHandler with a List Component on a page, the Value Binding Expressoin
of the list tag has to be targeted at the Managed Bean. For more information about the List Component
see ListTag
. The BPCListHandler will emit Item Changed Events if
a single item in the associated List Component has been selected. ItemListener can be registered on the
BPCListHandler using the ItemListener property. For more information about using the ItemListener interface, see
example under ItemListener
.
Example:
<managed-bean> <managed-bean-name>ProcessInstanceList</managed-bean-name> <managed-bean-class>com.ibm.bpe.jsf.handler.BPCListHandler</managed-bean-class> <managed-bean-scope>session</managed-bean-scope> <managed-property> <property-name>type</property-name> <value>com.ibm.bpe.client.model.ProcessInstanceBean</value> </managed-property> <managed-property> <property-name>itemListener</property-name> <list-entries> <value-class>com.ibm.bpe.jsf.handler.ItemListener</value-class> <value>#{ProcessInstanceDetailsBean}</value> </list-entries> </managed-property> <managed-property> <property-name>query</property-name> <value>#{ProcessInstanceQuery}</value> </managed-property> </managed-bean>The specified type enables Components to get hold of meta information about the model objects that are accessed through the instance of the BPCDetailsHandler.
<bpe:list model="#{ProcessInstanceList}" rows="5" styleClass="list" headerStyleClass="listHeader" rowClasses="normal"> <bpe:column name="name" action="processInstanceDetails" /> <bpe:column name="processTemplateName" action="processTemplateDetails" /> <bpe:column name="executionState" /> <bpe:column name="startTime" /> </bpe:list>
Nested Class Summary | |
---|---|
class |
BPCListHandler.PagingHelper
This class is not for public usage. |
class |
BPCListHandler.SelectionHelper
This class is not for public usage. |
class |
BPCListHandler.SortHelper
This class is not for public usage. |
Field Summary | |
---|---|
static java.lang.String |
ATTRIBUTE_FOR_SORTING
This is the name of the component attribute that determines which row will be used when sorting the result. |
static java.lang.String |
COPYRIGHT
|
Constructor Summary | |
---|---|
BPCListHandler()
|
Method Summary | |
---|---|
void |
addItemListener(ItemListener listener)
Adds a new ItemListener to the list of ItemListener . |
void |
clearSelection()
|
java.util.Map |
getErrors()
Returns the errors map for items in the list. |
java.lang.Object |
getItem()
Returns the currently selected item. |
java.util.List |
getItemListener()
Returns a list of all registered ItemListener . |
java.util.List |
getItems()
Returns the list of items retrieved by runing the associated query. |
BPCListHandler.PagingHelper |
getPagingHelper()
|
com.ibm.bpc.clientcore.Query |
getQuery()
Returns the registered query object. |
Message |
getQueryMessage()
Returns Messages indication problems during the execution of the query. |
java.util.List |
getSelectedItems()
Returns all selected items in the list. |
BPCListHandler.SelectionHelper |
getSelectionHelper()
|
BPCListHandler.SortHelper |
getSortHelper()
|
java.lang.String |
getType()
Returns the expected type of the query model. |
java.lang.String |
refreshList()
Triggers a refresh of the list by executing the associated query. |
java.lang.String |
refreshList(boolean clearErrors)
Triggers a refresh of the list by executing the associated query. |
void |
setErrors(java.util.Map errors)
Sets the errors map on this instance. |
void |
setItemListener(java.util.List list)
Sets the list of ItemListener . |
void |
setQuery(com.ibm.bpc.clientcore.Query newQuery)
Sets the query used for retrieving the list of items. |
void |
setType(java.lang.String typeName)
Sets the type of the BPCListHandler. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String COPYRIGHT
public static final java.lang.String ATTRIBUTE_FOR_SORTING
Constructor Detail |
public BPCListHandler()
Method Detail |
public void clearSelection()
public java.util.List getItems()
public java.lang.String refreshList(boolean clearErrors)
public java.lang.String refreshList()
public void setQuery(com.ibm.bpc.clientcore.Query newQuery)
newQuery
- The query used to retrieve the model
TODO Review(aschoen,Brian): Is it appropriate to throw an assertion ??public com.ibm.bpc.clientcore.Query getQuery()
public void setType(java.lang.String typeName)
typeName
- The model type
TODO Review(aschoen,Brian): Is it appropriate to throw an assertion ??public java.lang.String getType()
public java.lang.Object getItem()
ColumnTag
.
If called out of differed context the item might not valid any more.
public java.util.List getSelectedItems()
getSelectedItems
in interface ItemProvider
public java.util.List getItemListener()
ItemListener
.
public void setItemListener(java.util.List list)
ItemListener
.
For example, this method will be called if ItemListeners are specified as managed-bean-property of a BPCListHandler instance
in a faces-config file.
It overwrites any ItemListener that have been set using the addItemListener method.
list
- The list of ItemListenerpublic void addItemListener(ItemListener listener)
ItemListener
to the list of ItemListener
.
listener
- A ItemListenerpublic java.util.Map getErrors()
getErrors
in interface ErrorHandler
public void setErrors(java.util.Map errors)
setErrors
in interface ErrorHandler
errors
- The errors that occured while processing commandspublic Message getQueryMessage()
public BPCListHandler.PagingHelper getPagingHelper()
public BPCListHandler.SelectionHelper getSelectionHelper()
public BPCListHandler.SortHelper getSortHelper()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |