Technical Specification Methods

更新时间:2023-06-10 15:10:01 阅读量: 实用文档 文档下载

说明:文章内容仅供预览,部分内容可能不全。下载后的文档,内容与下面显示的完全一致。下载之前请确认下面内容是否您想要的,是否完整无缺。

Technical Specification Methods

IS 1024 Information SystemsLecture 6Technical Methods For Specifying Requirements(From: Leffingwell Chp 24)

UML State Diagrams(From: Fowler Chp 10 &http://pigseye.kennesaw.edu/~dbraun/csis4650/A&D/UML_tutorial/state.htm)

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Key points– Some reqs too complex and/or critical for natural language – Several alternative techniques available – Most require special training – Use only when necessary since most users won t understand them – Use in combination with natural language

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods If you can t afford a misunderstanding, supplement natural language with a technical specification

Pseudocode– Specification in a programming like language – Hybrid between natural language & programming language w/ strict syntax

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Pseudocode– No official version – Use Verb-Object imperative sentences – Small vocabulary of action-oriented verbs – Use understandable names – Decisions using IF-ELSE – Loops using DO-WHILE, FOR-NEXT – Sensible formatting for readability – Can be understood by most users if wellwrittenCopyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Pseudocode– Very useful when specifying a calculation – Reduces programming errors – Can be incorporated into a UC as supplemental info

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Finite State Machines– Models how a system changes state based on system inputs and its internal processing on those inputs – System should always be in a defined state – System transitions between states via defined events or actions – Used extensively in CS and is well studied (used for decades in hardware design)

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Finite State Machines– State Machine Diagram is UML version Will defer details to Fowler discussion…

– Notation details vary, but basically Each valid state represented by a box States connected by directed lines Directed lines labeled with event/action that triggers the transition between states

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Finite State Machines– In a typical business system, most objects do not exhibit significant state changes – Key is identifying those that do & ensuring UC properly accounts for those state changes – State-based behavior typically cuts across multiple UCs – In a business system, can you think of an entity that exhibits important state changes? – How does this impact UC writing?Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Finite State Machines– Can represent state in UCs using status – Consider UC: Rent Vehicle Can t rent a vehicle that is not available– System verifies that selected vehicle status is available

After rental process is complete, must ensure vehicle can t be rented until you return it– System changes vehicle status to rented

– Failure to properly specify state (status) is common error in UC writingCopyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Decision Tables & Trees– Useful for the depiction of system responses regarding various input combinations that generate multiple outputs – IF-THEN-ELSE logic – Can be displayed in tabular form (Table 24-1 p. 283) or tree form (Fig. 24-3 p. 284) – Good when complex conditional logic is involved – Helps ID missed alternativesCopyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Activity Diagram– Updated UML version of the venerable flowchart (Fig. 24-4, p. 285) – Very easy for users to understand when properly drawn – Simple notation, will defer to Fowler discussion – Excellent for depicting parallel workflows

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Entity-Relationship Diagrams (ERD)– The standard relational database modeling technique; an essential model artifact – Assumes knowledge of RDB principles Tables & records Primary & Foreign Keys Normalization

– Would get additional exposure in IS 1022 (database) – Easily confused with OO class diagramsCopyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

Technical Specification Methods Concluding advice– Technical specification methods should supplement natural language specifications – They are NOT a substitute – Mastery of these techniques will separate you from the pack

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

IS 1024 Information Systems

UML State Diagrams

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

State Machine Diagram State machines date from 1960s– Petri Nets (much more complex) – SMDs heavily influenced by Harel Statecharts

SMD can depict lifecycle of an entity or SW object Agile modelers aren t fans of SMDs– In typical business system, not many objects exhibit complex state changes – More common in control systemsCopyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

State Machine Diagram SMDs useful for modeling stateful entities across multiple use cases Use SMDs to model changes in state (i.e., status) of an entity in response to key events For example, a bank loan application– Must be verified as complete before it can be evaluated – Must be evaluated

before it can be approved/declined – Must be approved before funds can be lent – Must be paid off in full before it can be closed outCopyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

State Machine Diagram

Transition syntax– Trigger Event [guard] / activity to perform

Copyright 2005 by Glenn L. Ray, all rights reserved

Technical Specification Methods

State Machine Diagram

Copyright 2005 by Glenn L. Ray, all rights reserved

本文来源:https://www.bwwdw.com/article/qa51.html

Top