Subclasses of Calendar
Let's take a step back and assume, perhaps rightfully so, that we didn't know what Calendar options were available to us. This is one of the times when working with an IDE (Integrated Development Environment), such as NetBeans here, can be really amazing.
Normally, at this point in time, we'd have to take a trip to the Java documentation to see exactly what subclasses of Calendar are available for us to instantiate. But because our IDE knows some metadata about the packages that we've already imported, we can ask our IDE what it thinks might be a possible solution for our code. If you're working in NetBeans, you can get these kinds of suggestions very often by checking some of the Code Completion options from Tools ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access