Java   View all facts   Glossary   Help
specification > class > descendent
Next classException class    Upclass    Previous classcore class   

descendent comparison table
Subject have syntax rule add declare protect is a subtopic of name after access extend provide create using place in represent inherit contain have access mode have example instantiate you implement import from order is a kind of be a descendant of define specify by have access modifier hide have example of creation use override have syntax have benefit be a member of have have part has definition be
subclass
bold = mandatory
italic = non-terminal
normal font = optional
0 or more methods to the methods it inherits from its superclassa list of variables, called instance variables, corresponding to data that will be present in each instanceits members from access by other classes or objects using an access modifierClassesthe internals of a computer system such as 'Record', 'Table', 'Data', 'Structure', or 'Information'overridden methods using the keyword superonly one superclassimplementation for all its instance methods unless the class is abstractthe extends keywordits own source fileseveral similar objectsnone, some or all of its state from all its ancestorsdata associated with each object 
public class HelloWorld {
public static void main(String[] args) {
System.out.println("Hello World!");
}
}
create an instance of itmore than one interfacea packageelements as follows:
  1. class variables
  2. instance variables
  3. constructors
  4. the most important public methods
  5. methods that are simply used to access variables
  6. private methods
descendentObject classuntil its direct superclass has been defined1 class definitionan inherited member variable by declaring a member variable with the same name
public class Movie extends Attraction
any member that is inheritedany method that is declared final in the superclass
class classname
{ // declarations of variables
// declarations of constructors
// declarations of other methods with public ones first
}
1 named package rather than the default packagea unique name since somebody in the future might want to import the packages containing both classes and hence create a name clashconstructorA class that is an extension of another class, and hence inherits from the other classthe unit of data abstraction in an object-oriented program

Next classException class    Upclass    Previous classcore class