1 / 27

Systems Analysis

Systems Analysis. I introduction. Contents. Introduction 3 classic phases Literature What is important (Critical Success Factors) Some anti-patterns and code smells. 3 classic phases in software-development. 0 Background =knowledge about the subject = most important phase

zuzela
Télécharger la présentation

Systems Analysis

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Systems Analysis I introduction

  2. Contents • Introduction • 3 classic phases • Literature • What is important (Critical Success Factors) • Some anti-patterns and code smells Systems Analysis - Introduction

  3. 3 classic phases in software-development • 0 Background • =knowledge about the subject • =most important phase • Often neglected or ‘forgotten’ • 1 Conception • often called ‘analysis’ • Pointless without stage 0 • 2 Design/Specification • Already contains some implementation decisions • 3 Implementation • Turns out to be more important then we thought in de 70's and 80's. Systems Analysis - Introduction

  4. Remarks • Unlike what we used to think, the phases do not have to be followed in any strict order. • You should know realize however, what phase you are in. • Analysis ≠ exact science. IT is still too young. : USEFULNESS is the only reasonable measure to evaluate analysis techniques. • The Implementation phase is important. Things can still go awfully wrong in this phase. Programming is no routine act. Systems Analysis - Introduction

  5. Evolution of Systems Analysis:sequences The evolution of systems analysis has always been influenced by programming languages and databases, unlike what you might expect. The main theme is: higher levels of abstraction. • Electric switches • Assembler language • sequential, cryptic, machine dependent • registers • conditional jumps -> Flow Charts • Interpreted sequential languages: e.g. Basic • sequential, less cryptic, can be machine independent • global variables • conditional jumps -> Flow Charts Systems Analysis - Introduction

  6. Evolution of Systems Analysis:functional decomposition • Procedural languages: e.g. Algol 68, Pascal • procedures and functions • local variables, parameter passing • Conditional jumps are replaced • by if then else statements • by structured loops (for, while) -> Structured Techniques: Nassi-Schneidermann, Jackson SP, etc. -> Functional decomposition Systems Analysis - Introduction

  7. Evolution of Systems Analysis:data Now people started realizing that they were neglecting an important issue: DATA. Putting the emphasis on data, turned out to be an excellent idea. Suddenly people could look at the bigger picture. Data (state) is much more stable than functionality (behavior). So systems built a around data are more stable, easier to understand, easier to adapt, etc. Systems Analysis - Introduction

  8. Evolution of Systems Analysis:normalized data An excellent mathematical theory was developed as a theoretical basis for databases. • Relational Databases: • can be normalized -> avoid inconsistencies • Allow a seamless transition from analysis to database implementation: -> E.R. modeling, normalized E.R. models Systems Analysis - Introduction

  9. Evolution of Systems Analysis:Object Orientation Full blown object oriented languages have been around since the early seventies. They took a long time to be widely adopted, even by analysts. An introduction to OO modeling will be given this semester. • Object Oriented languages • Classes and encapsulation: • State (data) and its behavior are put together in a class of which the instances are called objects. Client code can only change the state of an object indirectly (by using methods). • Inheritance: • New classes can be created by inheriting code from old ones (without copy pasting ) • Polymorphism: • The same variable can contain objects of different classes and a same routine call (=method) can result in different behavior depending on the class of the object. Systems Analysis - Introduction

  10. Evolution of Systems Analysis:Object Orientation Object Orientation looks like the right thing to do. However there are some problems: • OO is hard. It takes experience to tell the difference between a useful and a useless design. • Unlike E.R. modeling and relational databases, OO lacks strict rules, making OO modeling a bit arbitrary. • Relational databases are ubiquitous and well understood. Converting objects to records remains a challenge. OO databases are not main-stream yet. Systems Analysis - Introduction

  11. Important OO works • ’50ies en ’60ies: Early works about Simula , Nygaard & Dahl • phase 3, programming simulations • First steps to a real OO language, • With SmallTalk, it became the inspiration for OO Analysis • 1991: Object-Oriented Analysis, Coad & Yourdon • phase 1 • Short & simple but theoretical work Systems Analysis - Introduction

  12. Important OO works • 1985: Eiffel, A Language for Software Engineering, Bertrand Meyer • Phase 3, but also 1 en 2 (part of the point) • 1988: OO Software Construction, Bertrand Meyer • Phase 1, 2 en 3 • Classic, quite hard, full of humor, very convincing, Meyer is a real guru. Systems Analysis - Introduction

  13. Important OO works 1994: Design Patterns, Gamma & Helm & Johnson & Vlissides • Phase 2, also 3 • Concentrates on design. • Structured no nonsense catalog of OO design patterns. Quite difficult but extremely useful work. Systems Analysis - Introduction

  14. OO Literature • 1999: Refactoring, Improving the Design of Existing Code, Martin Fowler • Phase 3, also 2 • Is about turning bad code into good code. Contains lots of recognizable design problems for anyone who had to work with existing bad code. • The emphasis is on the importance of automatic testing. • Others: Kent Beck, Ivar Jacobson, Barbara Liskov, James Rumbaugh, Bjarne Straustrup (C++), … Systems Analysis - Introduction

  15. What is important ?Respect What is the difference between a success and failure ? Some Critical Success Factors for software engineering: • Respect for • The client • the technology. What technology is less important • procedural programming versus OO programming • relational databases versus OO databases • Java versus VB versus C++ etc. • bare hand versus RAD-tools • yourself and the other team members. • If you are not motivated, you should find another job quickly. Systems Analysis - Introduction

  16. What is important ?Communication • Background knowledge about the client’s business & communication with the client in general • e.g. knowledge about the requirements: what does the client want ? Impressive systems have been developed that were not wanted nor needed by the client. Systems Analysis - Introduction

  17. What is important ?Communication Systems Analysis - Introduction

  18. What is important ?Automated tests • Automated Tests • Enable continuous improvement of code design. • Tell you whether the code works according to the specifications. The important word here is automated. This means that the testing code itself • Compares the result of the tested code with the expected result. • Reports problems. If every test went well, no extensive listings are needed. (No screen staring necessary) Systems Analysis - Introduction

  19. What is important ?Project Management • Project Management • Charismatic project leader who does real work and who is generally respected. • Project planning: Clear and easily verifiable goals. • Methodology-process: There has to be a generally accepted process. Systems Analysis - Introduction

  20. What is important ?Avoid copy pasting code • Avoid Copy-Paste code • Looks like a detail, but it’s really not. • Copy-Paste programming is THE cause of failure in phase 3 when large projects are involved . It gives enables exponentially growing code: x2, x4, x8, x16, x32 …→ ∞ → not maintainable. • Remedy: Collect common code, • call it • OR put it in a common class to which you delegate • OR put it in a superclass Systems Analysis - Introduction

  21. Some anti-patterns en code smells. I Anti-patterns Anti-pattern: common bad solution Code smell: suspect code (Fowler, Beck) Systems Analysis - Introduction

  22. Anti-patterns • Anti-patterns Some Anti Patterns ( Brown, Malveau,…): • The Blob: monolithic (non partitioned) huge procedure or class • Lava Flow: gradually degrading structure, due to new programmers that are non willing to read the old code. • Golden Hammer: wanting to do everything with 1 sacred tool. Example: everything in Excel macro’s, everything with XML. Systems Analysis - Introduction

  23. Anti-patterns • Spaghetti-code (too much dependence, goto) • Cut & paste programming (see above) • Vendor Lock-In • Design by committee: • Lack of leadership -> messy design • Reinvent the Wheel • Not knowing off the shelf products • Analysis Paralysis • Lost touch with reality • Arguing about unimportant details Systems Analysis - Introduction

  24. Code smells (phase 2 & 3) • Code Smells (Words used by Kent Beck & Martin Fowler) • Duplicate code (copy paste, see above) • Too much parameters • Too many properties in a class (data-fields) • Too much code in 1 class • Too many similar procedures or classes Systems Analysis - Introduction

  25. Code smells • Data-classes: no methods or only get/set-methods. • method-classes: no data-fields or hardly used data-fields. (OK for design-level classes, but not for classes retained from analysis) • Cryptic naming • Lots of documentation (needed ?) -> probable design flaw • Cause: Unconscious Incompetence http://c2.com/cgi/wiki?UnconsciousIncompetence Systems Analysis - Introduction

  26. The handbook This semester we will focus on traditional proven techniques. A special course on OO Analysis is given in the third year. Our book for this year is: • Title: Systems Analysis and Design Methods, Sixth Edition • Authors: Whitten-Bentley-Dittman • Publisher: McGraw-Hill, 2003, • ISBN: 0-07-121521-2 Slide handouts will be made available. Systems Analysis - Introduction

  27. Evaluation • Group assignment: 40% • Theory: 30 % • Exercises: 30% Systems Analysis - Introduction

More Related