In computer science, an object can be a variable, a data structure, a function, or a method, and as such, is a value in memory referenced by an identifier.
In the class-based object-oriented programming paradigm, object refers to a particular instance of a class, where the object can be a combination of variables, functions, and data structures. 1
Object-Oriented Analysis and Design (OOAD) is a popular technical approach to analyzing, designing an application, system, or business by applying the object-oriented paradigm and visual modeling throughout the development life cycles to foster better stakeholder communication and product quality.
According to the popular guide Unified Process, OOAD in modern software engineering is best conducted in an iterative and incremental way. Iteration by iteration, the outputs of OOAD activities, analysis models for OOA, and design models for OOD respectively, will be refined and evolve continuously driven by key factors like risks and business value.2
- Object Oriented Analysis and Design
- Object-Oriented Analysis And Design — Introduction (Part 1)
- The Principles of OOD
SOLID is an acronym that represents a set of five design principles for writing maintainable and scalable software. Robert C. Martin introduced these principles widely used in object-oriented programming. As a manager, understanding these principles can help you guide your development team to create robust and maintainable software. Let's go through each principle:
A series of Object-Oriented Design articles was principally authored by "Uncle Bob", Robert Martin.
- Design Principles and Design Patterns by Robert C. Martin
- SRP: The Single Responsibility Principle by Robert C. Martin
- OCP: The Open-Closed Principle by Robert C. Martin
- LSP: The Liskov Substitution Principle by Robert C. Martin
- ISP: The Interface Segregation Principle by Robert C. Martin
- DIP: The Dependency Inversion Principle by Robert C. Martin
- It encourages having a single reason to change for a class or module.
- Each class or module should have only one responsibility or job.
- Easier maintenance: When a class has a single responsibility, it's easier to understand and maintain.
- Improved collaboration: Developers can work more independently on specific tasks.
- Software entities (classes, modules, functions, etc.) should be open for extension but closed for modification.
- New functionality should be added by creating new classes or modules, not by changing existing ones.
- Future-proofing: Encourages a design that can accommodate new features without altering existing working code.
- Reduced risk: Changes are localized to new components, minimizing the risk of introducing bugs in existing functionality.
- Objects of a superclass should be replaceable with objects of a subclass without affecting the correctness of the program.
- Interchangeability: Teams can work on different components without worrying about breaking the system as long as they adhere to the defined interfaces.
- Consistency: Ensures a consistent behavior of components that can be swapped in and out.
- A class should not be forced to implement interfaces it does not use.
- Clients should not be forced to depend on interfaces they do not use.
- Focused development: Developers can work on smaller, more focused interfaces, reducing the likelihood of errors.
- Independent components: Teams can work on different interfaces without affecting each other.
- High-level modules should be independent of low-level modules. Both should depend on abstractions.
- Abstractions should not rely on details. Details should depend on abstractions.
- Flexibility: Allows for easy substitution of components, promoting a more modular and flexible system.
- Collaboration: Encourages collaboration between teams working on different layers of the application.
Understanding and applying these SOLID principles can lead to a more maintainable, scalable, and adaptable software system.
- Design Patterns in architecture and computer science is a formal way of documenting a solution to a design problem in a particular field of expertise. The idea was introduced by the architect Christopher Alexander in the field of architecture and has been adapted for various other disciplines, including computer science. An organized collection of design patterns that relate to a particular field is called a pattern language.3
- Design Anti-Patterns is a pattern that may be commonly used but is ineffective and/or counterproductive in practice.4
The Unified Modeling Language (UML) is a standardized way of specifying, visualizing, and documenting the artifacts of an object-oriented software under development (among other things). 5
- Introduction To OMG's Unified Modeling Language (UML)
- Unified Modeling Language (UML) - An Introduction
Object-Oriented Programming (OOP) is a programming paradigm based on the concept of "objects", which may contain data, in the form of fields, often known as attributes; and code, in the form of procedures, often known as methods. A feature of objects is that an object's procedures can access and often modify the data fields of the object with which they are associated (objects have a notion of "this" or "self"). In OOP, computer programs are designed by making them out of objects that interact with one another. There is significant diversity of OOP languages, but the most popular ones are class-based, meaning that objects are instances of classes, which typically also determine their type.
Many of the most widely used programming languages (such as C++, Delphi, Java, Python etc.) are multi-paradigm programming languages that support object-oriented programming to a greater or lesser degree, typically in combination with imperative, procedural programming. Significant object-oriented languages include Java, C++, C#, Python, PHP, Ruby, Perl, Object Pascal, Objective-C, Dart6
- Classes (OOP) - In object-oriented programming, a class is a blueprint for creating objects (a particular data structure), providing initial values for state (member variables or attributes), and implementations of behavior (member functions or methods).
- Object-Oriented System Development - The original hardcover textbook edition (ISBN 0-201-56355-X) of Object-Oriented System Development by Dennis de Champeaux, Douglas Lea, and Penelope Faure was published by Addison Wesley, copyright © 1993 by Hewlett-Packard Company. You can purchase this book directly from Addison-Wesley by phone at (800)822-6339, or order it through most bookstores. All parties involved have graciously granted permission to create this HTML edition, maintained by Doug Lea. Mail comments to dl at cs.oswego.edu.