Object-oriented programming (OOP) is a computer programming model that organizes software design around data, or objects, rather than functions and logic. An object can be defined as a data field that has unique attributes and behavior. Show
OOP focuses on the objects that developers want to manipulate rather than the logic required to manipulate them. This approach to programming is well-suited for programs that are large, complex and actively updated or maintained. This includes programs for manufacturing and design, as well as mobile applications; for example, OOP can be used for manufacturing system simulation software. The organization of an object-oriented program also makes the method beneficial to collaborative development, where projects are divided into groups. Additional benefits of OOP include code reusability, scalability and efficiency. The first step in OOP is to collect all of the objects a programmer wants to manipulate and identify how they relate to each other -- an exercise known as data modeling. Examples of an object can range from physical entities, such as a human being who is described by properties like name and address, to small computer programs, such as widgets. Once an object is known, it is labeled with a class of objects that 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 can communicate with well-defined interfaces called messages. What is the structure of object-oriented programming?The structure, or building blocks, of object-oriented programming include the following:
What are the main principles of OOP?Object-oriented programming is based on the following principles:
What are examples of object-oriented programming languages?While Simula is credited as being the first object-oriented programming language, many other programming languages are used with OOP today. But some programming languages pair with OOP better than others. For example, programming languages considered pure OOP languages treat everything as objects. Other programming languages are designed primarily for OOP, but with some procedural processes included. For example, popular pure OOP languages include: Programming languages designed primarily for OOP include: Other programming languages that pair with OOP include:
What are the benefits of OOP?Benefits of OOP include:
Criticism of OOPThe object-oriented programming model has been criticized by developers for multiple reasons. The largest concern is that OOP overemphasizes the data component of software development and does not focus enough on computation or algorithms. Additionally, OOP code may be more complicated to write and take longer to compile. Alternative methods to OOP include:
Most advanced programming languages enable developers to combine models, because they can be used for different programming methods. For example, JavaScript can be used for OOP and functional programming. Developers who are working with OOP and microservices can address common microservices issues by applying the principles of OOP.
Software is a set of instructions, data or programs used to operate computers and execute specific tasks. It is the opposite of hardware, which describes the physical aspects of a computer. Software is a generic term used to refer to applications, scripts and programs that run on a device. It can be thought of as the variable part of a computer, while hardware is the invariable part. The two main categories of software are application software and system software. An application is software that fulfills a specific need or performs tasks. System software is designed to run a computer's hardware and provides a platform for applications to run on top of. Other types of software include programming software, which provides the programming tools software developers need; middleware, which sits between system software and applications; and driver software, which operates computer devices and peripherals. Early software was written for specific computers and sold with the hardware it ran on. In the 1980s, software began to be sold on floppy disks, and later on CDs and DVDs. Today, most software is purchased and directly downloaded over the internet. Software can be found on vendor websites or application service provider websites. Examples and types of softwareAmong the various categories of software, the most common types include the following:
How does software work?All software provides the directions and data computers need to work and meet users' needs. However, the two different types -- application software and system software -- work in distinctly different ways. Application softwareApplication software consists of many programs that perform specific functions for end users, such as writing reports and navigating websites. Applications can also perform tasks for other applications. Applications on a computer cannot run on their own; they require a computer's OS, along with other supporting system software programs, to work. These desktop applications are installed on a user's computer and use the computer memory to carry out tasks. They take up space on the computer's hard drive and do not need an internet connection to work. However, desktop applications must adhere to the requirements of the hardware devices they run on. Web applications, on the other hand, only require internet access to work; they do not rely on the hardware and system software to run. Consequently, users can launch web applications from devices that have a web browser. Since the components responsible for the application functionality are on the server, users can launch the app from Windows, Mac, Linux or any other OS. System softwareSystem software sits between the computer hardware and the application software. Users do not interact directly with system software as it runs in the background, handling the basic functions of the computer. This software coordinates a system's hardware and software so users can run high-level application software to perform specific actions. System software executes when a computer system boots up and continues running as long as the system is on. Here are the key differences between system and application software.Design and implementationThe software development lifecycle is a framework that project managers use to describe the stages and tasks associated with designing software. The first steps in the design lifecycle are planning the effort and then analyzing the needs of the individuals who will use the software and creating detailed requirements. After the initial requirements analysis, the design phase aims to specify how to fulfill those user requirements. The next is step is implementation, where development work is completed, and then software testing happens. The maintenance phase involves any tasks required to keep the system running. The software design includes a description of the structure of the software that will be implemented, data models, interfaces between system components and potentially the algorithms the software engineer will use. The software design process transforms user requirements into a form that computer programmers can use to do the software coding and implementation. The software engineers develop the software design iteratively, adding detail and correcting the design as they develop it. The different types of software design include the following:
How to maintain software qualitySoftware quality measures if the software meets both its functional and nonfunctional requirements. Functional requirements identify what the software should do. They include technical details, data manipulation and processing, calculations or any other specific function that specifies what an application aims to accomplish. Nonfunctional requirements -- also known as quality attributes -- determine how the system should work. Nonfunctional requirements include portability, disaster recovery, security, privacy and usability. Software testing detects and solves technical issues in the software source code and assesses the overall usability, performance, security and compatibility of the product to ensure it meets its requirements. The dimensions of software quality include the following characteristics:
To maintain software quality once it is deployed, developers must constantly adapt it to meet new customer requirements and handle problems customers identify. This includes improving functionality, fixing bugs and adjusting software code to prevent issues. How long a product lasts on the market depends on developers' ability to keep up with these maintenance requirements. When it comes to performing maintenance, there are four types of changes developers can make, including:
Software licensing and patentsA software license is a legally binding document that restricts the use and distribution of software. Typically, software licenses provide users with the right to one or more copies of the software without violating copyright. The license outlines the responsibilities of the parties that enter into the agreement and may place restrictions on how the software can be used. Software licensing terms and conditions generally include fair use of the software, the limitations of liability, warranties, disclaimers and protections if the software or its use infringes on the intellectual property rights of others. Licenses typically are for proprietary software, which remains the property of the organization, group or individual that created it; or for free software, where users can run, study, change and distribute the software. Open source is a type of software where the software is developed collaboratively, and the source code is freely available. With open source software licenses, users can run, copy, share and change the software similar to free software. Over the last two decades, software vendors have moved away from selling software licenses on a one-time basis to a software-as-a-service subscription model. Software vendors host the software in the cloud and make it available to customers, who pay a subscription fee and access the software over the internet. Although copyright can prevent others from copying a developer's code, a copyright cannot stop them from developing the same software independently without copying. A patent, on the other hand, enables a developer to prevent another person from using the functional aspects of the software a developer claims in a patent, even if that other person developed the software independently. In general, the more technical software is, the more likely it can be patented. For example, a software product could be granted a patent if it creates a new kind of database structure or enhances the overall performance and function of a computer. History of softwareThe term software was not used until the late 1950s. During this time, although different types of programming software were being created, they were typically not commercially available. Consequently, users -- mostly scientists and large enterprises -- often had to write their own software. The following is a brief timeline of the history of software:
|