90 likes | 180 Views
Génie logiciel Software Engineering Summary C. Petitpierre. Development methodologies. UML: scenarios and diagrams RUP: project organization based on UML CMMI: project organization, 5 levels not organized project level management, tools for planning, quality assurance, configuration
E N D
Development methodologies • UML: scenarios and diagrams • RUP: project organization based on UML • CMMI: project organization, 5 levels • not organized • project level management, tools for planning, quality assurance, configuration • company level management, training, risk analysis • performance analysis, norms, statistics • proactive fault avoidance, continuous adaptation and improvement • XProgramming: implementation centered • continuous coordination with the customer, working slices of project, pair programming, TDD
Design Patterns: Basic concepts • Inheritanceextends, implements • Composition class CompositionClass {SuperClass element; } • Forwardingpublic String getName() { return element.getName(); } • Delegationpublic String getName() { return element.getName(this); }
GoF design patterns • Singleton(global object, Threadlocal) • Composite(tree with the same interface for the nodes and the leaves) • Decorator( new X(new Y(newZ())) ) • Flyweight(objects referenced from a position collection and an identity collection) • Observer (used to build listeners that listen or observe subjects) • Proxy (Remote proxy, Virtual proxy, Protection proxy, Handle) • Iterator (used to walk through a list) • Prototype (creation of objects by cloning, in Java may use Cloneable) • Façade (access to many operations through the same object)
GoF design patterns • Command(operation and operands defined in an object) • Chain of responsibility(operations defined in a list or list of commands) • Memento(used to save a state)
GoF design patterns • Factories • Abstract Factory: creation of objects according to some properties defining the factory to instantiate • Factory Method: creation of different objects defined by the user’s requests or by some property determined at the creation (parameter in the call, “.gif” versus “.jpg”) Usually use Java Reflection ( Class.forName(), Method meth, meth.invoke() )
GoF design patterns • Mediator (central object that relays the calls between the colleagues) • Adapter(interface and delegation) • Template (classical use of an abstract class to cover different implementation • Strategy (similar to the template, but with a delegation) • Builder (same diagram as strategy (?) ) • Bridge (developer’s and implementation hierarchies, the first one calls the second one by delegation)
GoF design patterns • State(used to create FSMs, in protocols, user interfaces, language handling) • Interpreter (list or tree of operations that computes an expression when walked through) • Visitor (object that can be executed within the nodes of an AST -abstract syntax tree- to perform a compilation operation)
JavaCC • Tokens (skip, token, special_token, more) • token.next, token.specialToken • Productions • recursive methods, lookahead, getNextToken(), getToken(index) - in the main file • Tree (one node per production) • SimpleNode • beginToken, endToken • dump • jjtAccept, childrenAccept • visitor