《高级软件工程》学习资料(英文版)sept222

Abstract Model Specifications Build an abstract model of required software behavior using mathematically defined(perhaps using axioms )types(e. g sets, relations) Define operations by showing effects of that operation on the model Specification includes Model Invariant properties of model For each operation name parameters return values Pre and post conditions on the operations
Abstract Model Specifications Build an abstract model of required software behavior using mathematically defined (perhaps using axioms) types (e.g., sets, relations). Define operations by showing effects of that operation on the model. Specification includes: Model Invariant properties of model For each operation: name parameters return values Pre and post conditions on the operations Copyright c Nancy Leveson, Sept. 1999 �

Z(pronounced zed Z specifications are made up of"schemas A schema is a named, relatively short piece of specification with two parts Above the line the definition of the data entities Below the line the definition of invariants that hold on those data entities Copyright Nancy Leveson, Sept. 1999
Z (pronounced Zed) Z specifications are made up of "schemas" A schema is a named, relatively short piece of specification with two parts: Above the line: the definition of the data entities Below the line: the definition of invariants that hold on those data entities Copyright c Nancy Leveson, Sept. 1999 �

Z: Defining the abstract model Library books:P BOOK status: BOOK k STATUS books dom status Declaration says library has two visible parts of its state books is a set of books. which are atomic elements status is a partial function that maps a booK into a status (which is another atomic element that can take values In or out) The invariant says the set of books is precisely the same as the domain of the function status Says every book in the Library has exactly one status Two books may have the same status EXample of a legal state for Library is books=Principia Mathematica, Safeware status=(Principia Mathematica h-In Safeware r- Out Copyright Nancy Leveson, Sept. 1999
Z : Defining the Abstract Model Library books: BOOK status: STATUS books = dom status P BOOK Declaration says library has two visible parts of its state: books is a set of BOOKS, which are atomic elements. status is a partial function that maps a BOOK into a STATUS (which is another atomic element that can take values In or Out) The invariant says the set of books is precisely the same as the domain of the function status. Says every book in the Library has exactly one status Two books may have the same status. Example of a legal state for Library is: books = {Principia Mathematica, Safeware} status = (Principia Mathematica In, Safeware Out} c Copyright Nancy Leveson, Sept. 1999 �

Z: Defining Operations Borrow △ Library book ?: BOOK status(book? ) =In status= status o(book?out) A Library declaration says operation modifies state of Library book? is the input A prime indicates the value after the operation The first invariant defines a pre-condition on the operation, i.e the book to be borrowed must be currently checked in The second invariant defines the semantics of borrowing i e,ok it overwrites the entry in the status function for the borrowed bo ancy Leveson, Sept. 1999
Z : Defining Operations Borrow book?: BOOK Library status’ = status (book? status (book?) = In Out) Library declaration says operation modifies state of Library book? is the input A prime indicates the value after the operation The first invariant defines a pre-condition on the operation, i.e., the book to be borrowed must be currently checked in. The second invariant defines the semantics of borrowing, i.e., it overwrites the entry in the status function for the borrowed book. Copyright Nancy Leveson, Sept. 1999 c �

Z: Proving Properties EXample: After a borrow operation, the set of books in the library remains unchanged books'= books books'= dom status [from invariant of Library dom (status o (book? H Out]) [from post-condition of Borrow] dom(status v (book? H Outy) dom status v dom ((book?H+ Out]) Follow from mathematics book book? book [ true because first invariant of Borrow implies that book is an element of books
Z : Proving Properties Example: After a borrow operation, the set of books in the library remains unchanged. books’ = books books’ = dom status’ [from invariant of Library] = dom (status {book? Out}) [from post-condition of Borrow] = dom (status {book? Out}) = dom status dom ({book? Out}) Follow from mathematics = book book? = book [true because first invariant of Borrow implies that book? is an element of books] Copyright c Nancy Leveson, Sept. 1999 �

Z: Defining Observing Operations Find status Library book?: BOOK status!: STATUS book?∈book status!= status(book? E indicates state is not changed by operation(a lookup op) status is an output variable The first invariant says that schema only defined if the book is known. Therefore, function application in second invariant cannot fail
Z : Defining Observing Operations book?: BOOK Library status! : STATUS book? status! = status (book?) books Find Status indicates state is not changed by operation (a lookup op) status! is an output variable The first invariant says that schema only defined if the book is known. Therefore, function application in second invariant cannot fail. c Copyright Nancy Leveson, Sept. 1999 �

Z: Another Observing operation CheckedOut Library out!= P BOOK out!= b books status(b)=Outy Produces all the books that are currently checked out of library Returns a(possibly empty) set of books
Z : Another Observing Operation Library CheckedOut out! = P BOOK out! = { b:books | status(b) = Out} Produces all the books that are currently checked out of library Returns a (possibly empty) set of books. Copyright Nancy Leveson, Sept. 1999 c �

Z: Initialization InitLibrary Library books Still need schemas to add and remove books from the library
Z : Initialization InitLibrary Library books = Still need schemas to add and remove books from the library. Copyright Nancy Leveson, Sept. 1999 c �
按次数下载不扣除下载券;
注册用户24小时内重复下载只扣除一次;
顺序:VIP每日次数-->可用次数-->下载券;
- 《高级软件工程》学习资料(英文版)sept221.pdf
- 《高级软件工程》学习资料(英文版)sept14.pdf
- 《高级软件工程》学习资料(英文版)What about software.pdf
- 《高级软件工程》学习资料(英文版)Is there a problem.pdf
- 《数据库原理》SS2K3AccessMeth.ppt
- 《数据库原理》第10章 数据库管理.doc
- 《数据库原理》第9章 数据库设计.doc
- 《数据库原理》第8章 数据依赖和关系模式规范化.doc
- 《数据库原理》第7章 数据库安全及完整性约束.doc
- 《数据库原理》第6章 事务管理.doc
- 《数据库原理》第5章 查询处理与优化.doc
- 《数据库原理》第4章 数据库管理系统引论.doc
- 《数据库原理》第4章(图4).doc
- 《数据库原理》第4章(图3).doc
- 《数据库原理》第4章(图2).doc
- 《数据库原理》第4章(图1).doc
- 《数据库原理》第3章 关系数据库语言SQL.doc
- 《数据库原理》查询课程信息.doc
- 《数据库原理》学生选课信息查询.doc
- 《数据库原理》SS2K3AccessMeth.ppt
- 《高级软件工程》学习资料(英文版)oct13.pdf
- 《高级软件工程》学习资料(英文版)oct6.pdf
- 《高级软件工程》学习资料(英文版)sept29.pdf
- 《高级软件工程》学习资料(英文版)reviews.pdf
- 《高级软件工程》学习资料(英文版)oct20.pdf
- 《高级软件工程》学习资料(英文版)cots Reuse.pdf
- 《高级软件工程》学习资料(英文版)metrics2.pdf
- 《高级软件工程》学习资料(英文版)metrics1.pdf
- 《高级软件工程》学习资料(英文版)Can programming language influence correctness?.pdf
- 《高级软件工程》学习资料(英文版)A Model of Team development.pdf
- 《高级软件工程》学习资料(英文版)types of Characteristics.pdf
- 《高级软件工程》学习资料(英文版)Programming Languages.pdf
- 《高级软件工程》学习资料(英文版)Software System Safety.pdf
- 《Microsoft Project 2002 教学手册》讲义.pdf
- 《计算机软件技术基础》ppt电子课件.ppt
- 陕西国防学院:《电子商务概论》序言.pps
- 陕西国防学院:《电子商务概论》第二章 网络技术基础.pps
- 陕西国防学院:《电子商务概论》第五章 物流管理.pps
- 陕西国防学院:《电子商务概论》第三章 电子商务的应用框架与交易模式.pps
- 陕西国防学院:《电子商务概论》第一章 电子商务概述.pps