# bellmcp/decibel-airlines-reservation-system architecture

> Architecture diagram of the GitHub repository bellmcp/decibel-airlines-reservation-system, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-03-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/bellmcp/decibel-airlines-reservation-system
- Repository: https://github.com/bellmcp/decibel-airlines-reservation-system

## Overview

This repository is a standalone Java desktop application for airline seat reservation, packaged as a NetBeans project and built with Ant. The architecture is centered on a Swing-based GUI with a small set of domain classes behind it, rather than a separate server/database backend.

Main subsystems

1. Presentation layer: NetBeans-generated Swing forms
- `main.java` / `main.form`: the entry screen or landing window for the reservation system.
- `RegisterForm.java` / `RegisterForm.form`: collects passenger and booking information.
- `Confirmation.java` / `Confirmation.form`: confirms a booking or seat assignment.
- `Cancellation.java` / `Cancellation.form`: handles seat cancellation.
- `ShowData.java` / `ShowData.form`: displays reservation/seat data in a table or read-only view.
- `About.java` / `About.form`: informational screen about the application.

These forms are the user-facing boundary of the system. The `.form` files indicate the UI was designed visually in NetBeans, and the app relies on the generated Swing layout code. The bundled `AbsoluteLayout.jar` in `dist/lib` suggests the UI uses absolute positioning rather than a more adaptive layout manager.

2. Domain/model layer
- `Seat.java`
- `Flight.java`

These classes likely represent the core reservation state: seat identity, availability, passenger assignment, and flight-related data. Based on the README, seat operations such as `CancelSeat`, `ConfirmSeat`, `UpdateSeat`, and `ShowData` are implemented through object-oriented interaction with these classes.

3. Workflow/control logic
The application appears to be event-driven, with each form triggering actions that update shared reservation state and then transition to another form or refresh a display.

Typical flow:
- User starts in `main`
- User enters booking details in `RegisterForm`
- The app creates or updates a seat/flight object
- `Confirmation` is used to finalize the reservation
- `ShowData` displays current booking state
- `Cancellation` reverses or clears a reservation when needed

This is a client-only workflow: there is no visible service layer, API layer, or database layer in the repository structure.

4. Output/artifact generation
- `dist/A1_broadingPass.txt`
- `dist/E5_broadingPass.txt`

These files show that the app can emit boarding-pass-like text artifacts. That implies a file-generation path in the application where booking state is serialized into a printable text output. The README also references `SaveBoardingPass` and `SaveData`, which strongly suggests local file output is one of the app’s key persistence mechanisms.

5. Build and packaging
- `build.xml`, `nbproject/*`: NetBeans/Ant build configuration
- `dist/DecibelAirline.jar`: packaged runnable application
- `manifest.mf`: JAR entry-point metadata

This is a self-contained desktop distribution. The runtime dependency footprint is small and local; the only explicit external library visible in the tree is `AbsoluteLayout.jar`, used for GUI layout.

Data flow and boundaries

- Input boundary: the user interacts through Swing forms.
- State boundary: reservation state is held in Java objects (`Seat`, `Flight`) and passed between forms.
- Display boundary: `ShowData` and `Confirmation` present the current state back to the user.
- File/output boundary: boarding pass text files are generated in the distribution/output area, providing a durable local artifact.
- No evidence of network, database, or multi-user synchronization appears in the repository structure.

Architectural summary

This is a single-process, monolithic desktop reservation system:
- UI-centric
- form-driven navigation
- object-based seat/flight state
- local file output for boarding passes and saved data
- built and packaged via NetBeans/Ant

If you are drawing an architecture diagram, the cleanest decomposition is:
- Top: Swing UI forms
- Middle: reservation workflow and domain objects
- Bottom/right: local file output and packaged JAR/runtime dependencies

One useful note: the repository reflects a school/project-style desktop app rather than an enterprise booking platform. The README’s “future ideas” section also confirms that multi-flight management, database persistence, and admin authentication are not yet part of the implemented architecture.

Main entry points: [`src/seat/RegisterForm.java`](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/RegisterForm.java) (Register), [`src/seat/Confirmation.java`](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/Confirmation.java) (Confirm), [`build.xml`](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/build.xml) (Ant build), [`src/seat/ShowData.java`](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/ShowData.java) (Show data)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph "UI forms"
  main["Home<br/>Swing entry<br/>[main.java]"]
  register_form["Register<br/>Swing form<br/>[RegisterForm.java]"]
  confirmation["Confirm<br/>Swing form<br/>[Confirmation.java]"]
  cancellation["Cancel<br/>Swing form<br/>[Cancellation.java]"]
  show_data["Show data<br/>Swing form<br/>[ShowData.java]"]
  about["About<br/>Swing form<br/>[About.java]"]
end

subgraph "Domain"
  seat[("Seat<br/>Domain model<br/>[Seat.java]")]
  flight[("Flight<br/>Domain model<br/>[Flight.java]")]
  reservation_state(("Reservation state<br/>Workflow state"))
