Note 11 Command Pattern SE2811 Software Component Design

Slides:



Advertisements
Similar presentations
Windows XP Basics OVERVIEW Next.
Advertisements

A Quick Review of Unit 2 – Using Windows 7 Computing Fundamentals © CCI Learning Solutions.
OOP Design Patterns Chapters Design Patterns The main idea behind design patterns is to extract the high level interactions between objects and.
Automating Tasks With Macros
Software Design & Documentation – Design Pattern: Command Design Pattern: Command Christopher Lacey September 15, 2003.
Command Design Pattern Source: Design Patterns – Elements of Reusable Object- Oriented Software; Gamma, et. al.
COMPREHENSIVE Windows Tutorial 10 Improving Your Computer’s Performance.
 The operating system is essential for the computer; without it the computer could not work.  The main function of any operating system is being an intermediary.
Presented by Chad Kafka This Month’s Topic: Wikispaces Advanced Today’s session is an introduction to what a WIKI is and how they can be used in education.
Detailed design – class design Domain Modeling SE-2030 Dr. Rob Hasker 1 Based on slides written by Dr. Mark L. Hornick Used with permission.
Design Patterns Part two. Structural Patterns Concerned with how classes and objects are composed to form larger structures Concerned with how classes.
Copyright © 2010 Wolters Kluwer Health | Lippincott Williams & Wilkins Introduction to Windows Chapter 2.
Linzhang Wang Dept. of Computer Sci&Tech, Nanjing University The Command Pattern.
NetTech Solutions Security and Security Permissions Lesson Nine.
Copyright © Robert W. Hasker, Based on About Face 4 th Ed: Cooper, Reimann, Cronin.
The desktop (overview) Working with desktop icons The desktop is the main screen area that you see after you turn on your computer and log on to Windows.
Jamilah Al-Saidan. Introduction to this Course This course is designed to introduce pharmacy students to data processing and programming with pharmaceutical.
© 2012 The McGraw-Hill Companies, Inc. All rights reserved. 1 Third Edition Chapter 6 Today’s Windows Windows Vista and Windows 7 McGraw-Hill.
William H. Bowers – Eliminating Excise Cooper 10.
Week 7, Class 1: The Command Pattern (cont.) Get Ready for Poll Everywhere Labs 2 & 3 returned Lab 7 due this evening at 11pm Quiz tomorrow at start of.
Model-View-Controller A Design Pattern SE-2030 Dr. Rob Hasker 1 Based on slides written by Dr. Mark L. Hornick Used with permission.
The Command Pattern SE-2811 Dr. Mark L. Hornick 1.
Transfer Contacts from iPhone to Android From:
Command Pattern. Intent encapsulate a request as an object  can parameterize clients with different requests, queue or log requests, support undoable.
CHAPTER 7 Operating System Copyright © Cengage Learning. All rights reserved.
PARTS.CAT.COM CLIENT TRAINING SIS – With 1.4m parts FOL – Frequent Order Lists Core Tracking Part Lookup Quick Order Quoting Setting Defaults Need.
ICAICT201A USE COMPUTER OPERATING SYSTEM. USING THE CONTROL PANEL The Control Panel contains many options for configuring your computer, including: adding.
Return to the Welcome to Windows 7 web page Lesson 1: Getting Your First Look.
Chapter 2 – Introduction to Windows Operating System II Manipulating Windows GUI 1CMPF112 Computing Skills for Engineers.
Windows customization
DISCOVERING COMPUTERS 2018 Digital Technology, Data, and Devices
Slide design: Dr. Mark L. Hornick
Intro to Windows 10.
Turning method call into an object
Sharing and Synching files
Intro to Windows 10.
An Introduction to Computers and Visual Basic
Single Sample Registration
Parts.cat.com Client training 2016.
Unit 2 User Interface Design.
Note 18: UX 3 Copyright © Robert W. Hasker,
An Introduction to Computers and Visual Basic
Understanding Operating System Configurations
IB Computer Science Topic 2.1.1
Introduction to Computers
Little work is accurate
Exploring the Basics of Windows XP
How To Disable The Banner Page On Xerox Work Centre Printer.
Programming Design Patterns
Model-View-Controller
12. Command Pattern SE2811 Software Component Design
Module 1: Getting Started with Windows 95
3. Object-oriented Design
Windows xp PART 1 DR.WAFAA SHRIEF.
Windows 7                      .
Exploring the Basics of Windows XP
Exploring the Power of EPDM Tasks - Working with and Developing Tasks in EPDM By: Marc Young XLM Solutions
Prof. Abdul Hameed Windows 10 Module 2 Prof. Abdul Hameed
PH Chapter 3 Thanks for the Memory Leaks Pushme-Pullyu (pp
Review: Applying Computer Basics
DOS and window operating system
An Introduction to Computers and Visual Basic
Bethesda Cybersecurity Club
Fundamentals of Using Microsoft Windows XP
8. Observer Pattern SE2811 Software Component Design
12. Command Pattern SE2811 Software Component Design
Microsoft Office Excel 2003
MVC overview Model, View, Controller is MVC
Software Engineering and Architecture
Windows Operating System
Presentation transcript:

Note 11 Command Pattern SE2811 Software Component Design Dr. Rob Hasker (based on slides by Dr. Mark Hornick) Note 11 Command Pattern

Excise Excise: actions not contributing to goal Financial excise: taxes, insurance Bicycle locks, repairing flats, oiling the chain Software excise: configuration, manuals Goal: eliminate excise so user more effective

Sources of excise GUI excise Training wheels Must move/resize window before can do work Command-line interface excise: learning commands GUI helps beginner, intermediate; cmd for expert Training wheels allow dismissing support for beginners Android power saver notification – why? Power saver notifier: displays message about turning off wireless/Bluetooth/etc at 30% - great idea, just do it; don’t need non-dismissible banner on my nofications page!

More excise Computer excise Visual excise Frequent & expensive updates for security features that affect few users. Visual excise Work user does to decode visual information Old software: special icons for beginners printer icons, fax machines help beginner, eat screen space for everyone else

Visual Clutter http://www.firemountaingems.com http://www.harborfreight.com

Visual Clutter Scrolling down several screens: http://www.firemountaingems.com http://www.harborfreight.com Scrolling down several screens:

Undo Another source of excise: “are you sure you want to do that?” Annoying at best Can be interpreted as saying: are you qualified to use this software? Solution: Undo Every action should be undoable Goal of undo: permit exploration Simple solution: save, restore state Each action: save state of system before the action Doesn’t scale: every video edit could require saving gigabytes of data… Even if have that much memory, undo/redo will be very slow!

Command Pattern Basic behind command pattern: store commands as objects base class defines abstract execute() subclasses: implement execute() Uses All menus, buttons, etc. can invoke same action Stack commands for undo/redo Share common bits of operations

Command pattern applied Applied to phonebook.java: Remove, add: core commands Two lists of commands; clear undone on new cmd

More phonebook details Implements GUI/policy/data layers History part of policy layer, encapsulates undo/redo Handler doesn’t need to track this! Phonebook: current contents; Map provides lookup Add: points to entry so can redo the add Remove: uses entry in undo

More phonebook details Issues to decide What data to store? Have a few “intelligent” commands, or lots of small ones? Provide way to group commands into a unit? Need way to save commands without exposing internal details?

More phonebook details Other ramifications: Macro = sequence of commands User might define own commands & assoc w/ menus Can log commands to handle system crashes, accountability, etc.

Another application How to support operations like startEngine, scrub? Should control panel team implement both? UI should be independent of actions

Using command pattern with this