A project that was issued by my college professor based on the book "A Student Guide to Object-Oriented Development", by Carol Britton and Jill Doake.
The book is an introductory text that follows the software development process, from requirements capture to implementation, using an object-oriented approach. The book uses object-oriented techniques to present a practical viewpoint on developing software, providing the reader with a basic understanding of object-oriented concepts by developing the subject in an uncomplicated and easy-to-follow manner. The book outlines standard object-oriented modelling techniques and illustrates them with a variety of examples and exercises, using UML as the modelling language and Java as the language of implementation. It adopts a simple, step by step approach to object-oriented development, and includes case studies, examples, and exercises with solutions to consolidate learning.
Our main task was to add a feature into the finalized offered code, which simulated a bike rental shop system. However, more than a couple things bothered me right from the start:
-
All of the variables and values (total price, daily ongoing rate, bike models, etc) were hardcoded and didn't offer any means of updating the data...
... which, in a real-world scenario, simply does not work.
-
Because of that, there was no way to receive user inputs and no way to interact with the system.
-
In a real-world setting, at least some sort of confirmation would be required at the end of the transaction.
With all of that in mind, I decided to work on polishing a bit of the code.
Firstly, I came up with a simple GUI using Java's Swing, allowing the user to interact with the system.
Secondly, I used Apache PDFBox to create and save a PDF receipt model, so that the user can print it and hand it over to the customer, as a way of keeping track of the transactions. The file is saved into the main root folder.
Lastly, I decided to add some statistics to the system, so that the store had a way of knowing which was the most rented bike model or the most frequent customer. This is a good business practice cause it allows managers to have a better understanding of their business and how to improve based upon that. However, at this time the data is only saved locally.
- Implement SQL database integration