Software Engineering - Architecture and UI
Software Engineering - Architecture and UI
Software design:
1
It is the first stage of the Software Design Lifecycle. It defines:
Software architecture:
It is the blueprint for a software system and the highest level of a software
design. It defines:
2
While there are several different software architecture patterns, we are going to
look at the following top-four:
● Serverless architecture
● Event-driven architecture
● Microservices Architecture
● Call and return Architecture
● Data Flow and Data Centered Architectures
● Hierarchical Architecture
● Component based architecture
This pattern can be used to build software and services without managing the
infrastructure. A third-party is used to manage servers, the backend, and other
services. This lets you focus on fast, continuous software delivery. When you
don’t have to worry about managing the infrastructure and planning for
expansion, you have more time to look at the value that can be added to your
software and services.
3
consumer event might process the event, or it might only be impacted by the
event.
Hierarchical Architecture
Applications
4
Widely applied in the areas of parallel and distributed computing.
Advantages
Call and return architecture is a specific type of hierarchical architecture that focuses
on managing control flow through function calls, while hierarchical architecture is a
broader organizational principle encompassing various layered structures.
Data Design
5
Key Aspects of Data Design:
Data Types:
Defining the types of data (e.g., integers, strings, dates) to be stored and
manipulated.
Data Relationships:
Establishing how different data elements relate to each other (e.g., one-to-one,
one-to-many).
Data Constraints:
Implementing rules to ensure data integrity and consistency (e.g., primary keys,
foreign keys, validation rules).
Data Structures:
Choosing appropriate data structures (e.g., arrays, linked lists, hash tables) to
optimize performance.
6
Database Design:
Transforming the data model into a database schema, considering factors like
normalization and performance.
7
Assessing Alternative Architectural Designs
There are basically 2 types of assessments
8
The Software Engg Institute has developed an Architecture Trade off
Analysis Method (ATAM) that establishes an iterative evaluation process
for software Architectures.
I.ATAM
The design analysis that follow are performed iteratively to evaluate the
processes:
1. Collect scenarios
2. Elicit requirements, constraints and Environment description
3. Describe the architectural patterns that hav been chosen to address the
scenarios and requirements.
The following are architectural views:
● Model View
● Process view →Analyses of performance
● Data flow view → Analyses of he degree to which the architecture
meets the functional requirements
Using the results of steps - 5 & step-6 some of the architectural alternatives
may be eliminated.
Also, one or more of the ATAM steps are modified and re-applied to the
ATAM processes.
9
II. Architectural complexity
proposed by zoho. There are 3 dependencies
Sharing dependencies - ex : 2 consumers share the same data.
Data is a dependency
Flow dependencies - The representation of dependent relationship between
producers and consumers
Constraint dependencies - It represents the constraints on the relative flow
among a set of activities.
for ex. 2 components can not execute at the same time. The
execution of one component depends on the other component
10
Mapping Data Flow into a Software Architecture
11
12
Efferent : "To carry away from".
Afferent: "To carry to".
13
14
15
16
Data gets into the system. Transformed
17
Data flows into the system.
Data gets transformed into a format required by the system
Data flows out of the system after the process - world data
18
19
● Step 2: Review and refine the data flow diagrams for the s/w
20
Modeling Component-Level Design
The foundation of any software architecture is component-level design
— you break a system into its component parts and define how they
interact. Done well, component-level design facilitates reuse, reduces
complexity, and enables parallel development.
Component-based architecture focuses on the decomposition of the design
into individual functional or logical components that represent well-defined
communication interfaces containing methods, events, and properties.
What is a Component?
A component is a software object, intended to interact with other
components, encapsulating certain functionality or a set of functionalities. It
has an obviously defined interface and conforms to a recommended behavior
common to all components within an architecture.
21
A software component can be defined as a unit of composition
with a contractually specified interface and explicit context
dependencies only. That is, a software component can be
deployed independently and is subject to composition by third
parties.
Characteristics of Components
Reusability − Components are usually designed to be reused in
different situations in different applications. However, some
components may be designed for a specific task.
Replaceable − Components may be freely substituted with other
similar components.
Not context specific − Components are designed to operate in
different environments and contexts.
Extensible − A component can be extended from existing
components to provide new behavior.
Encapsulated − A component depicts the interfaces, which allow the
caller to use its functionality, and do not expose details of the internal
processes or any internal variables or state.
Independent − Components are designed to have minimal
dependencies on other components.
22
● Describes persistent data sources (databases and files) and identifies
the classes required to manage them.
● Develop and elaborate behavioral representations for a class or
component. This can be done by elaborating the UML state diagrams
created for the analysis model and by examining all use cases that are
relevant to the design class.
● Elaborates deployment diagrams to provide additional implementation
detail.
23
Principles
Cohesion High
Coupling Very low or minimu . Loosely coupled
24
25
Object Constraint Language (OCL)
26
Users of the Unified Modeling Language and other
languages can use OCL to specify constraints and other expressions
attached to their models.
Why OCL
In order to write unambiguous constraints, so-called formal
languages have been developed. The disadvantage of traditional formal
languages is that they are usable to persons with a strong mathematical
background, but difficult for the average business or system modeler to
use.
● Expression language
OCL is a pure expression language. Therefore, an OCL expression is
guaranteed to be without side effects. It cannot change anything in the model.
This means that the state of the system will never change because of an OCL
expression, even though an OCL expression can be used to specify such a state
change (e.g., in a post-condition). All values for all objects, including all links, will
not change. Whenever an OCL expression is evaluated, it simply delivers a
value.
● Modeling language
OCL is a modeling language, not a programming language. It is not possible to
write program logic or flow-control in OCL. You especially cannot invoke
processes or activate non-query operations within OCL. Because OCL is a
modeling language in the first place, not everything in it is promised to be directly
executable.
As a modeling language, all implementation issues are out of scope and cannot
be expressed in OCL. Each OCL expression is conceptually atomic. The state of
the objects in the system cannot change during evaluation.
27
● Formal language
OCL is a formal language where all constructs have a formally defined
meaning. The specification of OCL is part of the UML specification.
The above Figure gives an overview of the OCL type system in the form of a feature
model. Using a tree-like description, feature models allow describing mandatory and
optional features of a subject, and to specify alternative features as well as conjunctive
features. In particular, the figure pictures the different kinds of available types.
28
Applications of OCL
29
Key Words
Context
30
Self
Invariant
31
32
33
34
35
Example
36
User Interface
User interface is the first impression of a software system from the user's
point of view. Therefore any software system must satisfy the requirements
of the user. UI mainly performs two functions −
37
Golden Rules
38
Interface types
UI Design Process
39
UI Analysis
40
Interface Design Steps
UI Design patterns
41
UI Design Issues & Challenges
UI Design Evaluation
42
43