com.esri.adf.web.faces.event
Class TocEvent

java.lang.Object
  extended by java.util.EventObject
      extended by javax.faces.event.FacesEvent
          extended by javax.faces.event.ActionEvent
              extended by com.esri.adf.web.faces.event.ADFEvent
                  extended by com.esri.adf.web.faces.event.TocEvent
All Implemented Interfaces:
Serializable

public class TocEvent
extends ADFEvent

The EventArgs object for the TocControl for storing TOC nodes and the current state of those nodes.

See Also:
Serialized Form

Nested Class Summary
static class TocEvent.CheckedTocNode
          Represents a node for the checked/unchecked operation.
 
Field Summary
protected  Collection<TocEvent.CheckedTocNode> checkedNodes
          The collection of TocEvent.CheckedTocNode objects.
protected  String contextMenuItemValue
          the value of the context menu item to be processed
protected  TocNode node
          The TOC node to perform the event.
protected  int nodeOperation
          The operation to perform on the node.
 
Fields inherited from class com.esri.adf.web.faces.event.ADFEvent
context, parameters
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
TocEvent(javax.faces.component.UIComponent source, javax.faces.context.FacesContext facesContext, WebContext context, TocNode node, int nodeOperation, String contextMenuItemValue, Collection<? extends TocEvent.CheckedTocNode> checkedNodes)
          Constructs the TOC event arguments object.
 
Method Summary
 Collection<TocEvent.CheckedTocNode> getCheckedNodes()
          Returns a collection of TocEvent.CheckedTocNodes.
 String getContextMenuItemValue()
          The value of the context menu item to be processed
 TocNode getNode()
          Returns the node associated with this operation.
 int getNodeOperation()
          Returns the operation to perform on the node.
 
Methods inherited from class com.esri.adf.web.faces.event.ADFEvent
getParameter, getWebContext
 
Methods inherited from class javax.faces.event.ActionEvent
isAppropriateListener, processListener
 
Methods inherited from class javax.faces.event.FacesEvent
getComponent, getPhaseId, queue, setPhaseId
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

node

protected TocNode node
The TOC node to perform the event.


nodeOperation

protected int nodeOperation
The operation to perform on the node. 0 indicates expand/collapse, 1 indicates check/uncheck, -1 indicates an error (the request parameter was null or not an integer), and any other integer indicates a custom operation.


checkedNodes

protected Collection<TocEvent.CheckedTocNode> checkedNodes
The collection of TocEvent.CheckedTocNode objects.


contextMenuItemValue

protected String contextMenuItemValue
the value of the context menu item to be processed

Constructor Detail

TocEvent

public TocEvent(javax.faces.component.UIComponent source,
                javax.faces.context.FacesContext facesContext,
                WebContext context,
                TocNode node,
                int nodeOperation,
                String contextMenuItemValue,
                Collection<? extends TocEvent.CheckedTocNode> checkedNodes)
Constructs the TOC event arguments object. If the node is not null, then the TocControl calls the TocNode.handleNodeEvent(com.esri.adf.web.faces.event.TocEvent) method on that node. If checkedNodes is not null, then the TocControl calls the TocNode.handleCheckedEvent(boolean, com.esri.adf.web.faces.event.TocEvent) method on all the nodes in this collection of TocEvent.CheckedTocNode objects.

Parameters:
source - the JSF component
facesContext - the FacesContext
context - the WebContext
node - the node to perform the operation on
nodeOperation - the operation to perform on the node (0 indicates expand/collapse, 1 indicates check/uncheck, and an integer other than -1, 0, or 1 indicates a custom operation)
contextMenuItemValue - - the value of the context menu item to be processed
checkedNodes - a collection of TocEvent.CheckedTocNode objects
Method Detail

getNode

public TocNode getNode()
Returns the node associated with this operation.

Returns:
TocNode- the node to perform the operation

getNodeOperation

public int getNodeOperation()
Returns the operation to perform on the node.

Returns:
int- the operation to perform on the node: 0 indicates expand/collapse, 1 indicates check/uncheck, -1 indicates an error (the request parameter was null or not an integer), and any other integer indicates a custom operation

getContextMenuItemValue

public String getContextMenuItemValue()
The value of the context menu item to be processed

Returns:
the value of the context menu item to be processed

getCheckedNodes

public Collection<TocEvent.CheckedTocNode> getCheckedNodes()
Returns a collection of TocEvent.CheckedTocNodes.

Returns:
Collection- the TocEvent.CheckedTocNodes