Java also has a "default" access, which comes into play if you don't use one of the aforementioned specifiers. this is usually called package access because classes can access the members of other classes in the same package (library component), but outside of the package those same Members appear to be private. the "wrapper" classes for the primitive data types allow you to make a non-primitive object on the heap to represent that primitive type.
Java. Lang is implicitly encoded in every Java code file
Constructor may call other construcotr via this internally, but cannot use this to call constructorfinalize () in member functions. When will it be called? There are three cases: 1. All objects are automatically called when they are garbage collection, such as when system. GC () is run. 2. Program The Finalize method is called once for each object upon exit. 3. explicitly call the Finalize method. Normally, when an object is collected as useless information by the system, finalize () is automatically called, but the JVM does not guarantee finalize () it must be called. That is to say, the call to finalize () is uncertain. That is why Sun does not advocate the use of finalize () because they are in the same directory and have no explicit package name. java treats files like this as implicitly part of the "Default package" for that directory, and thus they provide package access to all the other files in that directory. protected also gives package access-that is, other classes in the same package may access protected elementsthe actual process of initialization is: 1.The storage allocated for the object is initialized to binary zero before anything else happens.2.the base-class constructors are called as described previusly. at this point, the overridden draw () method is called (yes, before the roundglyph constructor is called), which discovers a radius value of zero, due to step 1.3.member initializers are called in the order of declaration.4.the body of the derived-class constructor is called.
@ Override
When you mean to override a method, you can choose to add this annotation and the compiler will produce an error message if you accidentally overload instead of overriding