|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xcmis.search.Visitors
public class Visitors
| Nested Class Summary | |
|---|---|
static class |
Visitors.AbstractModelVisitor
A common base class for all visitors, which provides no-op implementations for all visit(...) methods. |
static class |
Visitors.NavigationVisitor
An abstract visitor implementation that performs navigation of the query object. |
static class |
Visitors.ReadableVisitor
|
static class |
Visitors.WalkAllVisitor
A visitor implementation that walks the entire query object tree and delegates to another supplied visitor to do the actual work. |
| Constructor Summary | |
|---|---|
Visitors()
|
|
| Method Summary | ||
|---|---|---|
static Set<SelectorName> |
getSelectorsReferencedBy(QueryElement visitable)
Get the names of the selectors referenced by the QueryElement object. |
|
static String |
readable(QueryElement visitable)
Using a visitor, obtain the readable string representation of the supplied object |
|
static
|
visit(QueryElement visitable,
GeneralVisitor visitor)
Visit the supplied object using the supplied QueryObjectModelVisitor, which must be responsible for navigation as
well as any business logic. |
|
static
|
visitAll(QueryElement visitable,
StrategyVisitor strategyVisitor)
Visit all objects in the supplied object using a Visitors.NavigationVisitor (specifically a
Visitors.WalkAllVisitor), and with each of these visited objects calling the appropriate visit(...) method on the
supplied QueryObjectModelVisitor. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Visitors()
| Method Detail |
|---|
public static <StrategyVisitor extends QueryObjectModelVisitor> StrategyVisitor visitAll(QueryElement visitable,
StrategyVisitor strategyVisitor)
throws VisitException
object using a Visitors.NavigationVisitor (specifically a
Visitors.WalkAllVisitor), and with each of these visited objects calling the appropriate visit(...) method on the
supplied QueryObjectModelVisitor.
StrategyVisitor - the type of strategy visitorvisitable - the top-level object to be visitedstrategyVisitor - the visitor that is to be called for each visited objects, but that does not call
Visitable#accept(Visitor)
VisitException - if exception occurs
public static <GeneralVisitor extends QueryObjectModelVisitor> GeneralVisitor visit(QueryElement visitable,
GeneralVisitor visitor)
throws VisitException
object using the supplied QueryObjectModelVisitor, which must be responsible for navigation as
well as any business logic.
visitable - the top-level object to be visitedvisitor - the visitor that is to be used
VisitException - if exception occurspublic static String readable(QueryElement visitable)
object
visitable - the visitable
public static Set<SelectorName> getSelectorsReferencedBy(QueryElement visitable)
visitable - the object to be visited
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||