I'm trying to create a program with this criteria: - Your program is to print the following prompt to the terminal: Enter the date as: mm/dd/yyyy Your program can expect that mm, dd, and yyyy will be decimal digits. Your program will check whether the input represents a valid date: Day: correct for the given month (check days per month and leap year issues for February) Month: a value from 1 - 12 Year: a value between 15 Hint: You will have to use Delimiter("/*"); to enable the Scanner to work correctly.Examples: Enter the date as: mm/dd/yyyy 1/1/2010: Valid ------------------------- Enter the date as: mm/dd/yyyy 13/41/1734: Invalid: Day, Month this is what I have so far I just need a step in the right direction But you are using next Int in order to obtain the three numbers individually.The source code is compiled and tested in my dev environment.
All examples given here are as simple as possible to help beginners.There are few cases in which an invalid date can be inputted.For example, when a month with 30 days is selected along with day: 31.The Bean Validation model is supported by constraints in the form of annotations placed on a field, method, or class of a Java Beans component, such as a managed bean. User-defined constraints are called custom constraints. Several built-in constraints are available in the tag.Any managed bean that contains Bean Validation annotations automatically gets validation constraints placed on the fields on a Java Server Faces application’s web pages.