Tuesday, July 4, 2017

OOPs Learning


1. What is oops
2. Inheritance- You are inheriting something
    Do Not repeate 
3. Encapsulation - We set Access Level
   -  Private can use within class
   - Protected can use for inherit class
   - public can use anyone

4. Abstract classses
   - Means Incomplete
   - Declare with Abstract
No Base Employee -
- No Object created for base class
- It uses for enforcement


5. Interfaces
  its works like abstract class
  Why Use
  Multiple class do not extends
  No variable declaration
 No constructor
You can not make private   function

6. Static Variable and Static Method
No Object Creation  required
Scope resolution operation required
It is related to class not with object
How many objects created
can call with parent :: getCount

7.Dependency Injection
   - It is design patter like mvc
   - code usability -
   - One Library can use other Library
  - DRY concept - Do not repeat yourself
- Type Hinting
You should not instantiate object inside class
 


 
 






  

 
 

No comments:

Post a Comment