|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.faces.component.visit.VisitContext javax.faces.component.visit.VisitContextWrapper
public abstract class VisitContextWrapper
Provides a simple implementation of
VisitContext
that can be subclassed by developers wishing to
provide specialized behavior to an existing VisitContext
instance. The default implementation of all methods is to call
through to the wrapped VisitContext
instance.
Usage: extend this class and override
getWrapped()
to return the instance we are wrapping.
Field Summary |
---|
Fields inherited from class javax.faces.component.visit.VisitContext |
---|
ALL_IDS |
Constructor Summary | |
---|---|
VisitContextWrapper()
|
Method Summary | |
---|---|
FacesContext |
getFacesContext()
Returns the FacesContext for the current request. |
java.util.Set<VisitHint> |
getHints()
Returns hints that influence the behavior of the tree visit. |
java.util.Collection<java.lang.String> |
getIdsToVisit()
Returns the ids of the components to visit. |
java.util.Collection<java.lang.String> |
getSubtreeIdsToVisit(UIComponent component)
Given a |
abstract VisitContext |
getWrapped()
A class that implements this interface uses this method to return an instance of the class being wrapped. |
VisitResult |
invokeVisitCallback(UIComponent component,
VisitCallback callback)
Called by UIComponent.visitTree()
to visit a single component. |
Methods inherited from class javax.faces.component.visit.VisitContext |
---|
createVisitContext, createVisitContext |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public VisitContextWrapper()
Method Detail |
---|
public FacesContext getFacesContext()
VisitContext
Returns the FacesContext for the current request.
getFacesContext
in class VisitContext
public java.util.Set<VisitHint> getHints()
VisitContext
Returns hints that influence the behavior of the tree visit.
Interested parties, such as
UIComponent.visitTree()
implementations,
may check to see whether a particular hint is present by calling
VisitContext.getHints().contains()
, passing in one of the
hints defined by VisitHint
.
getHints
in class VisitContext
public java.util.Collection<java.lang.String> getIdsToVisit()
VisitContext
Returns the ids of the components to visit.
In the case of a full tree visit, this method returns the ALL_IDS collection. Otherwise, if a partial visit is beign performed, returns a modifiable collection containing the client ids of the components that should be visited.
getIdsToVisit
in class VisitContext
public java.util.Collection<java.lang.String> getSubtreeIdsToVisit(UIComponent component)
VisitContext
Given a NamingContainer
component, returns the
client ids of any components underneath the NamingContainer that
should be visited.
This method is called by NamingContainer visitTree() implementations to determine whether the NamingContainer contains components to be visited. In the case where no such components exist, the NamingContainer can short-circuit the tree visit and avoid descending into child subtrees.
In addition, iterating components such as UIData may be able to use the returned ids to determine which iterated states (ie. rows) need to be visited. This allows the visit traversal to be contstrained such only those rows that contain visit targets need to be traversed.
getSubtreeIdsToVisit
in class VisitContext
component
- a NamingContainer component
VisitContext.ALL_IDS
collection.public VisitResult invokeVisitCallback(UIComponent component, VisitCallback callback)
VisitContext
Called by UIComponent.visitTree()
to visit a single component.
invokeVisitCallback
in class VisitContext
component
- the component to visitcallback
- the VisitCallback to call
public abstract VisitContext getWrapped()
FacesWrapper
A class that implements this interface uses this method to return an instance of the class being wrapped.
getWrapped
in interface FacesWrapper<VisitContext>
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 2009-2011, Oracle Corporation and/or its affiliates. All Rights Reserved. Use is subject to license terms.
Generated on 10-February-2011 12:41