This README provides an overview of the Watch project, including a description of the project, details about its structure, usage instructions, commands, contributors, licensing information, and acknowledgments.
The Watch project is a Java program that simulates a timekeeping device. It allows users to interact with a virtual watch by entering commands through the console. The project aims to provide basic timekeeping functionality, including setting the time and advancing it by one second.
The project consists of the following Java classes:
-
App
: TheApp
class serves as the main program entry point. It allows users to interact with the virtual watch by entering commands through the console. Users can set the time, advance the time by one second, and display the current time. -
Watch
: TheWatch
class represents a timekeeping device with hour, minute, and second attributes. It provides methods to set and get the time, as well as increment the time by one second.
To use this project, follow the steps below:
-
Setup Instructions:
- Ensure you have Java installed on your system to run this program.
-
Installation:
- No specific installation is required. You can compile and run the program using a Java compiler or an integrated development environment (IDE) like Eclipse or IntelliJ IDEA.
-
How to Run:
- Run the
App
class, which serves as the entry point for the program. It will provide a console interface for entering commands.
- Run the
-
Review Output:
- The program will display the results of the commands you enter, including the current time or error messages for invalid commands.
-
setar [hora] [minuto] [segundo]
: Sets the time on the virtual watch to the specified hour, minute, and second. -
next
: Advances the time on the virtual watch by one second. -
mostra
: Displays the current time on the virtual watch. -
fim
: Exits the program.
This project is licensed under the MIT License. You can find detailed licensing information in the LICENSE.md
file included in the project directory.