Skip to main content

What is Object oriented programming

What is Object oriented?


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.

The programming challenge was seen as how to write the logic, not how to define the data. Object-oriented programming takes the view that what we really care about are the objects we want to manipulate rather than the logic required to manipulate them. Examples of objects range from human beings described by name, address, and so forth to buildings and floors whose properties can be described and managed down to the little widgets on a computer desktop such as buttons and scroll bars.

The first step in OOP is to identify all the objects the programmer wants to manipulate and how they relate to each other, an exercise often known as data modeling. Once an object has been identified, it is generalized as a class of objects think of Plato's concept of the "ideal" chair that stands for all chairs which defines the kind of data it contains and any logic sequences that can manipulate it. Each distinct logic sequence is known as a method. Objects communicate with well-defined interfaces called messages.

The concepts and rules used in object-oriented programming provide these important benefits:

ü  The concept of a data class makes it possible to define subclasses of data objects that share some or all of the main class characteristics. Called inheritance, this property of OOP forces a more thorough data analysis, reduces development time, and ensures more accurate coding.

ü  Since a class defines only the data it needs to be concerned with, when an instance of that class an object is run, the code will not be able to accidentally access other program data. This characteristic of data hiding provides greater system security and avoids unintended data corruption.
ü  The definition of a class is re useable not only by the program for which it is initially created but also by other object-oriented programs and, for this reason, can be more easily distributed for use in networks.

ü  The concept of data classes allows a programmer to create any new data type that is not already defined in the language itself.

Simula was the first object-oriented programming language. Java, Python, C++, Visual Basic .NET and Ruby are the most popular OOP languages today. The Java programming language is designed especially for use in distributed applications on corporate networks and the Internet. Ruby is used in many Web applications. Curl, Smalltalk, Delphi and Eiffel are also examples of object-oriented programming languages.

OOPSLA is the annual conference for Object-Oriented Programming Systems, Languages and Applications.

Advantages of Object Oriented Programming:

1.      Code Reuse and Recycling: Objects created for Object Oriented Programs can easily be reused in other programs.

2.      Encapsulation (part 1): Once an Object is created, knowledge of its implementation is not necessary for its use. In older programs, coders needed understand the details of a piece of code before using it (in this or another program).

3.      Encapsulation (part 2): Objects have the ability to hide certain parts of themselves from programmers. This prevents programmers from tampering with values they shouldn't. Additionally, the object controls how one interacts with it, preventing other kinds of errors. For example, a programmer (or another program) cannot set the width of a window to -400.
4.      Design Benefits: Large programs are very difficult to write. Object Oriented Programs force designers to go through an extensive planning phase, which makes for better designs with fewer flaws. In addition, once a program reaches a certain size, Object Oriented Programs are actually easier to program than non-Object oriented ones.

5.      Modifiability: it is easy to make minor changes in the data representation or the procedures in an OO program. Changes inside a class do not affect any other part of a program, since the only public interface that the external world has to a class is through the use of methods;

6.      Extensibility: adding new features or responding to changing operating environments can be solved by introducing a few new objects and modifying some existing ones;

7.      Maintainability: objects can be maintained separately, making locating and fixing problems easier;

8.      Re-usability: objects can be reused in different programs.

Disadvantages Object Oriented Programming:

1.      Takes more memory, so it causes the system to run slower. For an example creating and destroying objects take more memory and causes the system to slow.


2.      In an optimal design, little support is given to identify the objects. 

Comments

Popular posts from this blog

Types of Network Topologies Alternatively referred to as a network topology, a topology is the physical configuration of a network that determines how the network's computers are connected. Common configurations include the Bus topology, Mesh topology, Ring topology, Star topology, Tree topology and Hybrid topology. See each of these topologies Bus Topology A bus topology is a type of network setup where each computer and network device is connected to a single cable or backbone. Below is a visual example of a simple computer setup on a network using the bus topology. Mesh Topology A network setup where each computer and network device is interconnected with one another, allowing for most transmissions to be distributed, even if one of the connections go down. This topology is not commonly used for most computer networks as it is difficult and expensive to have redundant connection to every computer. However, this topology is commonly used for wireless networks. Belo...

What is java

What is java?   Ø   Java is a programming language expressly designed for use in the distributed environment of the Internet. It was designed to have the "look and feel" of the C++ language, but it is simpler to use than C++ and enforces an object-oriented programming model. Java can be used to create complete applications that may run on a single computer or be distributed among servers and clients in a network. It can also be used to build a small application module or applet for use as part of a Web page. Applets make it possible for a Web page user to interact with the page. The major characteristics of Java are: Ø   The programs you create are portable in a network. (See portability.) Your source program is compiled into what Java calls bytecode, which can be run anywhere in a network on a server or client that has a Java virtual machine. The Java virtual machine interprets the bytecode into code that will run on the real computer hardware. This means ...

Network Types

Network Types: Networking is required to make accessible communication between computers possible by a network connection. Networking allows for many possibilities, such as accessing the internet, file sharing, file transferring, networks attacks and system communication. Let’s look at the different types of networking ways in detail. Different types of (private) networks are distinguished based on their size (in terms of the number of machines) their data transfer speed and their reach. Private networks are networks that belong to a single organization. There are usually said to be Five categories of networks: 1.        Personal area network - PAN 2.       Local area network – LAN 3.       Wireless Local Area Networks – WLAN 4.       Metropolitan area network - MAN 5.       Wide area network - WAN Bluetooth (Personal Area Network) Bluetooth is a wirel...