Simple console application to park, list and search vehicles in a fixed-capacity garage. Built in C# targeting .NET 10.
- Park and remove vehicles (
Car,Motorcycle,Bus,Airplane,Boat) - Search and filter vehicles by attributes (
color,type,regnr,make,model) - List vehicles and counts by type
- Optional demo data population
- .NET 10 SDK
- Visual Studio 2026 (or any editor that supports .NET 10)
- C# language version 14.0
- Open the solution in Visual Studio 2026 and build.
- Or use the .NET CLI:
- Restore & build:
dotnet build - Run:
dotnet run --project Garage
- Restore & build:
When the app starts it will ask for a garage capacity and (optionally) whether to populate demo vehicles.
The app reads configuration values via Microsoft.Extensions.Configuration. Example settings:
demo(boolean) — defaultfalse. Iftruethe app will offer to populate demo vehicles on startup.
Place configuration in appsettings.json.
Garage/— core domain and application codeGarage.cs— genericGarage<T>storage implementationManager.cs— application flow, menus and user interactions
Garage/UserInterface/IUserInterface.cs— abstraction used by the console UI and testsMenu.cs— menu model used byManager
Garage/Vehicles/— vehicle types and baseVehicleclassLICENSE— project license (MIT)
- Registration numbers must be unique. The app enforces uniqueness and capacity limits.
Manageruses the configuration keydemoto control demo population.- The UI is abstracted via
IUserInterfaceto allow easy testing or substitution.
This project is released under the MIT License. See LICENSE for details.