# dikotl/paal2-lab3 architecture

> Architecture diagram of the GitHub repository dikotl/paal2-lab3, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-08-19). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/dikotl/paal2-lab3
- Repository: https://github.com/dikotl/paal2-lab3

## Overview

##### Project type and purpose
- This is a multi-language laboratory project (Lab3) demonstrating dynamic array operations in C#, F# and VB.NET.
- It consists of:
- Three language-specific class libraries (ClassLibraryCS, ClassLibraryFS, ClassLibraryVB) implementing array operations.
- A Main console application (Main) that ties everything together via a CLI.
- A Tasks library (Tasks) containing assignment tasks or sample data.
- A Tests project exercising the C# implementation.
- The README confirms it’s purely algorithmic/educational, not a client-server or UI-rich system.

##### File structure
- Top-level solution file Lab3.sln orchestrates all projects.
- ClassLibraryCS/FS/VB each contain their own project file and implementation subfolders.
- Main holds the CLI entry point (CliArgs.fs, Main.fsproj, TaskSelectorMenu.fs).
- Tasks is a small C# project with task definitions.
- Tests is an MSTest project targeting only ClassLibraryCS.
- .github/workflows/main.yml for CI build & test.
- README.md documents the lab assignment.

##### README for additional insights
- Blocks 1 & 2 describe requirements for one-dimensional and jagged arrays.

a. Main components
- CLI Application (Main)
- C# Class Library (ClassLibraryCS)
- F# Class Library (ClassLibraryFS)
- VB.NET Class Library (ClassLibraryVB)
- Tasks Library (Tasks)
- Tests Project (Tests)
- External: .NET SDK & Command-Line Environment, GitHub Actions CI

b. Relationships & interactions
- Main → references → ClassLibraryCS, ClassLibraryFS, ClassLibraryVB, Tasks
- Tasks → defines input data or problem statements consumed by Main and libraries
- Tests → references → ClassLibraryCS (validates array operations)
- GitHub Actions → triggers build+test on Lab3.sln

c. Architectural patterns & principles
- Separation of concerns: each language has its own library, Main is language-agnostic CLI.
- Modular design: Tasks are decoupled from implementation details.
- Test-driven: MSTest project validates core C# library.
- CI pipeline ensures cross-language build integrity.

d. Key technologies/frameworks
- .NET Core/SDK, F# scripting
- MSTest testing framework
- GitHub Actions for CI
- CLI argument parsing in F#

##### Detailed capture of essential elements
- Break out each ClassLibrary’s submodules (e.g., Collections, FunctionalOperations in CS) if deep detail is desired.
- Tasks as a shared resource invoked by Main and potentially by tests.
- If documenting I/O variants, group “Console / File / Random generator” as a subcomponent of Main or the libraries that handle input.

