# sadeeshajayaweera/java-practical-codes- architecture

> Architecture diagram of the GitHub repository sadeeshajayaweera/java-practical-codes-, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-05-12). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sadeeshajayaweera/java-practical-codes-
- Repository: https://github.com/sadeeshajayaweera/java-practical-codes-

## Overview

##### Project type and purpose
- This is a Java OOP practice repository. It is not a production service or full-stack app but a collection of code examples and Word-doc exercises organized by OOP topics.

##### File structure
- Top-level folders correspond to core OOP topics: Introduction, Encapsulation, Inheritance, Interfaces, Polymorphism, Exception Handling.
- Each folder contains .java source files and a .docx (or .pdf) showing exercise instructions and explanations.
- There are no deployment scripts, database configs, or external-service stubs. It’s purely code + documentation.

##### README
- Explains that this is a learning repo, listing six topics.
- Mentions that each topic has a Word doc with code snippets and explanations.
- No runtime architecture is described because this is sample code.

##### Detailed breakdown of components
– Developer Environment (parallelogram): user writes code, reads docs.
– Java Compiler (gear): javac → .class files → JVM.
- Introduction: HelloWorld.java, DegreeName.java, etc.
- Encapsulation: Encapsulation.java, EncapTest.java.
- Inheritance: Animal.java, Dog.java, Mammal.java, etc.
- Interfaces: (if present) interface examples.
- Exception Handling: Date.java, DateTest.java, SavingsAccount.java, etc.
- Docs → Developer Environment → Code in Modules → Java Compiler → Runtime.

## Diagram (Mermaid)

```mermaid
flowchart TD
    DevEnv["Developer Environment"]:::env
    JavaComp["Java Compiler (javac)"]:::compiler
    DocStore["Documentation Store"]:::docs

    subgraph "Practical 01 Module"
        Intro["Introduction Module"]:::intro
    end
    subgraph "Practical 3 Module"
        Encaps["Encapsulation Module"]:::encap
    end
    subgraph "Practical 4 Module"
        Inherit["Inheritance Module"]:::inherit
    end
    subgraph "Java Assignment - Polymorphism Module"
        Poly["Polymorphism Module"]:::poly
    end
    subgraph "Java Assignment - Exception Handling Module"
        Except["Exception Handling Module"]:::except
    end

    DevEnv -->|"writes code & reads docs"| DocStore
    DevEnv -->|"invokes"| JavaComp

    DocStore -->|"provides exercises"| Intro
    DocStore -->|"provides exercises"| Encaps
    DocStore -->|"provides exercises"| Inherit
    DocStore -->|"provides exercises"| Poly
    DocStore -->|"provides exercises"| Except

    JavaComp -->|"compiles .java to .class"| Intro
    JavaComp -->|"compiles .java to .class"| Encaps
    JavaComp -->|"compiles .java to .class"| Inherit
    JavaComp -->|"compiles .java to .class"| Poly
    JavaComp -->|"compiles .java to .class"| Except

    click Intro "https://github.com/sadeeshajayaweera/java-practical-codes-/tree/main/Practical 01"
    click Encaps "https://github.com/sadeeshajayaweera/java-practical-codes-/tree/main/Practical 3"
    click Inherit "https://github.com/sadeeshajayaweera/java-practical-codes-/tree/main/Practical 4"
    click Poly "https://github.com/sadeeshajayaweera/java-practical-codes-/tree/main/Java Assignment"
    click Except "https://github.com/sadeeshajayaweera/java-practical-codes-/tree/main/Java Assignment"

    classDef env     fill:#D6E9FE,stroke:#08427B
    classDef compiler fill:#FFE4B3,stroke:#B8860B
    classDef docs    fill:#DFFFD6,stroke:#2E8B57
    classDef intro   fill:#FDE2E2,stroke:#E34234
    classDef encap   fill:#E8DAEF,stroke:#8A2BE2
    classDef inherit fill:#E2F0CB,stroke:#6B8E23
    classDef poly    fill:#FFF5BA,stroke:#DAA520
    classDef except  fill:#E1F5FE,stroke:#4682B4
```
