Your SlideShare is downloading. ×
0
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
OOP_1_TEG
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

OOP_1_TEG

178

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
178
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
2
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • Good afternoon gentlemen and ladies, I'm so glad to be here. Today we will discuss about OOP. OOP is one of the main courses in the department of information systems. OOP is a new paradigm in programming techniques, almost all programming languages are currently using OOP concepts. The purpose of this course is students can understand the OOP concepts and they can make a program in accordance with the rules of OOP Okay, let's look at our topic today. I'll start from the definition of OOP, the reason why you should use OOP, classes and objects, and access modifier Let's look at the definition of OOP. There are many definitions of OOP. Are there any questions? Well, our class is finished, see you next week. Next week we will discuss about the making method and relationships between classes thank you, happy to learn OOP and success for all of us
  • Transcript

    • 1. Object Oriented Programming Teguh Sutanto Si | STIKOM Surabaya teguh@stikom.edu|+628563076813|http://teguhsutanto.blogspot.com|http://blog.stikom.edu/teguh
    • 2. GOAL
        • Students can understand the Object Oriented Programming concepts
        • Students can make a program in accordance with the rules of Object Oriented Programming
    • 3.  
    • 4. Object-oriented programming (OOP) is a programming paradigm using "objects" – data structures consisting of data fields and methods together with their interactions – to design applications and computer programs
    • 5. Object-oriented programming (OOP) is a programming language model organized around "objects" rather than "actions" and data rather than logic. Historically, a program has been viewed as a logical procedure that takes input data, processes it, and produces output data
    • 6. Why OOP?
        • Object-oriented systems can be easily upgraded from small to large scale.
        • It is easy to partition the work in a project based on objects.
        • Object-oriented programming offers a new and powerful model for writing computer software.
        • It reduces software maintenance and developing costs.
        • Changes in user requirements or later developments have always been a major problem.
        • Object-orientation or object oriented programming (OOP) should help one in developing high quality software easily.
    • 7. Concept of Class and Object
        • “ Class” refers to a blueprint. It defines the variables and methods the objects support
        • “ Object” is an instance of a class. Each object has a class which defines its data and behavior
    • 8. Concept of Class and Object
    • 9. Classes reflect concepts, objects reflect instances that embody those concepts Daria Jane Brittany Jodie girl class object
    • 10.  
    • 11.  
    • 12. Class: A class can have three kinds of members:
    • 13. Attribute/Field/Data Method
    • 14. Field Declaration
        • a type name followed by the field name, and optionally an initialization clause
        • primitive data type vs. Object reference
          • boolean, char, byte, short, int, long, float, double
        • field declarations can be preceded by different modifiers
          • access control modifiers
          • static
          • final
    • 15. Acces Control Modifier
        • private : private members are accessible only in the class itself
        • package : package members are accessible in classes in the same package and the class itself
        • protected : protected members are accessible in classes in the same package, in subclasses of the class, and in the class itself
        • public : public members are accessible anywhere the class is accessible
    • 16. com Person
        • name: String
        • address: String
      • # age: int
      • +getName(): String
      Employee HRD X MainMenu X
    • 17.
      • public class Pencil {
      • public String color = “red”;
      • public int length;
      • public float diameter;
      • private float price;
        • public static long nextID = 0;
        • public void setPrice (float newPrice) {
        • price = newPrice;
        • }
        • }
      • public class CreatePencil {
      • public static void main (String args[]){
      • Pencil p1 = new Pencil();
      • p1.price = 0.5f;
        • }
      • }
      Pencil.java CreatePencil.java %> javac Pencil.java %> javac CreatePencil.java CreatePencil.java:4: price has private access in Pencil p1.price = 0.5f; ^
    • 18.  

    ×