Skip to main content
Back to projects

Case study / Coursework and personal refinement

Java Vending Machine

A Java project focused on object-oriented design, domain modelling, and testable implementation rather than surface-level feature count.

Java vending machine project preview

A focused Java build designed to showcase object-oriented thinking, maintainable structure, and testable behaviour.

[ Problem ]

I wanted a project that made software design quality visible. The goal was not only to simulate a vending machine, but to build it in a way that demonstrated clear modelling, maintainability, and sound object-oriented thinking.

[ Approach ]

01. Modelled the machine around well-scoped responsibilities so inventory, payment handling, and product behaviour stayed understandable and testable.

02. Used the project as a way to practise core Java engineering habits: strong encapsulation, clean abstractions, and careful separation between behaviour and state.

03. Backed the implementation with JUnit tests to show that the design could be verified and evolved instead of existing as one-off coursework code.

[ Technical decisions ]

Domain-first class design

The code is shaped around the responsibilities of the vending domain, which keeps behaviour easier to reason about than a single monolithic implementation.

OOP principles made explicit

Encapsulation, abstraction, inheritance, and polymorphism are visible in the structure of the system rather than being treated as theory only.

Testing as part of design

JUnit coverage helped validate behaviours and reinforced the idea that a clean design should be straightforward to exercise in tests.

[ Outcome ]

  • > Produced a compact project that communicates software engineering fundamentals clearly.
  • > Reinforced habits around modelling, readability, and testability that transfer directly into production codebases.
  • > Created a useful example of how I think about code quality beyond just shipping features.