end

subgraph "Build & output"
  ant_build["Ant build<br/>Build system<br/>[build.xml]"]
  nbproject["NetBeans config<br/>Project metadata<br/>[project.xml]"]
  app_jar["App JAR<br/>Runnable artifact<br/>[DecibelAirline.jar]"]
  boarding_passes["Pass files<br/>Output files"]
  absolute_layout["Layout lib<br/>External jar<br/>[AbsoluteLayout.jar]"]
end

main -->|"start booking"| register_form
main -->|"info"| about
register_form -->|"capture"| reservation_state
register_form -->|"assign seat"| seat
register_form -->|"select flight"| flight
register_form -->|"submit"| confirmation
confirmation -->|"finalize"| reservation_state
confirmation -->|"view data"| show_data
cancellation -->|"clear"| reservation_state
cancellation -->|"refresh"| show_data
show_data -->|"read"| reservation_state
reservation_state -->|"save"| boarding_passes
ant_build -->|"package"| app_jar
nbproject -->|"configure"| ant_build
ant_build -->|"depends on"| absolute_layout
app_jar -.->|"runtime output"| boarding_passes

click main "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/main.java"
click register_form "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/RegisterForm.java"
click confirmation "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/Confirmation.java"
click cancellation "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/Cancellation.java"
click show_data "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/ShowData.java"
click about "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/About.java"
click seat "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/Seat.java"
click flight "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/src/seat/Flight.java"
click ant_build "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/build.xml"
click nbproject "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/nbproject/project.xml"
click app_jar "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/dist/DecibelAirline.jar"
click boarding_passes "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/dist/A1_broadingPass.txt"
click absolute_layout "https://github.com/bellmcp/decibel-airlines-reservation-system/blob/master/dist/lib/AbsoluteLayout.jar"

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 main,register_form,confirmation,cancellation,show_data,about toneBlue
class seat,flight,reservation_state toneAmber
class ant_build,nbproject,app_jar,boarding_passes,absolute_layout toneMint
```

## Components

### UI forms

Swing screens and NetBeans-generated desktop UI

- [Home](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/main.java): Swing entry · Landing window for the reservation app · `src/seat/main.java`
- [Register](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/RegisterForm.java): Swing form · Collects passenger and booking details · `src/seat/RegisterForm.java`
- [Confirm](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/Confirmation.java): Swing form · Finalizes a booking or seat assignment · `src/seat/Confirmation.java`
- [Cancel](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/Cancellation.java): Swing form · Handles seat cancellation · `src/seat/Cancellation.java`
- [Show data](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/ShowData.java): Swing form · Displays reservation or seat data · `src/seat/ShowData.java`
- [About](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/About.java): Swing form · Application information screen · `src/seat/About.java`

### Domain

Core reservation objects and workflow state

- [Seat](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/Seat.java): Domain model · Represents seat state and assignment · `src/seat/Seat.java`
- [Flight](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/src/seat/Flight.java): Domain model · Represents flight-related reservation context · `src/seat/Flight.java`
- **Reservation state**: Workflow state · Shared booking data passed between forms

### Build & output

Ant/NetBeans packaging and local artifacts

- [Ant build](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/build.xml): Build system · NetBeans Ant project build pipeline · `build.xml`
- [NetBeans config](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/nbproject/project.xml): Project metadata · Generated NetBeans project configuration · `nbproject/project.xml`
- [App JAR](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/dist/DecibelAirline.jar): Runnable artifact · Packaged desktop application · `dist/DecibelAirline.jar`
- [Pass files](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/dist/A1_broadingPass.txt): Output files · Local boarding-pass text artifacts · `dist/A1_broadingPass.txt`
- [Layout lib](https://github.com/bellmcp/decibel-airlines-reservation-system/blob/HEAD/dist/lib/AbsoluteLayout.jar): External jar · Swing absolute positioning dependency · `dist/lib/AbsoluteLayout.jar`

## Connections

- Home → Register: start booking · User moves from landing screen into booking entry
- Home → About: info · Landing screen can open the about screen
- Register → Reservation state: capture · Form populates shared booking state
- Register → Seat: assign seat · Booking details update seat allocation
- Register → Flight: select flight · Booking is associated with a flight
- Register → Confirm: submit · Completed booking advances to confirmation
- Confirm → Reservation state: finalize · Confirmation reads and finalizes reservation state
- Confirm → Show data: view data · Confirmed booking can be displayed
- Cancel → Reservation state: clear · Cancellation removes or resets reservation state
- Cancel → Show data: refresh · Updated state can be shown after cancellation
- Show data → Reservation state: read · Read-only view of current reservation data
- Reservation state → Pass files: save · Booking state is written to local boarding-pass text files
- Ant build → App JAR: package · Ant build produces the runnable JAR
- NetBeans config → Ant build: configure · NetBeans project metadata drives the build
- Ant build → Layout lib: depends on · Build includes the layout library for Swing forms
- App JAR → Pass files: runtime output · Packaged app produces local text artifacts
