All Downloads are FREE. Search and download functionalities are using the official Maven repository.

alloy2b.kodkod.ast.visitor.package.html Maven / Gradle / Ivy









Contains visitors for Kodkod formulas, expressions, and integer expressions.

Package Specification

Provides two interfaces for traversing the Kodkod AST using the visitor pattern. A {@linkplain kodkod.ast.visitor.VoidVisitor} visits the nodes but returns no values. A {@linkplain kodkod.ast.visitor.ReturnVisitor} can be parametrized to return values of specific types for {@linkplain kodkod.ast.Decls}, {@linkplain kodkod.ast.Expression}, {@linkplain kodkod.ast.IntExpression}, and {@linkplain kodkod.ast.Formula} nodes.

Several skeletal implementations of the VoidVisitor and ReturnVisitor interfaces are also provided. These traverse the AST in a depth-first manner and optionally cache the results of visiting specified nodes. The caching functionality makes it convenient to implement visitors that visit shared nodes only once.

Related Documentation

@see kodkod.ast.visitor.VoidVisitor @see kodkod.ast.visitor.ReturnVisitor




© 2015 - 2025 Weber Informatics LLC | Privacy Policy