GoV Patterns Architectural-Patterns in Software Engineering-Lecture 8 Slides-Computer Engineering, Slides of Software Engineering

GoV Patterns Architectural, Architectural Patterns, Interactive Systems, Model View Controller, Presentation Abstraction Control, Adaptable Systems, Reflection, Microkernel, Raman Ramsin, Lecture Slides, Patterns in Software Engineering, Department of Computer Engineering, Sharif University of Technology, Iran.

Typology: Slides

2011/2012

Uploaded on 02/19/2012

hester
hester 🇮🇷

4.5

(13)

84 documents

1 / 39

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Patterns in
Software Engineering
Lecturer: Raman Ramsin
Lecture 8
GoV Patterns – Architectural
Part 2
Department of Computer Engineering 1Sharif University of Technology
Part
2
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27

Partial preview of the text

Download GoV Patterns Architectural-Patterns in Software Engineering-Lecture 8 Slides-Computer Engineering and more Slides Software Engineering in PDF only on Docsity!

Patterns in Software Engineering Lecturer: Raman Ramsin^ Lecture 8^ GoV Patterns – Architectural

Part 2

1

Sharif University of Technology

Part

Patterns in Software Engineering – Lecture 8

Architectural Patterns: CategoriesArchitectural

Patterns: Categories

„

From Mud to Structure

Layers,

Pipes and Filters, and

Blackboard

„

Distributed Systems

Broker; also

Microkernel and

Pipes and Filters

I

t

ti

S

t

„

I

nteractive Systems

Support the structuring of systems that feature human-computer interaction.

Model-View-Controller and

Presentation-Abstraction-Control

„

Adaptable Systems

Support extension of applications and their adaptation to evolving technology andchanging functional requirements.changing functional requirements.

Reflection and

Microkernel

2

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Interactive Systems: Model

-View-Controller

Interactive Systems: Model View Controller^ „

Divides an interactive application into three components.

The

Model

contains the core functionality and data.

Views

display information to the user.

Controllers

handle user input.

Controllers

handle user input.

A change-propagation mechanism ensures consistency between the user interface(views and controllers) and the model.

4

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Interactive Systems: Model

-View-Controller

Interactive Systems: Model View Controller^ „

Context

-

Interactive applications with a flexible human

-computer interface

„

Context

Interactive

applications with a flexible human computer interface.

„

Problem

-

Forces are as follows:

„

Problem

Forces

are as follows:

The same information is presented differently in different windows, for example,in a bar or pie chart.

The display and behavior of the application must reflect data manipulationsimmediately.

Changes to the user interface should be easy, and even possible at run-time.

Supporting different 'look and feel' standards or porting the user interfaceshould not affect code in the core of the application.

5

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Model-View-Controller: Structure

  • Views and Controllers

„

View

components present information to the user.

‰

Each view defines an update procedure that is activated by the change propagationmechanism and retrieves data from the model.

‰

Each view creates a suitable controller.

‰

Views often offer functionality that allows controllers to manipulate the display.

„

Controller

components accept user input as events.

‰

If the behavior of a controller depends on the state of the model, the controller

p

,

registers itself with the model and implements an update operation.

7

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Model

-View-Controller: Class Structure

Model View Controller: Class Structure

8

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Model

-View-Controller: Dynamics

  • Scenario II

Model View Controller: Dynamics

Scenario II

the MVC triad is initialized

the

MVC triad is initialized.

10

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Model

-View-Controller: Consequences

Model View Controller: Consequences^9

Multiple views of the same model

9

Multiple

views of the same model

9

Synchronized views

9

'Pluggable' views and controllers

9

Exchangeability of 'look and feel'

g

y

9

Framework potential

8

Increased complexity

8

Potential for excessive number of updates

8

Potential for excessive number of updates

8

Close couplings

11

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Interactive Systems: Presentation-Abstraction-Control

y

Context -

Development of an interactive application with the

help of agents

„

Problem

Forces are as follows:

Problem

-

Forces

are as follows:

Agents often maintain their own state and data.

Interactive agents provide their own user interface.

Systems evolve over time.

13

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Presentation

-Abstraction-Control: Structure

Presentation Abstraction Control: Structure^ „

Interactive application is structured as a tree

-like hierarchy of PAC agents.

Interactive application is structured as a tree like hierarchy of PAC agents.

‰

There should be one top-level agent, several intermediate level agents, andeven more bottom-level agents.

‰

Every agent consists of three components:

presentation

abstraction

and

‰

Every agent consists of three components:

presentation,

abstraction, and

control.

Th

T

l^

l PAC

t

„

Th

e

Top-level PAC agent:

provides the functional core of the system;

includes parts of the user interface that cannot be assigned to subtasks.

p

g

„

Bottom-level PAC agents:

represent self-contained semantic concepts on which users of the system canact

such as spreadsheets and charts

act, such as spreadsheets and charts.

„

Intermediate-level PAC agents:

represent either combinations of, or relationships between, lower-level agents.

14

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Presentation-Abstraction-Control: Structure

  • Components

p

16

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Presentation-Abstraction-Control: Dynamics

  • Scenario I

y

„

Cooperation between different PAC agents when opening a new bar

-chart

Cooperation between different PAC agents when opening a new bar chartview of the election data.

17

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Presentation-Abstraction-Control: Consequences

q

9

Separation of concerns

9

Support for change and extension

9

Support for change and extension

9

Support for multi-tasking

8

Increased system complexity

8

Complex control component

8

Complex control component

8

Efficiency

8

Applicability

19

Sharif University of Technology

Patterns in Software Engineering – Lecture 8

Architectural: Adaptable SystemsArchitectural:

Adaptable Systems

„

Reflection:

p

rovides a mechanism for changing structure and behavior of p

g

g

software systems dynamically.

Supports the modification of fundamental aspects, such as type structures andfunction call mechanisms.function call mechanisms.

An application is split into two parts.

„

A

meta level provides information about selected system properties and makes the software self-awaresoftware self aware.

„

A

base level includes the application logic; its implementation builds on the meta level.

„

Microkernel:

Applies to software systems that must be able to adapt to

„

Microkernel:

Applies

to software systems that must be able to adapt to

changing system requirements.

separates a minimal functional core from extended functionality and customer-specific parts.

serves as a socket for plugging in such extensions and coordinating theircollaboration.

20

Sharif University of Technology