java basic oops concept

Post on 24-Dec-2014

341 Views

Category:

Education

1 Downloads

Preview:

Click to see full reader

DESCRIPTION

Java Basic Oops Concept with short and neat example and diagrams www.atozknowledge.com Technology in tamil

TRANSCRIPT

JAVA

www.atozknowledge.com

atozknowledge.com@gmail.com www.atozknowledge.com

OOPS

atozknowledge.com@gmail.com www.atozknowledge.com

OOPS

▪ Class

▪ Object

▪ Abstraction

▪ Inheritance

▪ Interface

▪ Encapsulation

▪ Polymorphism

atozknowledge.com@gmail.comwww.atozknowledge.com

Identity

State

Behavior

Class

▪ Class is logical entity

▪ Class contain set of objects or collection of objects

atozknowledge.com@gmail.comwww.atozknowledge.com

Objects

▪ Objects are real time entity

▪ Identify the object by its ▪ Identity

▪ State

▪ Behavior

atozknowledge.co

m@gmail.com

www.atozknowledge.com

Abstraction

▪ The general meaning for abstraction is ELIMINATION i.e fetching only the wanted information even though all information is available based on our need we are eliminating the unwanted information.

atozknowledge.co

m@gmail.com

www.atozknowledge.com

Inheritance

▪ When one Class extends another Class. Deriving new class from the existing class parent child relationship

Two types

▪ Single level

▪ Multi level

atozknowledge.com@gmail.comwww.atozknowledge.com

Cont..

Single level

Deriving a new class from the existing class(one to one)

Example

class A

{

}

class B extends class A

{

}

atozknowledge.com@gmail.comwww.atozknowledge.com

Cont..

Multi Level

Deriving multilevel of new class from the parent

Example

class A{

}

class B extends class A {

}

class C extends class B{

}

atozknowledge.com@gmail.comwww.atozknowledge.com

Interface

▪ Replacement of multiple inheritance that has methods and method definition and no implementation

atozknowledge.com@gmail.comwww.atozknowledge.com

Polymorphism

▪ The general meaning for POLY — many MORPHISM — behavior. Two types of polymorphism.

atozknowledge.com@gmail.comwww.atozknowledge.com

Encapsulation

▪ Encapsulation is a process of wrapping code and data together into a single unit e.g. capsule i.e mixed of several medicines.

atozknowledge.com@gmail.comwww.atozknowledge.com

atozknowledge.com@gmail.comwww.atozknowledge.com

Thank you

For queries atozknowledge.com@gmaol.com

Subscribe our youtube channel and like us at facebook

top related