Package org.neo4j.cypherdsl.core.ast
Interface Visitor
-
- All Known Implementing Classes:
ReflectiveVisitor,VisitorWithResult
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public interface Visitor
- Since:
- 1.0
- Author:
- Michael J. Simons
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidenter(Visitable segment)Enter aVisitable.default EnterResultenterWithResult(Visitable segment)A method that is used to pass control to some extend from the visitor to theVisitable.default voidleave(Visitable segment)Leave aVisitable.
-
-
-
Method Detail
-
enter
void enter(Visitable segment)
Enter aVisitable. Not all visitables will obey to the result- Parameters:
segment- the segment to visit.
-
enterWithResult
default EnterResult enterWithResult(Visitable segment)
A method that is used to pass control to some extend from the visitor to theVisitable. Not all visitables react to this and we don't give any guarantees about which will. This method has been mainly introduced in parallel toenter(Visitable)so that existing external implementations ofvisitorswon't break.- Parameters:
segment- the segment to visit.- Returns:
- A result indicating whether visitation of child elements should continue or not.
- Since:
- 2022.3.0
-
-