Skip to content

NgMinPhuc/Convert-Project

Repository files navigation

C to Java Code Converter

A powerful tool that automatically converts C/C++ code to Java, featuring a modern GUI interface and intelligent code transformation.

📚 Documentation

  1. Introduction

    • Project Overview
    • Features
    • Screenshots
    • Requirements
  2. Usage Guide

    • Installation
    • Quick Start
    • GUI Interface
    • Common Operations
  3. Technical Details

    • ANTLR4 Grammar
    • Conversion Process
    • Code Analysis
    • AST Transformation
  4. Architecture

    • Project Structure
    • Component Design
    • Class Diagrams
    • Data Flow
  5. Code Documentation

    • Core Components
    • Key Classes
    • Important Functions
    • Extension Points
  6. Examples & Support

    • Sample Conversions
    • Supported Features
    • Known Limitations
    • Troubleshooting

🚀 Quick Start

  1. Prerequisites

    # Install Python 3.8+
    python --version
    
    # Install Java (for ANTLR)
    java -version
  2. Installation

    # Clone repository
    git clone https://github.com/NgMinPhuc/Convert-Project.git
    cd Convert-Project
    
    # Create virtual environment
    python -m venv venv
    source venv/bin/activate  # or .\venv\Scripts\activate on Windows
    
    # Install dependencies
    pip install -r requirements.txt
    
    # Generate parser
    python generate_parser.py
  3. Run Application

    python main.py

🎯 Features

  • Modern GUI with real-time preview
  • Intelligent code analysis and conversion
  • Automatic type conversion
  • Standard library mapping
  • Detailed conversion reports
  • Support for complex C constructs

🏗 Project Structure

Convert-Project/
├── docs/              # Detailed documentation
├── grammar/           # ANTLR grammar files
├── translator/        # Core translation logic
│   ├── converter.py   # Main converter
│   └── c_listener.py  # ANTLR listener
├── utils/            # Utility functions
├── C.g4              # C grammar definition
├── main.py           # GUI application
└── requirements.txt  # Python dependencies

🤝 Contributing

  1. Nguyen Minh Phuc - ITCSIU22225

🙏 Acknowledgments

  • ANTLR4 for grammar parsing
  • PyQt6 for GUI framework
  • Open source community for inspiration and support

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •