public static class Components.ForEach extends Object
Constructor and Description |
---|
ForEach() |
ForEach(FacesContext facesContext) |
Modifier and Type | Method and Description |
---|---|
Components.ForEach |
fromRoot(UIComponent root)
The root component where tree visiting starts
|
protected FacesContext |
getFacesContext() |
protected Set<VisitHint> |
getHints() |
protected Collection<String> |
getIds() |
protected UIComponent |
getRoot() |
Components.ForEach |
havingIds(Collection<String> ids)
The IDs of the components that are visited
|
Components.ForEach |
havingIds(String... ids)
The IDs of the components that are to be visited
|
<C extends UIComponent> |
invoke(Callback.ReturningWithArgument<VisitResult,C> operation)
Invokes the given operation on the components as specified by the
query parameters set via this builder.
|
<C extends UIComponent> |
invoke(Callback.WithArgument<C> operation)
Invokes the given operation on the components as specified by the
query parameters set via this builder.
|
void |
invoke(VisitCallback operation)
Invokes the given operation on the components as specified by the
query parameters set via this builder.
|
Components.ForEach |
ofTypes(Class<?>... types)
The types of the components that are to be visited
|
Components.ForEach |
withHints(Set<VisitHint> hints)
The VisitHints that are used for the visit.
|
Components.ForEach |
withHints(VisitHint... hints)
The VisitHints that are used for the visit.
|
public ForEach()
public ForEach(FacesContext facesContext)
public Components.ForEach fromRoot(UIComponent root)
root
- the root component where tree visiting startspublic Components.ForEach havingIds(Collection<String> ids)
ids
- the IDs of the components that are visitedpublic Components.ForEach havingIds(String... ids)
ids
- the IDs of the components that are to be visitedpublic Components.ForEach withHints(Set<VisitHint> hints)
hints
- the VisitHints that are used for the visit.public Components.ForEach withHints(VisitHint... hints)
hints
- the VisitHints that are used for the visit.@SafeVarargs public final Components.ForEach ofTypes(Class<?>... types)
types
- the types of the components that are to be visitedpublic <C extends UIComponent> void invoke(Callback.WithArgument<C> operation)
C
- The expected component type.operation
- the operation to invoke on each componentClassCastException
- When C
is of wrong type.public <C extends UIComponent> void invoke(Callback.ReturningWithArgument<VisitResult,C> operation)
C
- The expected component type.operation
- the operation to invoke on each componentClassCastException
- When C
is of wrong type.public void invoke(VisitCallback operation)
operation
- the operation to invoke on each componentprotected FacesContext getFacesContext()
protected UIComponent getRoot()
protected Collection<String> getIds()
Copyright © 2012–2017 OmniFaces. All rights reserved.