Connect to the Java Foundation (i)
Outline: (1) advanced features of the class
(2) Collection class
(3) Exception handling
(4) Input/output
(5) Swing program Design
Abstract class: Only declares the existence of a method and does not implement its class; An abstract class cannot be instantiated, that is, it cannot create its object;
The syntax format is as follows:
Abstract class class Name { class body}
In the abstract class, there is no practical meaning, the method that must be overridden in the subclass is an abstract method, and the abstract method has only the method declaration and no method implementation;
The basic definition format is as follows:
Abstract < return value > method name (Parameter list)
PS: Abstract methods cannot be modified with private and static
Inner class:
If a class is declared inside a class as an inner class, the inner class can be divided into members inner class, local inner class, Anonymous inner class
Public class outerclass{ publicclass innerclass {... }}
The member variables and member methods of external classes can be used arbitrarily in inner classes, although they are declared private; an instance of an inner class must be bound to an instance of an external class.
Java Fundamentals (ii)