The document discusses object-oriented design and analysis. It covers key aspects of the design phase including identifying classes, class responsibilities, and relationships between classes. The purposes of the design phase are to gather information for implementation, reduce implementation time and cost, and be the most time-consuming phase. Results of design include text descriptions and diagrams depicting relationships, usage scenarios, and state changes. The document also discusses translating analysis concepts into design, including understanding quality attributes, constraints, and requirements.
1 of 15
Download to read offline
More Related Content
Object oriented analysis and design unit- iv
1. Object Oriented Analysis and Design
M.Sc. Computer Science
III Semester
MS. Arati Singh
Department of Computer Science
Shri Shankaracharya Mahavidyalaya Junwani Bhilai
2. Unit- 4
Design Phase
OBJECT-ORIENTED DESIGN
Object-oriented design and object-oriented analysis are distinct disciplines, but they can be
intertwined. Object-oriented development is highly incremental; in other words, you start with
object-oriented analysis, model it, create an object-oriented design, then do some more of each,
again and again, gradually refining and completing models of the system. The activities and
focus of object-oriented analysis and object-oriented design are intertwined-grown, not built.
Design Phase
• In this phase, the program designer structures tasks identified in analysis phase into a set
of interrelated classes
• Major goals of design phase:
– Identify classes
– Identify class responsibilities
– Identify relationships between classes
• Again, these are goals, not steps; identification of one aspect of a class may lead to changes
in, discovery of others.
Purposes of design phase
• Gather information as foundation for implementation phase
• Reduce time required for implementation and testing
• If done correctly, should be most time consuming phase
Results of design phase
• Text descriptions of classes/responsibilities
• Diagrams depicting:
– relationships between classes
– usage scenarios
– changes in class state
Translating analysis Concept into Design
To transition from analysis to design, the team needs to understand the project's quality
attributes (e.g., security, maintainability, usability, and reliability) as well as design and
implementation constraints (e.g., a delivery platform). These nonfunctional requirements
3. (quality attributes and design and implementation constraints) should be elicited in consort
with functional requirements (e.g., stories, use cases, and data models).
Some teams define these early in their project charter or software requirements specification,
if one is used. (Agile projects tend to shun full-blown specification documents where possible.)
In any case, these nonfunctional requirements must be defined and are necessary for a safe and
sound transition from analysis to design.
Given the delivery platform per design and implementation constraints, quality attributes, and
any existing architectural standards; the design staff can-in tandem as requirements are elicited-
work on the design. Priorities count, because without the prioritized requirements and prior
knowledge of delivery platform, the bare minimum the design team could produce is an
analysis-view class diagram, which isn't enough to say the team has a sound design or has
thought about any difficult architectural decisions. So, the design team also needs to understand
the customer's priorities.
Sequence Diagrams
Sequence Diagrams capture the processing associated with particular Use Case functions.
The purpose of sequence diagrams is to display the interaction between users, screens and
object instances within the system. They provide a sequential map of message passing between
objects over time. Frequently these diagrams are placed under Use Cases or Components in the
model to illustrate a scenario, or common set of steps followed in response to an event that
generates an outcome. The model includes what initiates activity in the system, what processing
and changes occur internally and what outputs are generated.
Often, the object instances are represented using special stereotyped icons. Icons exist for
boundary objects, controllers and persistent entities. The notation used is typically a
horizontally deployed set of actors and object instances, each having a vertical lifespan bar.
Messages are drawn from one object to another with an arrow indicating the direction of flow.
The example diagram Figure 3.8 below demonstrates some features of Sequence diagrams.
Note the use of stereotyped icons to display particular objects: for example the user interface
(Login Screen) is displayed with a Boundary stereotype and the User as an Entity stereotype.
These help visually differentiate object roles during analysis.
4. Figure : Example of a sequence diagram
Collaboration Diagram
A collaboration diagram describes interactions among objects in terms of sequenced
messages. Collaboration diagrams represent a combination of information taken from class,
sequence, and use case diagrams describing both the static structure and dynamic behavior of
a system.
A collaboration diagram, also called a communication diagram or interaction diagram, is
an illustration of the relationships and interactions among software objects in the Unified
Modeling Language (UML). The concept is more than a decade old although it has been refined
as modeling paradigms have evolved.
A collaboration diagram resembles a flowchart that portrays the roles, functionality and
behavior of individual objects as well as the overall operation of the system in real time.
Objects are shown as rectangles with naming labels inside. These labels are preceded by colons
5. and may be underlined. The relationships between the objects are shown as lines connecting
the rectangles. The messages between objects are shown as arrows connecting the relevant
rectangles along with labels that define the message sequencing.
Collaboration diagrams are best suited to the portrayal of simple interactions among
relatively small numbers of objects. As the number of objects and messages grows, a
collaboration diagram can become difficult to read. Several vendors offer software for creating
and editing collaboration diagrams.
Class Diagrams
A Class is a standard UML construct used to detail the pattern from which objects will be
produced at run-time. A class is a specification - an object an instance of a class. Classes may
be inherited from other classes (that is they inherit all the behavior and state of their parent and
add new functionality of their own), have other classes as attributes, delegate responsibilities
to other classes and implement abstract interfaces.
The Class Model is at the core of object-oriented development and design - it expresses
both the persistent state of the system and the behavior of the system. A class encapsulates state
(attributes) and offers services to manipulate that state (behavior). Good object-oriented design
limits direct access to class attributes and offers services, which manipulate attributes on behalf
of the caller. This hiding of data and exposing of services ensures data updates are only done
in one place and according to specific rules - for large systems the maintenance burden of code
which has direct access to data elements in many places is extremely high. The class is
represented as Figure below:
Figure: Example of a class diagram
Class diagrams are one of the most useful types of diagrams in UML as they clearly map out
6. the structure of a particular system by modeling its classes, attributes, operations, and
relationships between objects. With our UML diagramming software, creating these diagrams
is not as overwhelming as it might appear. This guide will show you how to understand, plan,
and create your own class diagrams.
Benefits of class diagrams
Class diagrams offer a number of benefits for any organization. Use UML class diagrams to:
• Illustrate data models for information systems, no matter how simple or complex.
• Better understand the general overview of the schematics of an application.
• Visually express any specific needs of a system and disseminate that information
throughout the business.
• Create detailed charts that highlight any specific code needed to be programmed and
implemented to the described structure.
• Provide an implementation-independent description of types used in a system that are
later passed between its components.
Designing the Data Access Layer
In information systems, most of system processes are associated with storing and recovering
information, because of that in architecting these kinds of systems, the module that is associated
with storing and recovering information, gets much attention.
Also there is specific layer in three-layer architecture that is responsible for accessing
information and its name is data access layer. All processes related to system’s information
management including insert and remove, edit and recovery of information are responsibilities
of this layer.
A lot of models have been used and deliberated to data access layer that all of them had some
advantages and disadvantages. In some of these models by changing system’s information
structure, data access layer model must be changed.
In fact data access layer is associated with system’s information structure and this is one of the
serious problems of these kinds of models because it has not capability of reusing. According
to the importance of data access layer in information system’s architecture, internal architecture
of this layer should be designed in a way that it could be used in all systems with any kind of
information as data access module and this matter makes the speed of software production
process faster.
Because of hat in our suggested model, in addition to observing capability of reusing, we have
considered lots of quality characteristics of software such as capability of development reliance
and security capability by designing data access layer and we apply them in our designing.
Figure represents general structure of data access layer and its engagement method with an
adjacent layer based on suggested model.
7. Figure: overall structure of internal architecture of data access layer based on the proposed
model.
Internal structure of data access layer as you observes in figure, all system layers and modules
are associated with data access layer directly and indirectly.
In order to design a model for data access layer we should keep it in mind that what the other
modules and layers of system expect from this layer.
After recognizing other requirements of system layers, we can offer an appropriate model for
that by observing object oriented design patterns.
A data access layer must have the ability to control the information access, to perform the
commands related to information edition, to control faults and to manage transactions.
A layer which leads us to data must ensure that the information of the system will be
comprehensive at any situation.
User Interface Design & Layer
User interface design (UI) or user interface engineering is the design of user
interfaces for machines and software, such as computers, home appliances, mobile devices,
and other electronic devices, with the focus on maximizing usability and the user experience.
In information technology, the user interface (UI) is everything designed into an information
device with which a person may interact. This can include display screens, keyboards,
a mouse and the appearance of a desktop. It is also the way through which a user interacts with
an application or a website. The growing dependence of many companies on web
applications and mobile applications has led many companies to place increased priority on UI
in an effort to improve the user's overall experience.
The goal of user interface design is to make the user's interaction as simple and efficient as
8. possible, in terms of accomplishing user goals (user-centered design).
Good user interface design facilitates finishing the task at hand without drawing unnecessary
attention to it. Graphic design and typography are utilized to support its usability, influencing
how the user performs certain interactions and improving the aesthetic appeal of the design;
design aesthetics may enhance or detract from the ability of users to use the functions of the
interface.
Figure: Different Layers of User Interface
The design process must balance technical functionality and visual elements (e.g., mental
model) to create a system that is not only operational but also usable and adaptable to changing
user needs.
Interface design is involved in a wide range of projects from computer systems, to cars, to
commercial planes; all of these projects involve much of the same basic human interactions yet
also require some unique skills and knowledge. As a result, designers tend to specialize in
certain types of projects and have skills centered on their expertise, whether that be software
design, user research, web design, or industrial design.
User interface design requires a good understanding of user needs. There are several phases
and processes in the user interface design, some of which are more demanded upon than others,
depending on the project.[2]
(Note: for the remainder of this section, the word system is used to
denote any project whether it is a website, application, or device.)
• Functionality requirements gathering – assembling a list of the functionality required
by the system to accomplish the goals of the project and the potential needs of the users.
• User and task analysis – a form of field research, it's the analysis of the potential users of
the system by studying how they perform the tasks that the design must support, and
conducting interviews to elucidate their goals.
9. • Information architecture – development of the process and/or information flow of the
system (i.e. for phone tree systems, this would be an option tree flowchart and for web sites
this would be a site flow that shows the hierarchy of the pages).
• Prototyping – development of wire-frames, either in the form of paper prototypes or
simple interactive screens. These prototypes are stripped of all look & feel elements and
most content in order to concentrate on the interface.
• Usability inspection – letting an evaluator inspect a user interface. This is generally
considered to be cheaper to implement than usability testing (see step below), and can be
used early on in the development process since it can be used to evaluate prototypes or
specifications for the system, which usually cannot be tested on users. Some common
usability inspection methods include cognitive walkthrough, which focuses the simplicity
to accomplish tasks with the system for new users, heuristic evaluation, in which a set of
heuristics are used to identify usability problems in the UI design, and pluralistic
walkthrough, in which a selected group of people step through a task scenario and discuss
usability issues.
• Usability testing – testing of the prototypes on an actual user—often using a technique
called think aloud protocol where you ask the user to talk about their thoughts during the
experience. User interface design testing allows the designer to understand the reception
of the design from the viewer's standpoint, and thus facilitates creating successful
applications.
• Graphical user interface design – Actual look and feel design of the final graphical user
interface (GUI). These are design’s control panels and faces; voice-controlled interfaces
involve oral-auditory interaction, while gesture-based interfaces witness users engaging
with 3D design spaces via bodily motions. It may be based on the findings developed
during the user research, and refined to fix any usability problems found through the results
of testing. Depending on the type of interface being created, this process typically involves
some computer programming in order to validate forms, establish links or perform a
desired action.
• Software Maintenance - After the deployment of a new interface, occasional maintenance
may be required to fix software bugs, change features, or completely upgrade the system.
Once a decision is made to upgrade the interface, the legacy system will undergo another
version of the design process, and will begin to repeat the stages of the interface life cycle.
Designing System Interfaces
10. A system transforms its inputs into its outputs.
▪ The inputs must come from somewhere; in the systems perspective, they always come from
some other system (in the form of that other system's outputs).
▪ Similarly, system outputs are made available to other systems (and become those other
systems' inputs).
▪ The collection of all the inputs and outputs of a system define its interfaces.
In figure 1, we have a schematic model of how two systems “connect”1).
• Each system has interfaces (the small coloured boxes).
• Between the interfaces is the system boundary.
• For each interface in System 1, there is a corresponding interface in System 2; this is
shown in figure 1 by corresponding colours.
• Each matching pair of interfaces represents one flow of mass, energy, or information
across the boundary.
• So, two systems share one boundary across which many flows can occur, and each flow
must have matching interfaces in each system.
Since systems are black boxes2), we do not know or care how a system provides its interface;
we only really care about the interface itself.
• For instance, so long as the “engine” of a car safely provides sufficient power to satisfy
the needs of the driver and the other systems in the car, does it really matter if the engine
is driven by internal combustion, or a fuel cell, or a Mr. Fusion? (Spoiler: no, it doesn't.)
11. In engineering design, we only care about three principal types of interfaces: mass, energy, and
information. There are other types of interfaces that may concern other specialists, but we do
not need to worry about them.
Interfaces are functional in nature, not behavioral. That is to say, they describe, in quantitative
terms, the purpose for the input or output3).
• For instance, if we consider our elevator example (e.g. as discussed in product systems),
we can think of the various commands that a user might wish to send to the elevator
system. We would phrase these commands not as pushing buttons, but rather by
the intent behind pushing the buttons.
Why do we specify system interfaces?
Interfaces let us describe what a system is supposed to do to be useful as an element of a larger
system.
• An engine that cannot provide enough power to your car is useless.
• A computer that requires electricity at a difference voltage than that available is useless.
• An umbrella that does not sufficiently cover you is useless.
• A stapler than hurts your hand when you use it is useless.
These are just some examples of products with mismatched interfaces for the situations in
which they are to be used.
• It doesn't matter how good the product is otherwise, if there is a mismatch or imbalance
between the interface it provides and the interface expected by other systems, then that
product is useless (if not harmful).
• Mismatched interfaces are a kind of systemic flaw.
Furthermore, as we recuse down to lower, more detailed levels of a design project, each
preceding level of user interface provides the foundation for the requirements we will need at
the lower, more detailed levels.
• For instance, higher level user interfaces in the design of a kitchen blender (plus
knowledge of various technologies and natural laws) will lead to requirements about
the quality and quantity of electric energy that has to be accommodated by the blender's
plug.
Finally, quantitative specifications of system interfaces will also be essential in the next stage
of the design process (concept design) when we seek out ways to implement the functions that
the systems have to provide, because the quantity of flow through an interface will help us
decide what technologies we can use to implement those interfaces.
12. When do we specify system interfaces?
Since design is about solving existing problems (or improving identified imbalances), we can
only specify interfaces when we know what systems will be interacting, and why they will
interact. It is best, then, to first identify interacting subsystems, and then figure out exactly how
those subsystems will interact, constrained by the requirements of the problem and the product
strategy for the project.
Because of the richly interconnected nature of system interfaces, specifying them is a task that
is best done as a team exercise, with everyone present.
Also, because systems are functional units, interface specification should be
done before concept design, when embodiments are developed. (Indeed, coming up with good
embodiments rather depends on there being well-defined system interfaces.)
How do we specify system interfaces?
We specify interfaces on system diagrams, where we can graphically show the flows, in
conjunction with supporting documentation. Assuming you have already identified whatthe
inputs and outputs are to your overall system, there are three steps to specifying interfaces:
• draw appropriate arrows on your system diagram,
• quantify the interfaces, and
• add any supporting documentation you think is necessary to explain your decisions.
Controls & Security
Access control is a security technique that regulates who or what can view or use resources in
a computing environment. It is a fundamental concept in security that minimizes risk to the
business or organization.
There are two types of access control: physical and logical. Physical access control limits
access to campuses, buildings, rooms and physical IT assets. Logical access control limits
connections to computer networks, system files and data.
To secure a facility, organizations use electronic access control systems that rely on user
credentials, access card readers, auditing and reports to track employee access to restricted
business locations and proprietary areas, such as data centers. Some of these systems
incorporate access control panels to restrict entry to rooms and buildings as well as alarms and
lockdown capabilities to prevent unauthorized access or operations.
13. Access control systems perform identification authentication and authorization of users and
entities by evaluating required login credentials that can include passwords, personal
identification numbers (PINs), biometric scans, security tokens or other authentication
factors. Multifactor authentication, which requires two or more authentication factors, is often
an important part of layered defense to protect access control systems.
These security controls work by identifying an individual or entity, verifying that the person or
application is who or what it claims to be, and authorizing the access level and set of actions
associated with the username or IP address. Directory services and protocols, including the
Local Directory Access Protocol (LDAP) and the Security Assertion Markup
Language(SAML), provide access controls for authenticating and authorizing users and entities
and enabling them to connect to computer resources, such as distributed applications and web
servers.
Organizations use different access control models depending on their compliance requirements
and the security levels of information technology they are trying to protect.
Types of access control
The main types of access control are:
• Mandatory access control (MAC): A security model in which access rights are regulated
by a central authority based on multiple levels of security. Often used in government and
military environments, classifications are assigned to system resources and the operating
system or security kernel, grants or denies access to those resource objects based on the
information security clearance of the user or device. For example, Security Enhanced
Linux is an implementation of MAC on the Linux operating system.
• Discretionary access control (DAC): An access control method in which owners or
administrators of the protected system, data or resource set the policies defining who or
what is authorized to access the resource. Many of these systems enable administrators to
limit the propagation of access rights. A common criticism of DAC systems is a lack of
centralized control.
• Role-based access control (RBAC): A widely used access control mechanism that
restricts access to computer resources based on individuals or groups with defined business
14. functions -- executive level, engineer level 1 -- rather than the identities of individual users.
The role-based security model relies on a complex structure of role assignments, role
authorizations and role permissions developed using role engineering to regulate employee
access to systems. RBAC systems can be used to enforce MAC and DAC frameworks.
• Rule-based access control: A security model in which the system administrator defines
the rules that to govern access to resource objects. Often these rules are based on conditions,
such as time of day or location. It is not uncommon to use some form of both rule-based
access control and role-based access control to enforce access policies and procedures.
• Attribute-based access control (ABAC): A methodology that manages access rights by
evaluating a set of rules, policies and relationships using the attributes of users, systems
and environmental conditions.
Use of access control
The goal of access control is to minimize the risk of unauthorized access to physical and logical
systems. Access control is a fundamental component of security compliance programs that
ensures security technology and access control policies are in place to protect confidential
information, such as customer data. Most organizations have infrastructure and procedures that
limit access to networks, computer systems, applications, files and sensitive data, such as
personally identifiable information and intellectual property.
Access control systems are complex and can be challenging to manage in dynamic IT
environments that involve on-premises systems and cloud services. After some high-profile
breaches, technology vendors have shifted away from single sign-on systems to unified access
management, which offers access controls for on-premises and cloud environments.
Implementing access control
Access control is a process that is integrated into an organization's IT environment. It can
involve identity and access management systems. These systems provide access control
software, a user database, and management tools for access control policies, auditing and
enforcement.
When a user is added to an access management system, system administrators use an automated
provisioning system to set up permissions based on access control frameworks, job
15. responsibilities and workflows.
The best practice of "least privilege" restricts access to only resources that an employee requires
to perform their immediate job functions.
A common security issue is failure to revoke credentials and access to systems and data when
an individual moves into a different job internally or leaves the company.
Reference
https://searchcio.techtarget.com/definition/OODA-loop
https://www.tutorialspoint.com/object_oriented_analysis_design/index.htm
https://www.geeksforgeeks.org/unified-modeling-language-uml-introduction/
https://www.techopedia.com/definition/12027/object-oriented-database-management-system-
oodbms