I am in an intro to Java course, and I need to provide a class diagram with my program assignment. I've got the class diagram completed in the way my professor wants it, but my question has to do with access specifications. I have a class for the main program, then a class below it. The main program creates an instance of the lower class. In the lower class I have made all of the fields private and the methods public. In the main class, however, I have never indicated private or public when declaring the variables. If this isn't specified in the source code are the variables public by default? And how do I show these fields in my class diagram (with a '+' for public, a "-" for private, or no access specification at all)?
Thanks in advance for any assistance that anyone may be able to provide!