Abstract class



  1. class that is declared using “abstract” keyword; 
  2. may or may not include abstract methods ( has no body)and concrete methods (methods with body) ;
  3. we can  not allowed to create object of Abstract class,
  4. An abstract class has no use until unless it is extended by some other class ,logic behind structuring inheritance property for project[animal-dog,cow].
  5. it provides partial abstraction only,100% abstraction - interface.
See --
Interface , 
abstraction VS interface 

Access Modifiers 2 – Static,Abstract,Final



Static- Variables are calling Class variables. These members belong to the class not to the object,means values of these variables are not part of the object state.creating its while initiating class, not instance .Final- 

Abstract - 

Final variable is a constant; its value cannot be changed after its initialization.



Access Modifiers – Public, Private, Protected & Default


Public This is the least restrictive,accessible to entire project;

Default If no access modifier is specified in the declaration, accessible only within package,not accessible in other packages or sub packages;

Protected Accessible to all classes in the package and to all sub-classes of its class in any package where this class is visible.

Private -This is the most restrictive accessibility modifiers. These members are accessible only with in the same class.