Object-oriented analysis and design (OOAD) is a popular technical approach for 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.
Object Oriented Analysis.
The purpose of any analysis activity in the software life-cycle is to create a model of the system's functional requirements that is independent of implementation constraints.
In the system analysis or object-oriented analysis phase of software development, the system requirements are determined, the classes are identified and the relationships among classes are identified, appropriate models are created.
The primary tasks in object-oriented analysis (OOA) are:
- Find the objects,
- Organize the objects,
- Describe how the objects interact,
- Define the behavior of the objects,
- Define the internals of the objects.
This serves as a way to understand the 'domain knowledge' - knowledge needed to write software that is not neccesarily the Computer Sciences-related.
Common models used in OOA are use cases and object models. Use cases describe scenarios for standard domain functions that the system must accomplish. Object models describe the names, class relations (e.g. Circle is a subclass of Shape), operations, and properties of the main objects.
Object Oriented Design.
Object-oriented design is the process of planning a system of interacting objects for the purpose of solving a software problem.
The input for object-oriented design is provided by the output of object-oriented analysis.
During object-oriented design (OOD), a developer applies implementation constraints to the conceptual model produced in object-oriented analysis. Such constraints could include the hardware and software platforms, the performance requirements, persistent storage and transaction, usability of the system, and limitations imposed by budgets and time. Concepts in the analysis model which is technology independent, are mapped onto implementing classes and interfaces resulting in a model of the solution domain, i.e., a detailed description of how the system is to be built on concrete technologies.
- Defining objects, creating class diagram from conceptual diagram,
- Identifying attributes,
- Use design patterns (if applicable),
- Define application framework (if applicable): Application framework is a term usually used to refer to a set of libraries or classes that are used to implement the standard structure of an application for a specific operating system. By bundling a large amount of reusable code into a framework, much time is saved for the developer, since he/she is saved the task of rewriting large amounts of standard code for each new application that is developed,
- Identify persistent objects/data (if applicable): Identify objects that have to last longer than a single runtime of the application. If a relational database is used, design the object relation mapping,
- Identify and define remote objects (if applicable).
Output of object-oriented design:
- Class diagram: A class diagram is a type of static structure UML diagram that describes the structure of a system by showing the system's classes, their attributes, and the relationships between the classes. The messages and classes identified through the development of the sequence diagrams can serve as input to the automatic generation of the global class diagram of the system.
The Acyclic dependencies principle.
The dependency graph of components should have no cycles. This can be realized by abstracting common parts of the inter-dependent objects & moving into other abstract object(s), as well as by using the Dependency Injection Design Pattern. There are tools such as the Spring Framework that organize structure of the project & allow to easily use the Dependency Injection pattern as well. A part of 'Ola AH' Programming Language's semantics - Stitie Space - will also allow to model the object graph of a program & skillfully use the Dependency Injection Design Pattern as well.
Circular dependencies can cause many unwanted effects in software programs:
- Most problematic from a software design point of view is the tight coupling of the mutually dependent modules which reduces or makes impossible the separate re-use of a single module,
- Circular dependencies can cause a domino effect when a small local change in one module spreads into other modules and has unwanted global effects (program errors, compile errors),
- Circular dependencies make software to be hard to test,
- Circular dependencies can also result in infinite recursions or other unexpected failures. Circular dependencies may also cause memory leaks by preventing certain very primitive automatic garbage collectors from deallocating unused objects.
Object Oriented Modelling.
Object Oriented Modeling (OOM) is a common approach to modeling applications, systems, and business domains by using the object-oriented paradigm throughout the entire development life cycles. OOM is a main technique heavily used by both OOA and OOD activities in modern software engineering.
The benefits of OOM are:
- Efficient and effective communication within & between Team(s),
- Models are tools that allow to quickly, visually analyze the Project & the Problem Domain, to Simplify & Abstract the Design.
The Unified Modeling Language (UML) is a visual, popular international standard language used for object-oriented modeling, there are other solutions as well.
- My own knowledge & experience.
See also, if You wish:
- Object Relationships Modelling & Analysis,
- Iterative Development vs. Waterfall model.