Professional Documents
Culture Documents
1 - Konsep Obyek Dan Class
1 - Konsep Obyek Dan Class
1 - Konsep Obyek Dan Class
BAYU PRIYAMBADHA
TUJUAN PERKULIAHAN
• Object
• Class
• 4 Pilars of OOP
• OOP Vs Procedural (Structural)
Object???
OBJECT
• an object is a thing.
• tangible and intangible, that we can imagine.
• A program written in object-oriented style will consist of interacting objects.
Encapsulation
Modularity
Object Orientation
Hierarchy
ABSTRACTION
• The essential characteristics of an entity that distinguishes it from all other kinds of entities.
• Defines a boundary relative to the perspective of the viewer.
• Example :
• When you are at school, then you are a"Student". When you are at work, you are an "Employee".
When you are at government institution, you can be viewed as a "Citizen". So it boils down to what in
what context are we looking at an entity/object. So if I am modelling a Payroll System, I will look at you
as an Employee(PRN, Full Time/Part Time, Designation). If am modelling a Course Enrollment System, then I
will consider your aspects and characteristics as a Student(Roll Number, Age, Gender, Course Enrolled).
And if I am modelling a Social Security Information System then I will look at your details as aCitizen(like
DOB, Gender, Country Of Birth, etc.)
ENCAPSULATION
Course
Catalog
System
Course Registration
System Student
Management
System
HIERARCHY
Increasing Asset
abstraction