Putting it all together:
- Left side: User → CLI (Main: CliArgs, TaskSelectorMenu)
- Center: 3 parallel libraries (CS, FS, VB) each with their own namespaces/folders
- Right: Tasks library feeding input/data models
- Bottom: Tests project targeting ClassLibraryCS
- Top: GitHub Actions (build & test) on Lab3.sln

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% User Interaction
    User["User"]:::external

    %% CLI Application
    subgraph "CLI Application"
        Main["Main (CLI)"]:::cli
        CliArgs["CliArgs.fs"]:::cli
        TaskMenu["TaskSelectorMenu.fs"]:::cli
        Main --> CliArgs
        Main --> TaskMenu
    end

    %% C# Class Library
    subgraph "ClassLibraryCS"
        CSProj["ClassLibraryCS.csproj"]:::cs
        DynArray["DynArray.cs"]:::cs
        Generator["Generator.cs"]:::cs
        Enumerable["Enumerable.cs"]:::cs
        CSProj --> DynArray
        CSProj --> Generator
        CSProj --> Enumerable
    end

    %% F# Class Library
    subgraph "ClassLibraryFS"
        FSProj["ClassLibraryFS.fsproj"]:::fs
        AssemblyInfo["AssemblyInfo.fs"]:::fs
        Coloring["Coloring.fs"]:::fs
        ConsoleUI["ConsoleUI.fs"]:::fs
        Text["Text.fs"]:::fs
        FSProj --> AssemblyInfo
        FSProj --> Coloring
        FSProj --> ConsoleUI
        FSProj --> Text
    end

    %% VB.NET Class Library
    subgraph "ClassLibraryVB"
        VBProj["ClassLibraryVB.vbproj"]:::vb
        RequestHandler["RequestHandler.vb"]:::vb
        VBProj --> RequestHandler
    end

    %% Tasks Library
    subgraph "Tasks Library"
        TasksProj["Tasks.csproj"]:::tasks
        TasksFile["Tasks.cs"]:::tasks
        TasksProj --> TasksFile
    end

    %% Tests Project
    subgraph "Tests Project"
        TestsProj["Tests.csproj"]:::tests
        TestDynArray["TestDynArray.cs"]:::tests
        TestEnumerable["TestEnumerable.cs"]:::tests
        MSTestSettings["MSTestSettings.cs"]:::tests
        TestsProj --> TestDynArray
        TestsProj --> TestEnumerable
        TestsProj --> MSTestSettings
    end

    %% Solution and CI
    Lab3["Lab3.sln"]:::external
    GitHub["GitHub Actions CI"]:::external

    %% Relationships
    User --> Main
    Main --> CSProj
    Main --> FSProj
    Main --> VBProj
    Main --> TasksProj
    TestsProj --> CSProj
    GitHub --> Lab3
    Lab3 --> Main
    Lab3 --> CSProj
    Lab3 --> FSProj
    Lab3 --> VBProj
    Lab3 --> TasksProj
    Lab3 --> TestsProj

    %% Click Events
    click CliArgs "https://github.com/dikotl/paal2-lab3/blob/main/Main/CliArgs.fs"
    click TaskMenu "https://github.com/dikotl/paal2-lab3/blob/main/Main/TaskSelectorMenu.fs"
    click Main "https://github.com/dikotl/paal2-lab3/blob/main/Main/Main.fsproj"
    click CSProj "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryCS/ClassLibraryCS.csproj"
    click DynArray "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryCS/Collections/DynArray.cs"
    click Generator "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryCS/Collections/Generator.cs"
    click Enumerable "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryCS/FunctionalOperations/Enumerable.cs"
    click FSProj "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryFS/ClassLibraryFS.fsproj"
    click AssemblyInfo "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryFS/AssemblyInfo.fs"
    click Coloring "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryFS/Coloring.fs"
    click ConsoleUI "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryFS/ConsoleUI.fs"
    click Text "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryFS/Text.fs"
    click VBProj "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryVB/ClassLibraryVB.vbproj"
    click RequestHandler "https://github.com/dikotl/paal2-lab3/blob/main/ClassLibraryVB/IO/RequestHandler.vb"
    click TasksProj "https://github.com/dikotl/paal2-lab3/blob/main/Tasks/Tasks.csproj"
    click TasksFile "https://github.com/dikotl/paal2-lab3/blob/main/Tasks/Tasks.cs"
    click TestsProj "https://github.com/dikotl/paal2-lab3/blob/main/Tests/Tests.csproj"
    click TestDynArray "https://github.com/dikotl/paal2-lab3/blob/main/Tests/ClassLibraryCS/Collections/TestDynArray.cs"
    click TestEnumerable "https://github.com/dikotl/paal2-lab3/blob/main/Tests/ClassLibraryCS/FunctionalEnumerableOperations/TestEnumerable.cs"
    click MSTestSettings "https://github.com/dikotl/paal2-lab3/blob/main/Tests/ClassLibraryCS/MSTestSettings.cs"
    click GitHub "https://github.com/dikotl/paal2-lab3/blob/main/.github/workflows/main.yml"
    click Lab3 "https://github.com/dikotl/paal2-lab3/blob/main/Lab3.sln"

    %% Styles
    classDef cli fill:#E8F1F2,stroke:#2E8B57,stroke-width:2px
    classDef cs fill:#F2E8E8,stroke:#B22222,stroke-width:2px
    classDef fs fill:#E8EAF2,stroke:#4B0082,stroke-width:2px
    classDef vb fill:#F2F2E8,stroke:#DAA520,stroke-width:2px
    classDef tasks fill:#E8F2E8,stroke:#228B22,stroke-width:2px
    classDef tests fill:#F2E8F2,stroke:#8B008B,stroke-width:2px
    classDef external fill:#FFFFFF,stroke:#000000,stroke-dasharray: 5 5
```
