SDS Foil no 1 SDL – Inheritance. SDS Foil no 2 Controller behaviour to Central Validation Idle Code (cid,PIN) Code(cid, PIN) via U Validation virtual.

Slides:



Advertisements
Similar presentations
SDL-2000 Foil no Rolv Bræk; NTNU, SINTEF Birger Møller-Pedersen; Ericsson SDL-2000 = SDL-96 + UML + - New ITU-T SG10 recommendations, due.
Advertisements

R4 Dynamically loading processes. Overview R4 is closely related to R3, much of what you have written for R3 applies to R4 In R3, we executed procedures.
Slide: 1 Copyright © AdaCore Arrays Presented Quentin Ochem university.adacore.com.
Composition CMSC 202. Code Reuse Effective software development relies on reusing existing code. Code reuse must be more than just copying code and changing.
Chapter 3: The Enhanced E-R Model
Chapter 3  Define terms  Understand use of supertype/subtype relationships  Understand use of specialization and generalization techniques  Specify.
Advanced Data Modeling
CSI5118 W2001 Outline –Review Verification & Validation –Introduction to EFSM Models –Introduction to SDL e.g. EggTimer –Principles of Validation & Verification.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 6 Advanced Data Modeling.
Database Systems: Design, Implementation, and Management Tenth Edition Chapter 5 Advanced Data Modeling.
Database Systems: Design, Implementation, and Management Tenth Edition
Chapter 6 Advanced Data Modelling
BIS Database Systems School of Management, Business Information Systems, Assumption University A.Thanop Somprasong Chapter # 6 Advanced Data Modeling.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 6 Advanced Data Modeling.
Winter 2007SEG2101 Chapter 41 Chapter 4 SDL – Structure and Behavior.
Criteria for good design. aim to appreciate the proper and improper uses of inheritance and appreciate the concepts of coupling and cohesion.
Data Modeling Entity - Relationship Models. Models Used to represent unstructured problems A model is a representation of reality Logical models  show.
Lecture a: Additional UML Models: Package, Activity, Deployment Lecture b: Generalization, Aggregation and Additional Domain Model Notation Copyright W.
Working with Workgroups and Domains
Class Agenda – 04/04/2006 Discuss database modeling issues
1 Chapter One A First Program Using C#. 2 Objectives Learn about programming tasks Learn object-oriented programming concepts Learn about the C# programming.
Object Oriented Software Development
SDS Foil no 1 How to make real systems: Implementation design, deployment and realisation.
IAY 0600 Digital Systems Design
An Introduction to Unix Shell Scripting
Mentor Tools tutorial Bold Browser Design Manager Design Architect Library Components Quicksim Creating and Compiling the VHDL Model.
SDS Foil no 1 How to make real systems: Implementation design, deployment and realisation.
SDS Foil no 1 PBX Make your own PBX – solution sketch.
Working with Numeric Variables (Unit 6) Visual Basic for Applications.
FDT Foil no 1 Overall Methodology – from Engineering RT Systems through TIMe; to RAM. Covering the full development cycle Supporting the whole company.
Chapter 8 Data Modeling Advanced Concepts Database Principles: Fundamentals of Design, Implementation, and Management Tenth Edition.
1 Classes and Controls CE-105 Spring 2007 By: Engr. Faisal ur Rehman.
Question of the Day  On a game show you’re given the choice of three doors: Behind one door is a car; behind the others, goats. After you pick a door,
Winter 2007, rev. 2008SEG Chapter 21 Chapter 2 Basic Principles.
SDL as an Object Oriented Language Lecture 6 Huma Ayub Software Engineering Department 1.
Making Frameworks using SDL Foil no SINTEF Telecom and Informatics SAM 98 Making Frameworks using SDL Birger Møller-Pedersen ERICSSON Rolv.
Chapter Eleven Classes and Objects Programming with Microsoft Visual Basic th Edition.
FDT Foil no 1 Overall Methodology – from Engineering RT Systems through TIMe; to RAM. Covering the full development cycle Supporting the whole company.
Oracle 11g: SQL Chapter 4 Constraints.
Object-Oriented Modeling: Static Models. Object-Oriented Modeling Model the system as interacting objects Model the system as interacting objects Match.
Object Oriented Analysis and Design Class and Object Diagrams.
Introduction to c++ programming - object oriented programming concepts - Structured Vs OOP. Classes and objects - class definition - Objects - class scope.
SDS Foil no 1 V&V&S Verification, Validation and Synthesis: doing away with defects Verification, Validation and Synthesis: doing away with defects.
Programming with Microsoft Visual Basic 2012 Chapter 11: Classes and Objects.
Database Systems: Design, Implementation, and Management Ninth Edition
Application development with Java Lecture 21. Inheritance Subclasses Overriding Object class.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
FDT Foil no 1 MSC Structuring MSCs Using Message Sequence Charts for real systems.
The State Pattern (Behavioral) ©SoftMoore ConsultingSlide 1.
Passing Parameters. 2 home back first prev next last What Will I Learn? List the types of parameter modes Create a procedure that passes parameters Identify.
M1G Introduction to Programming 2 2. Creating Classes: Game and Player.
Copyright © 2009 Pearson Education, Inc. Publishing as Prentice Hall Appendix A Object-Oriented Analysis and Design A.1.
Ch 05. Basic Symbols ( manino ). Cardinalities Cardinality Notation.
FDT Foil no 1 Basic SDL Specification and Description Language Basic SDL.
Data Modeling Advanced Concepts Updated 20/4/2015 TMC2034 Database Concept and Design1.
1 An SDL Tutorial Two primary elements: –Structure –Identifies the various components of the system, and the communication paths among them. –Components:
Lecture # 14 Chapter # 5 The Relational Data Model and Relational Database Constraints Database Systems.
CE-105 Spring 2007 By: Engr. Faisal ur Rehman
LECTURE 4: Chapter 4: The Enhanced E-R Model
CARA 3.10 Major New Features
Class Diagrams.
Java Primer 1: Types, Classes and Operators
Exceptions An exception signals an error, and has the ability to propagate upward through the call stack for easier management To “raise” an exception,
CHAPTER 3: THE ENHANCED E-R MODEL
Chapter 5 SDL - Data 2007, rev. 08 SEG2101 Chapter 5.
IAY 0600 Digital Systems Design
Process Identification (PId)
Chapter 5 Advanced Data Modeling
Database Management System
Presentation transcript:

SDS Foil no 1 SDL – Inheritance

SDS Foil no 2 Controller behaviour to Central Validation Idle Code (cid,PIN) Code(cid, PIN) via U Validation virtual OK to cur_panel cur_panel := sender NOK to cur_panel Idle process type Controller dcl cur_panel PId ; /* current panel whose Code will be validated */ dcl cid, PIN integer ; /* temporary variables for the data attributes of 'Code' */ 1(2) [Code] [(validity)] [opened,closed] [open,close] [(validity)] [Code] P D U Opening Open /* to Door */

SDS Foil no 3 Behaviour inheritance process type BlockingController inherits Controller 1(1) * Disable BlockDoor blocked Enable Idle U [Disable,Enable] * BlockDoor For all states Add transition To new state Add signals «process» controller «process» BlockingController

SDS Foil no 4 Inherited behaviour to Central Validation Idle Code (cid,PIN) Code(cid, PIN) via U Validation virtual OK to cur_panel cur_panel := sender NOK to cur_panel Idle process type Controller dcl cur_panel PId ; /* current panel whose Code will be validated */ dcl cid, PIN integer ; /* temporary variables for the data attributes of 'Code' */ 1(2) [Code] [(validity)] [opened,closed] [open,close] [(validity)] [Code] P D U Opening Open /* to Door */

SDS Foil no 5 Who can interwork correctly? a:controller u b:blocking controller u c:validation d:blocking validation

SDS Foil no 6 code OK NOK opened closed Idle Validation Controller blockingController code OK NOK opened closed Disable Enable Validation Idle Controller Blocked Subtyping for states and transitions

SDS Foil no 7 e [(inp)] [(outp)] block type BlockingAccessPoint 1(1) Door [(validity)] [code] [opened, closed] [open, close] [(inp)] [(outp)] [(validity)] [Code] P1 signal opened,closed ; /* Door -> Controller */ signal open, close ; /* Controller -> Door */ CE CU D C [(validity)] [Code] apc: Blocking Controller P D U Panel [unlock, lock] d [unlock, lock] [isOpen, isClosed] [isOpen, isClosed] BlockingController Using the Blocking controller – the BlockingAccessPoint could we define this by inheriting from AccessPoint?

SDS Foil no 8 «block» AccessPoint «block» BlockingAccessPoint «block» LoggingAccessPoint Inheritance: pure extension «process» controller «process» BlockingController «process» LoggingController Note that this is valid SDL-2000 notation!

SDS Foil no 9 «block» AccessPoint «block» BlockingAccessPoint «block» LoggingAccessPoint Inheritance: virtual to enable changes «process» controller {virtual} «process» Controller {redefined} «process» Controller {finalised}

SDS Foil no 10 Virtual process in modified AccessPoint e [(outp)] block type AccessPoint 1(1) Door [(validity)] [code] [opened, closed] [open, close] [(inp)] [(outp)] [(validity)] [Code] P1 signal open, close ; /* Controller -> Door */ signal opened, closed ; /* Door -> Controller */ CE CU D C [(validity)] [Code] apc: Controller P D U Panel [unlock, lock] d [unlock, lock] [isOpen, isClosed] [isOpened, isClosed] Virtual Controller [(inp)]

SDS Foil no 11 Virtual process Validation Code (cid,PIN) Code(cid,PIN ) via U Validation OK to cur_panel Idle cur_panel := sender unlockDoor NOK to cur_panel Idle virtual process type Controller dcl cur_panel PId ; /* current panel whose Code will be validated */ dcl cid, PIN integer ; /* temporary variables for the data attributes of 'Code' */ 1(1) [Code] [(validity)] [opened,closed] [open,close] [(validity)] [Code] P D U Idle OK NOK

SDS Foil no 12 redefined C [Enable, Disable] block type blockingAccessPoint inherits AccessPoint Controller existing gate added signals Inheriting AccessPoint: BlockingAccessPoint Note that the full structure of AccessPoint is inherited here!

SDS Foil no 13 Inherited structure e [(outp)] block type AccessPoint 1(1) Door [(validity)] [code] [opened, closed] [open, close] [(inp)] [(outp)] [(validity)] [Code] P1 signal open, close ; /* Controller -> Door */ signal opened, closed ; /* Door -> Controller */ CE CU D C [(validity)] [Code] apc: Controller P D U Panel [unlock, lock] d [unlock, lock] [isOpen, isClosed] [isOpened, isClosed] Virtual Controller [(inp)]

SDS Foil no 14 Redefined process type: Controller in blocking AccessPoint redefined process type Controller1(1) * Disable BlockDoor blocked Enable Idle U [Disable,Enable] *

SDS Foil no 15 blocktype loggingAccessPoint inherits AccessPoint 1(1) finalised Controller apc: Controller LogDevice [(validity),Code] L LD existing instance added signalroute Inheriting structure: LoggingAccessPoint added process «block» AccessPoint «block» LoggingAccessPoint

SDS Foil no 16 Virtual process with virtual transitions Validation Code (cid,PIN) Code(cid,PIN ) via U Validation OK to cur_panel Idle cur_panel := sender unlockDoor NOK to cur_panel Idle virtual process type Controller dcl cur_panel PId ; /* current panel whose Code will be validated */ dcl cid, PIN integer ; /* temporary variables for the data attributes of 'Code' */ 1(1) [Code] [(validity)] [opened,closed] [open,close] [(validity)] [Code] P D U Idle OK NOK virtual

SDS Foil no 17 OK to cur_panel via P Idle unlockDoor NOK to cur_panel via P Idle NOK finalised process type controller1(1) [Code, (validity)] L Validation Redefined and finalized transitions redefinedfinalized OK, Code(cid,PIN) via L NOK, Code(cid,PIN) via L «process» controller {virtual} «process» controller {finalised}

SDS Foil no 18 Virtual Procedures virtual whenOK virtual whenNotOK unlockDoor Validation Idle Code (cid,PIN) Code(cid,PIN ) via U Validation OK cur_panel := sender NOK process type Controller dcl cur_panel PId ; /* current panel whose Code will be validated */ dcl cid, PIN integer ; /* temporary variables for the data attributes of 'Code' */ 1(1) [Code] [(validity)] [opened,closed] [open,close] [(validity)] [Code] P D U Idle unlockDoor Idle whenOK whenNotOK

SDS Foil no 19 process type loggingController inherits Controller L [Code,OK,NOK] redefined WhenOK redefined WhenNOK Redefining virtual procedures

SDS Foil no 20 CentralUnit Building a system from components system type AccessControl use AccessPointLib ap(100): AccessPoin t ce d bp(10): Blocking AccessPoin t ce d lp(20): Logging AccessPoint ce d [(inp)] [(outp)] unlock, lock isOpen, isClosed [(validity)][Code] [(inp)] [(outp)] unlock, lock isOpen, isClosed [(validity), Disable, Enable] [Code] [(validity)][Code] [(inp)] [(outp)] unlock, lock isOpen, isClosed

SDS Foil no 21 package AccessPointLib AccessPointBlockingAccessPoint use SignalLib ; LoggingAccessPoint The Block types in the AccessPointLib Package

SDS Foil no 22 signal opened,closed ; /* Door to Controller */ signal open, close ; /* Controller to Door */ package SignalLib signal eject-card, lock, unlock input-card, isOpen, isClosed display, keys; signal Code(integer,integer); signal OK,NOK,ERR ; signallist validity = OK, NOK, ERR ; signallist outp = EjectCard, display; signallist inp = InputCard, keys ; /* AccessPoint /* ENV /* Display /* ENV /* AccessPoint /* CentralUnit to ENV */ to AccessPoint*/ to ENV */ to Keyboard */ to CentralUnit */ to AccessPoint */ signal Disable, Enable /* CentralUnit to BlockingAccessPoint */

SDS Foil no 23 system type GeneralAccessControl use SignalLib ; use PanelLib / PanelInterface; use DoorLib / DoorInterface; virtual process type Panel atleast PanelInterface virtual process type Door atleast DoorInterface virtual Doorvirtual Panel ls(10): AccessPoint CentralUnit CE C [(validity)][Code] e c [(inp)][(out)] package SystemTypes AccessPoint Specialisation of system types d

SDS Foil no 24 Redefined process type Panel inherits PanelInterface Redefined process type Door inherits DoorInterface redefined Doorredefined Panel system type MyAccessControl inherits GeneralAccessControl package SpecialSystemTypes use SystemTypes

SDS Foil no 25 system MAC: MyAccessControl useSpecialSystemTypes; System Instance

SDS Foil no 26 <SIGNAL OK,NOK,ERR,Code(integer,integer), ejectCard, inputCard, display, keys> [Code] e [(inp)] [(outp)] virtual Controller block type AccessPoint 1(1) Door [(validity)] [code] [opened, closed] [open, close] [(inp)] [(outp)] [(validity)] [Code] P1 signal opened,closed ; /* Door -> Controller */ signal open, close ; /* Controller -> Door */ CE CU D C [(validity)] apc: Controller P D U Panel [unlock, lock] d [unlock, lock] [isOpen, isClosed] [isOpen, isClosed] signallist validity = OK, NOK, ERR ; signallist outp = eject-card, display; signallist inp = input-card, keys ; Context parameters

SDS Foil no 27 system AccessControl 1(1) CE C [(inp)] [(outp)] [(validity)][Code] ap(100): AccessPoint <Ja,Nei,Feil, Kode, KortUt, KortIn, Skjerm, Taster> C e CentralUnit Actual context parameters use AccessPointLib/AccessPoint; Actual context parameter

SDS Foil no 28 system AccessControl 1(1) CE C [(inp)] [(outp)] [(validity)][Code] CF [(validity), Enable, Disable] [Code] CB ap(apn ): AccessPoint C bap( bapn ): Blocking AccessPoint e C [(inp)] [(outp)] e CentralUnit CG CL lap( lapn ): Logging AccessPoint e C [(validity)][Code] [(inp)] [(outp)] Context parameters for dimensioning d d d L Logger [Code, (validity)] LL

SDS Foil no 29 Variability in system families (Product lines) Is inheritance sufficient? Additional composition will be needed in many cases! Is inheritance sufficient? Additional composition will be needed in many cases! Package system lib Process types Block types System types System Installation33: SystemType5 System Installation45

SDS Foil no 30 Summary 1 (Inheritance) Specialization of process, state types and procedures Simple inheritance, adding properties Virtual procedures Virtual transitions Specialization of block types Simple inheritance, adding properties Virtual block types Virtual process types Virtual procedure types Specialization of data and signal types Simple inheritance, adding properties Specialization of process, state types and procedures Simple inheritance, adding properties Virtual procedures Virtual transitions Specialization of block types Simple inheritance, adding properties Virtual block types Virtual process types Virtual procedure types Specialization of data and signal types Simple inheritance, adding properties

SDS Foil no 31 Summary 2 (Virtual, redefined, finalized) Virtual types may have virtuality constraints given by an atleast-clause which specifies a minimum type which the analysis of the enclosing type may take for granted. When no atleast-clause is given, the default is that the original virtual type itself is the constraint type. A redefined type is a type which is specified as virtual in a supertype of the type enclosing the redefined type. A redefined type must be a specialization of the virtuality constraint. A redefined type may be further redefined in specializations of its encloser. A finalized type is a type which is specified as virtual in a supertype of the encloser. A finalized type must be a specialization of the virtuality constraint. A finalized type may not be defined again in specializations of its encloser. Virtual, redefined and finalized can also be used for individual transitions in processes. The virtuality specification can occur in input symbols, start symbols and save symbols. Virtual types may have virtuality constraints given by an atleast-clause which specifies a minimum type which the analysis of the enclosing type may take for granted. When no atleast-clause is given, the default is that the original virtual type itself is the constraint type. A redefined type is a type which is specified as virtual in a supertype of the type enclosing the redefined type. A redefined type must be a specialization of the virtuality constraint. A redefined type may be further redefined in specializations of its encloser. A finalized type is a type which is specified as virtual in a supertype of the encloser. A finalized type must be a specialization of the virtuality constraint. A finalized type may not be defined again in specializations of its encloser. Virtual, redefined and finalized can also be used for individual transitions in processes. The virtuality specification can occur in input symbols, start symbols and save symbols.

SDS Foil no 32 Summary 3 (analyzability) Specifying a type as virtual decreases the degree of analysis which can be performed on its encloser (since the instances of the virtual type may be of a type which is actually not known at the analysis of the encloser). However, it increases the flexibility of specializations. Finalizing a type increases the degree of analysis which can be performed on the encloser. Specifying a type as virtual decreases the degree of analysis which can be performed on its encloser (since the instances of the virtual type may be of a type which is actually not known at the analysis of the encloser). However, it increases the flexibility of specializations. Finalizing a type increases the degree of analysis which can be performed on the encloser.