# gustavo2358/proleap-poc architecture

> Architecture diagram of the GitHub repository gustavo2358/proleap-poc, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-26). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/gustavo2358/proleap-poc
- Repository: https://github.com/gustavo2358/proleap-poc

## Overview

COBOL Structure Atlas analyzes a COBOL source file and copybooks, then generates locally openable static pages. The documented journey is parse tree → semantic AST → symbol table → reference resolution, with navigation back to source structure. The graph also includes coverage and storage-semantics capabilities visible in the supplied source. Main orchestration and some intermediate wiring are not shown in the excerpts, so only documented workflow links and explicit analysis inputs are drawn.

Main entry points: [`src/main/java/io/github/gustavo2358/cobolexplorer/ExplorerMain.java`](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/ExplorerMain.java) (Explorer entry), [`src/main/java/io/github/gustavo2358/cobolexplorer/AstBuilder.java`](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/AstBuilder.java) (AST construction), [`src/main/java/io/github/gustavo2358/cobolexplorer/CompilationUnitSymbolTableBuilder.java`](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/CompilationUnitSymbolTableBuilder.java) (Symbol tables), [`src/main/java/io/github/gustavo2358/cobolexplorer/CobolReferenceResolver.java`](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/CobolReferenceResolver.java) (Reference resolution)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_analysis["COBOL analysis"]
  node_main["Explorer entry<br/>[ExplorerMain.java]"]
  node_preprocessor["COPY preprocessing"]
  node_ast["AST construction<br/>[AstBuilder.java]"]
  node_symbols["Symbol tables"]
  node_resolution["Reference resolution"]
end

subgraph group_semantics["Semantic facts"]
  node_coverage["Semantic coverage"]
  node_layout["Storage layout"]
  node_access["Storage access facts"]
end

subgraph group_export["Products and export"]
  node_product["Semantic product"]
  node_writer["Page generation"]
end

subgraph group_interface["Static explorer"]
  node_treeui["Parse-tree view<br/>[app.js]"]
  node_astui["AST view<br/>[ast-app.js]"]
  node_symbolsui["Symbols view<br/>[symbols-app.js]"]
  node_resolutionui["Resolution view<br/>[resolution-app.js]"]
end

node_engineer(("Engineer"))
node_source["COBOL source"]
node_browser(("Local browser"))

node_engineer -->|"runs analysis"| node_main
node_source -->|"provides input"| node_main
node_main -->|"preprocesses COPY"| node_preprocessor
node_main -->|"builds AST"| node_ast
node_ast -->|"feeds declarations"| node_symbols
node_symbols -->|"supplies names"| node_resolution
node_ast -->|"assesses modeling"| node_coverage
node_symbols -->|"supplies declarations"| node_layout
node_resolution -->|"supplies bindings"| node_layout
node_resolution -->|"resolves accesses"| node_access
node_layout -->|"supplies layout"| node_access
node_main -->|"generates artifacts"| node_writer
node_writer -->|"writes product data"| node_product
node_browser -->|"opens page"| node_treeui
node_browser -->|"opens page"| node_astui
node_browser -->|"opens page"| node_symbolsui
node_browser -->|"opens page"| node_resolutionui

click node_main "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/ExplorerMain.java"
click node_preprocessor "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/PreprocessorEngine.java"
click node_ast "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/AstBuilder.java"
click node_symbols "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/CompilationUnitSymbolTableBuilder.java"
click node_resolution "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/CobolReferenceResolver.java"
click node_coverage "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/SemanticCoverage.java"
click node_layout "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/StorageLayoutSemantics.java"
click node_access "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/StorageAccessSemantics.java"
click node_product "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/semanticproduct/CobolSemanticProduct.java"
click node_writer "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/semanticproduct/transport/SemanticProductJsonWriter.java"
click node_treeui "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/app.js"
click node_astui "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/ast-app.js"
click node_symbolsui "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/symbols-app.js"
click node_resolutionui "https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/resolution-app.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_main,node_preprocessor,node_ast,node_symbols,node_resolution,node_browser toneBlue
class node_coverage,node_layout,node_access toneAmber
class node_product,node_writer toneMint
class node_treeui,node_astui,node_symbolsui,node_resolutionui toneRose
class node_engineer,node_source toneIndigo
```

## Components

### COBOL analysis

- [Explorer entry](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/ExplorerMain.java): `src/main/java/io/github/gustavo2358/cobolexplorer/ExplorerMain.java`
- [COPY preprocessing](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/PreprocessorEngine.java): `src/main/java/io/github/gustavo2358/cobolexplorer/PreprocessorEngine.java`
- [AST construction](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/AstBuilder.java): `src/main/java/io/github/gustavo2358/cobolexplorer/AstBuilder.java`
- [Symbol tables](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/CompilationUnitSymbolTableBuilder.java): `src/main/java/io/github/gustavo2358/cobolexplorer/CompilationUnitSymbolTableBuilder.java`
- [Reference resolution](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/CobolReferenceResolver.java): `src/main/java/io/github/gustavo2358/cobolexplorer/CobolReferenceResolver.java`

### Semantic facts

- [Semantic coverage](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/SemanticCoverage.java): `src/main/java/io/github/gustavo2358/cobolexplorer/SemanticCoverage.java`
- [Storage layout](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/StorageLayoutSemantics.java): `src/main/java/io/github/gustavo2358/cobolexplorer/StorageLayoutSemantics.java`
- [Storage access facts](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/StorageAccessSemantics.java): `src/main/java/io/github/gustavo2358/cobolexplorer/StorageAccessSemantics.java`

### Products and export

- [Semantic product](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/semanticproduct/CobolSemanticProduct.java): `src/main/java/io/github/gustavo2358/cobolexplorer/semanticproduct/CobolSemanticProduct.java`
- [Page generation](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/java/io/github/gustavo2358/cobolexplorer/semanticproduct/transport/SemanticProductJsonWriter.java): `src/main/java/io/github/gustavo2358/cobolexplorer/semanticproduct/transport/SemanticProductJsonWriter.java`

### Static explorer

- [Parse-tree view](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/app.js): `src/main/resources/web/app.js`
- [AST view](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/ast-app.js): `src/main/resources/web/ast-app.js`
- [Symbols view](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/symbols-app.js): `src/main/resources/web/symbols-app.js`
- [Resolution view](https://github.com/gustavo2358/proleap-poc/blob/main/src/main/resources/web/resolution-app.js): `src/main/resources/web/resolution-app.js`

### Other components

- **Engineer**
- **COBOL source**
- **Local browser**

## Connections

- Engineer → Explorer entry: runs analysis
- COBOL source → Explorer entry: provides input
- Explorer entry → COPY preprocessing: preprocesses COPY
- Explorer entry → AST construction: builds AST
- AST construction → Symbol tables: feeds declarations
- Symbol tables → Reference resolution: supplies names
- AST construction → Semantic coverage: assesses modeling
- Symbol tables → Storage layout: supplies declarations
- Reference resolution → Storage layout: supplies bindings
- Reference resolution → Storage access facts: resolves accesses
- Storage layout → Storage access facts: supplies layout
- Explorer entry → Page generation: generates artifacts
- Page generation → Semantic product: writes product data
- Local browser → Parse-tree view: opens page
- Local browser → AST view: opens page
- Local browser → Symbols view: opens page
- Local browser → Resolution view: opens page
