Skip to content

Latest commit

 

History

12 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Travel Management App

Overview

Travel Management App is a JavaFX-based desktop application for managing tourism operations such as attractions, tourists, guides, and bookings. It uses a clean separation between controllers, models, repositories, and utilities, with file-based persistence for simplicity and transparency.

The application supports authentication, session handling, basic statistics, multilingual UI, and theming. It is built with Java and Maven, and uses JavaFX with FXML for the UI layer. The structure is designed to be understandable and easy to extend for experienced developers.


Techniques and Patterns

  • JavaFX with FXML-based UI composition UI layouts are defined declaratively using FXML files under src/main/resources/com/example/app. Controllers handle logic separately, keeping layout and behavior decoupled. JavaFX FXML documentation: https://openjfx.io/javadoc/

  • Controller-driven MVC-style structure The project follows a pragmatic MVC-style separation:

    • controller for UI logic
    • model for domain entities
    • repo for data access
    • util for shared utilities
  • Plain-text persistence layer Application data is stored in text files under app-data and managed via utilities like FileHandler. This keeps data flow explicit and easy to inspect.

  • Password hashing utilities Authentication avoids plain-text passwords by using helpers such as PasswordHashGenerator and PasswordUtils.

  • Session management User state is centralized in Session, reducing duplicated state handling across controllers.

  • Internationalization (i18n) Language support is implemented using Java ResourceBundle property files:

  • Runtime language switching The LangSwitch utility enables changing UI language at runtime, which requires careful state and view updates in JavaFX.

  • Custom JavaFX theming Styling is controlled via JavaFX CSS in styles/nepali-theme.css. JavaFX CSS reference: https://openjfx.io/javadoc/


Technologies and Libraries


Project Structure

/
├── .idea
├── .mvn/wrapper
├── app-data
├── src/main
├── mvnw
├── mvnw.cmd
├── pom.xml

Directory Notes

  • .mvn/wrapper/ — Maven Wrapper binaries and configuration
  • app-data/ — Plain-text storage for users, tourists, guides, bookings, and attractions
  • src/main/java/ — Controllers, models, repositories, utilities, and application entry point
  • src/main/resources/ — FXML views, styles, fonts, images, and localization files

Notable subdirectories inside resources:

  • Fonts/ — Embedded font assets
  • images/ — UI background and dashboard images
  • styles/ — JavaFX CSS themes
  • com/example/app/ — FXML view files

Build and Run

From the repository root:

./mvnw clean javafx:run

On Windows:

mvnw.cmd clean javafx:run

Extending the Project

This project is intentionally straightforward. Common next steps include:

  • Replacing text-file persistence with a database
  • Introducing repository interfaces
  • Adding automated tests
  • Improving validation and error handling
  • Packaging as a native desktop application

License

No license is currently specified. Add one if you plan to reuse or distribute this code.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages