I want your program to catch two exceptions that are generated by the Scanner class's nextInt method:
I also want you to make use of the finally clause to count the total number of tokens. Because I want you to keep calling nextInt until the input is exhausted you may overcount the number of tokens by 1, in which case you will need to subtract 1 from the total number of tokens at the end of your program. If you want to check the output of your program you can run my sample executable:
java -cp .:..:/home/cs365/www-home/hw/hw5 myException
The program should use the Integer class's parseInt method to convert the command line arguments to integers and it should use a try/catch block to catch a NumberFormatException if any of the three arguments cannot be converted to an integer.
The application should place the increment button in the west region of the display, the slider in the center region, the decrement button in the east region, and the value label in the north region. If the user presses the increment button and the value is already at the maximum allowable value for the slider then the application should pop up a message dialog indicating that the value cannot be further incremented. A similar message should be displayed if the user attempts to decrement the value when it is already at its minimum value.
If you have questions about how your interface should look or behave, you can use the following commands to copy my SliderApp class files to your home file system and then run it:
cp /home/cs365/www-home/hw/hw5/*.class . java SliderApp minValue maxValue startValue