Class GMarkerGroupTableContentProvider
- All Implemented Interfaces:
IAddressableTableContentProvider
,IContentProvider
,ISelectableTableContentProvider
,ITableContentProvider
,IUpdateableContentProvider
,Serializable
GMarkerGroup
as rows in the content provider, so the GMarkerList
renderer can be used
to render a GMarkerGroup
.- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescription -
Method Summary
Modifier and TypeMethodDescriptionMarker at the current row index or null.Returns wrapped current row object.getGroup()
GMarkerGroup wrapped by this provider.GMarkers in the wrapped GMarkerGroup, or an empty list (never null).Object[]
Returns list of properties supported by this content provider.int
Return the number of rows of data objects represented by this DataModel.getRowId()
Returns unique identifier for the current row.int
Return the zero-relative index of the currently selected row.int
Returns number of selected rows.Returns collection ofString
ids of the selected rows.Returns collection ofString
ids of the un-selected rows (all other rows are selected implicitly) May be empty or contain non-existent ids; never null, never contains null.Returns row variable name.Class<?>
Returns java type of the given propertyboolean
Returns true if it's more effecient to use unselected model (ieISelectableTableContentProvider.getRowUnselectedIds()
rather thanISelectableTableContentProvider.getRowSelectedIds()
).Returns value of the given propertyboolean
hasProperty
(Object propertyKey) Checks if the given property is supported by this content providerboolean
Checks if this content provider truly is addressable.boolean
isReadOnly
(Object propertyKey) Returns true if the given property is readonly.boolean
Return a flag indicating whether there is rowData available at the current rowIndex.boolean
Returnstrue
if current row is selected.void
setGroup
(GMarkerGroup group) GMarkerGroup wrapped by this provider.protected void
setMarkerSelected
(FacesContext context, GMarker marker, boolean selected) Selects/unselects the specified marker.void
setRowById
(String id) Selects current row by its id.void
setRowIndex
(int rowIndex) Set the zero-relative index of the currently selected row, or -1 to indicate that we are not positioned on a row.void
setRowSelected
(boolean selected) Sets the selection status for the current row.void
Sets new selection using a collection ofString
ids of the rows to select.void
Unselects rows using a collection ofString
ids of the un-selected rows (all other rows are selected implicitly).void
setRowVariable
(String var) Sets row variable name to use for accessing row specific data.void
Sets new value of the given propertyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.webmethods.caf.faces.data.IContentProvider
toString
-
Field Details
-
EMPTY_MARKER_LIST
-
m_id
ID of marker group. -
m_index
protected int m_indexCurrent row index. -
m_var
Row variable name. -
m_useUnselectedModel
protected boolean m_useUnselectedModelUnselected model state.
-
-
Constructor Details
-
GMarkerGroupTableContentProvider
public GMarkerGroupTableContentProvider() -
GMarkerGroupTableContentProvider
-
-
Method Details
-
getPropertyKeys
Description copied from interface:IContentProvider
Returns list of properties supported by this content provider. Can returnObject[0]
, never null.- Specified by:
getPropertyKeys
in interfaceIContentProvider
- Returns:
- array of property keys which is typically of type
String
orInteger
-
getType
Description copied from interface:IContentProvider
Returns java type of the given property- Specified by:
getType
in interfaceIContentProvider
- Parameters:
propertyKey
- the property key of typeString
orInteger
- Returns:
- property java
Class
- Throws:
PropertyNotFoundException
- if property is not supported
-
getValue
Description copied from interface:IContentProvider
Returns value of the given property- Specified by:
getValue
in interfaceIContentProvider
- Parameters:
propertyKey
- the property key of typeString
orInteger
- Returns:
- value of the property, can be
null
- Throws:
PropertyNotFoundException
- if property is not supportedELException
-
hasProperty
Description copied from interface:IContentProvider
Checks if the given property is supported by this content provider- Specified by:
hasProperty
in interfaceIContentProvider
- Parameters:
propertyKey
- property key of typeString
orInteger
- Returns:
true
if property is supported
-
isReadOnly
Description copied from interface:IUpdateableContentProvider
Returns true if the given property is readonly. If it is readonly,
IUpdateableContentProvider.setValue(Object, Object)
will definitely fail.- Specified by:
isReadOnly
in interfaceIUpdateableContentProvider
- Parameters:
propertyKey
- property key of typeString
orInteger
- Returns:
- true if the property is readonly
- Throws:
PropertyNotFoundException
ELException
-
setValue
public void setValue(Object propertyKey, Object value) throws ELException, PropertyNotFoundException Description copied from interface:IUpdateableContentProvider
Sets new value of the given property
- Specified by:
setValue
in interfaceIUpdateableContentProvider
- Parameters:
propertyKey
- property key of typeString
orInteger
value
- new property value- Throws:
PropertyNotFoundException
- if property is not foundELException
-
getCurrentRow
Description copied from interface:ITableContentProvider
Returns wrapped current row object. Can be
null
if not data is available- Specified by:
getCurrentRow
in interfaceITableContentProvider
- Returns:
- current row object
- See Also:
-
getRowCount
public int getRowCount()Description copied from interface:ITableContentProvider
Return the number of rows of data objects represented by this DataModel.Return -1, if the number of rows is unknown, or no wrappedData is available.
- Specified by:
getRowCount
in interfaceITableContentProvider
- See Also:
-
getRowIndex
public int getRowIndex()Description copied from interface:ITableContentProvider
Return the zero-relative index of the currently selected row.If we are not currently positioned on a row, or no wrappedData is available, return -1.
- Specified by:
getRowIndex
in interfaceITableContentProvider
- See Also:
-
getRowVariable
Description copied from interface:ITableContentProvider
Returns row variable name.
If specified row variable can be used to access current row data for the provider internal needs, like sorting or addressing.
- Specified by:
getRowVariable
in interfaceITableContentProvider
- Returns:
- row variable name or null if not specified
- See Also:
-
isRowAvailable
public boolean isRowAvailable()Description copied from interface:ITableContentProvider
Return a flag indicating whether there is rowData available at the current rowIndex. If no wrappedData is available, return false.- Specified by:
isRowAvailable
in interfaceITableContentProvider
- See Also:
-
setRowIndex
public void setRowIndex(int rowIndex) Description copied from interface:ITableContentProvider
Set the zero-relative index of the currently selected row, or -1 to indicate that we are not positioned on a row.- Specified by:
setRowIndex
in interfaceITableContentProvider
- See Also:
-
setRowVariable
Description copied from interface:ITableContentProvider
Sets row variable name to use for accessing row specific data. For example, if the provider wrapps an array of a data objects with
id
property and the variable name isitem
, then the provider implementation can accessid
property of each record asitem.id
.This property should set only once at the provider initialization time
- Specified by:
setRowVariable
in interfaceITableContentProvider
-
getRowId
Description copied from interface:IAddressableTableContentProvider
Returns unique identifier for the current row. If no current row is avaiable, returns null.- Specified by:
getRowId
in interfaceIAddressableTableContentProvider
- Returns:
- current row id or null
-
isAddressable
public boolean isAddressable()Description copied from interface:IAddressableTableContentProvider
Checks if this content provider truly is addressable.- Specified by:
isAddressable
in interfaceIAddressableTableContentProvider
- Returns:
true
if addressable.
-
setRowById
Description copied from interface:IAddressableTableContentProvider
Selects current row by its id. If id doesn't identify a row, makes no row current (equivalent tosetRowIndex(-1)
).- Specified by:
setRowById
in interfaceIAddressableTableContentProvider
- Parameters:
id
- row id to find and make current
-
getRowSelectedCount
public int getRowSelectedCount()Description copied from interface:ISelectableTableContentProvider
Returns number of selected rows.- Specified by:
getRowSelectedCount
in interfaceISelectableTableContentProvider
- Returns:
- number of currently selection rows
-
getRowSelectedIds
Description copied from interface:ISelectableTableContentProvider
Returns collection ofString
ids of the selected rows. May be empty or contain non-existent ids; never null, never contains null.- Specified by:
getRowSelectedIds
in interfaceISelectableTableContentProvider
- Returns:
- collection of ids of selected rows
-
getRowUnselectedIds
Description copied from interface:ISelectableTableContentProvider
Returns collection ofString
ids of the un-selected rows (all other rows are selected implicitly) May be empty or contain non-existent ids; never null, never contains null.- Specified by:
getRowUnselectedIds
in interfaceISelectableTableContentProvider
- Returns:
- collection of ids of the un-selection rows
-
getUseUnselectedModel
public boolean getUseUnselectedModel()Description copied from interface:ISelectableTableContentProvider
Returns true if it's more effecient to use unselected model (ieISelectableTableContentProvider.getRowUnselectedIds()
rather thanISelectableTableContentProvider.getRowSelectedIds()
).- Specified by:
getUseUnselectedModel
in interfaceISelectableTableContentProvider
- Returns:
- true if it's more effecient to use unselected model
-
isRowSelected
public boolean isRowSelected()Description copied from interface:ISelectableTableContentProvider
Returnstrue
if current row is selected.- Specified by:
isRowSelected
in interfaceISelectableTableContentProvider
- Returns:
- true if current row is selection
-
setRowSelected
public void setRowSelected(boolean selected) Description copied from interface:ISelectableTableContentProvider
Sets the selection status for the current row.- Specified by:
setRowSelected
in interfaceISelectableTableContentProvider
- Parameters:
selected
-true
to select current row;false
to unselect.
-
setRowSelectedIds
Description copied from interface:ISelectableTableContentProvider
Sets new selection using a collection ofString
ids of the rows to select. May be empty or contain non-existent ids; never null, never contains null.- Specified by:
setRowSelectedIds
in interfaceISelectableTableContentProvider
- Parameters:
ids
- the collection ofString
row ids
-
setRowUnselectedIds
Description copied from interface:ISelectableTableContentProvider
Unselects rows using a collection ofString
ids of the un-selected rows (all other rows are selected implicitly). May be empty or contain non-existent ids; never null, never contains null.- Specified by:
setRowUnselectedIds
in interfaceISelectableTableContentProvider
- Parameters:
ids
- collection ofString
row ids
-
getGroup
GMarkerGroup wrapped by this provider. -
setGroup
GMarkerGroup wrapped by this provider. -
getCurrentMarker
Marker at the current row index or null. -
getMarkers
GMarkers in the wrapped GMarkerGroup, or an empty list (never null). -
setMarkerSelected
Selects/unselects the specified marker.
-