Rabu, 07 April 2010

Object-oriented programming (OOP)

Object-oriented programming is a programming paradigm to the object-oriented object orsomething. All data and functions in the place or classroom-object-oriented classes. Compare with structured programming logic. Each object can receive messages, process data, and send messages to other objects. Using OOP do so in solving a problem we do not see how to solve a problem (structured) objects but what can be done solving the problem. For example, assume we have a department that has a manager, secretary, clerk and other data. Suppose the manager wants to obtain data from the administration bag is not the manager have to take it directly but can be ordered administration officials to retrieve bags. In the case of a manager does not have to know how to retrieve the data but the manager can get the data via object administration officer. So to solve a problem with collaboration among the objects that exist because every object has his own job description.
Object-oriented programming consists of several classes :
  1. Class is a collection of definitions of data and functions in a unit for a particular purpose.
  2. Object to wrap the data and functions together as a unit in a computer program; object is the basis of modularity and structure in an object-oriented computer program.
  3. Abstraction is the ability of a program to pass information processing aspects of it, namely the ability to focus on the core. Every object in the system serve as a model of the "actors" who can do abstract work, reports and changes in circumstances, and communicate with other objects in the system, without disclosing how the excess is applied. Processes, functions or methods can also be made abstract.
  4. Ensuring users encapsulation for an object can not change the state of an object in a way that is not feasible; only method in which the object is given permission to access the situation. Each object access interface that mentions how other objects can interact with it. Other objects will not know and depend on the representation of the object.
  5. Inheritas to Organize polymorphism and encapsulation by allowing objects to be defined and created a special type of object already exists - these objects can share (and expand) their behavior without re-touching to implement such behavior (object-based languages do not always have inheritas).
The main focus on the functions and procedures that operate on the data, Fokus functions and procedures that operate on the data Big, Program program is divided into small units called functions, Data and functions are treated as separate entities, Data freely move around the system from one other function. The following design, Program "Top Down Approach". fokus the data being operated and do not function or procedure, Programs divided into what are called objects, Data and joint function are treated as separate entities, Data hidden and can not be accessed by external functions, The following design, Program "Bottom Up Approach".

Tidak ada komentar:

Posting Komentar

.::BY JUMBHO-MY AT HOME IN THE JEPARA CITY OF BEAUTIFUL::.