10 repository-uri
Algorithms that walk a tree and trigger specific callback functions when encountering nodes of a particular type.
Distinct from Tree Walkers: Distinct from Tree Walkers: specifically implements the visitor pattern for typed node callbacks rather than general transformations.
Explore 10 awesome GitHub repositories matching data & databases · Visitor Pattern Traversers. Refine with filters or upvote what's useful.
This project is a technical handbook and tutorial guide for the Babel compiler. It serves as a resource for configuring the tool and writing custom plugins to transform JavaScript source code. The guide provides instructional material on creating custom transformation plugins and modifying the compilation process. It specifically covers how to navigate and modify abstract syntax trees to programmatically rewrite source code. The documentation covers the mechanics of code transformation, the management of compiler configurations, and the fundamentals of compiler tooling. It includes guidance
Provides implementation details for walking a syntax tree and triggering callbacks on matching node types.
Acorn is a JavaScript parser that converts source text into a structured abstract syntax tree. It follows the ESTree specification to produce a standardized JSON tree format, enabling consistent analysis of code structure and language versions. The project features a plugin-based grammar extension system that allows the base parser to be extended with custom rules for experimental or non-standard language features. It also includes syntax error recovery, which inserts placeholder nodes into the tree when encountering invalid code to allow parsing to continue. The toolset covers static analys
Implements a visitor-pattern walker to trigger specific actions when encountering predefined node types during tree traversal.
Sonic is a high-performance Go JSON serialization library that provides tools for encoding and decoding native data structures. It functions as a JIT-accelerated encoder, a JSON AST parser, a stream processor, and a lazy decoder. The project utilizes just-in-time machine code generation to optimize the encoding of large data schemas and employs a JIT assembler to maximize serialization and deserialization speeds. It features a precompiled schema warmup process to prevent latency spikes during initial execution and leverages SIMD hardware instructions for accelerated parsing. The library cove
Provides a preorder traversal mechanism via the visitor pattern to map JSON data into custom types.
sqlglot is a SQL parser and transpiler that represents queries as abstract syntax trees to enable structural analysis, modification, and semantic transformation. It functions as a dialect translator and query optimizer, converting SQL code between different database engines and simplifying syntax trees through rule-based normalization. The project provides a framework for defining custom SQL dialects by overriding tokenizers, parsers, and generators. It includes a lineage analyzer to track data flow from source tables through complex queries to identify the origin of specific columns. Additi
Implements the visitor pattern to identify and modify specific nodes within SQL expression trees.
Checkstyle is a Java static analysis tool and linter designed to identify and enforce coding standards and best practices. It functions as a code quality auditor and Javadoc validation tool, checking source code against configurable rulesets to ensure structural and stylistic consistency. The project allows for the creation of custom linting rules by extending a core API to inspect the abstract syntax tree. It further enables specialized validation through the use of XPath expressions to query the syntax tree for specific code patterns and violations. Capability areas include the enforcement
Uses the visitor pattern to traverse the abstract syntax tree and trigger listeners for specific code tokens.
syn is a Rust syntax tree parser and token stream converter. It serves as a toolkit for procedural macro development, providing a framework to parse Rust source code into structured syntax trees for analysis and transformation. The project enables the manipulation of Rust abstract syntax trees through specialized visitor and folder patterns for traversing and mutating nodes. It provides a bidirectional mapping that allows developers to convert token streams into structured trees and print those trees back into tokens for code generation. The library covers a broad range of syntax analysis ca
Implements the visitor pattern to separate syntax tree traversal logic from node-specific operations.
YamlDotNet is a YAML serialization library and data mapping tool for .NET. It functions as a parser and generator that converts between .NET objects and YAML formatted text for data storage and configuration. The project provides capabilities for YAML document parsing and data object mapping. It transforms YAML streams into low-level representations or high-level object models for programmatic analysis and converts structured data objects back into valid YAML strings. The library covers general data serialization and configuration file management, allowing application data structures to be m
Implements a visitor pattern to walk the parsed YAML node tree and execute custom logic.
The project provides a standardized abstract syntax tree specification and utility library for parsing, transforming, and serializing markdown documents. It serves as a comprehensive document processing architecture that translates between raw text markup and structured node representations in both directions. The capability surface covers syntax parsing for extended markdown features, custom syntax extensions, metadata blocks, and embedded expressions, alongside document serialization that converts syntax trees back into standard and extended markup formats. It includes node modeling and val
Traverses hierarchical document trees recursively to inspect, validate, and transform specific node types.
Serde-yaml is a serialization library for the Rust programming language that facilitates the conversion of complex data structures into YAML format and the deserialization of YAML text into strongly typed objects. It functions as a data format converter, enabling the transformation of structured information between native language types and human-readable configuration files. The library integrates with the standard Rust serialization ecosystem to map arbitrary data types to and from the YAML format. By utilizing trait-based data mapping, it allows developers to manage application settings an
Traverses complex nested data structures by delegating type-specific logic to recursive handlers.
Deobfuscator is a static analysis and manipulation framework designed to inspect and modify compiled Java class files and bytecode instructions. It functions as a deobfuscator that simplifies and reverses obfuscated Java applications, alongside operating as a security runtime environment that isolates and executes untrusted or potentially malicious Java bytecode safely. The project processes class files through a sequence of custom transformation passes using visitor-based instruction parsing and a static class analysis engine that maps out class hierarchies and cross-references without dynam
Traverses class file instruction trees using pattern matching to identify and refactor specific obfuscated code constructs.