Reuse and Reusability (Chapter 8 of maintenance text)

14
Reuse and Reusability Reuse and Reusability (Chapter 8 of maintenance (Chapter 8 of maintenance text) text) Steve Chenoweth Steve Chenoweth CSSE 375, Rose-Hulman CSSE 375, Rose-Hulman Based on Don Bagert’s 2006 Lecture Based on Don Bagert’s 2006 Lecture m http://www.lancashire.gov.uk/environment/waste/reduction/reuse.asp?print=yes .

description

Image from http://www.lancashire.gov.uk/environment/waste/reduction/reuse.asp?print=yes. Reuse and Reusability (Chapter 8 of maintenance text). Steve Chenoweth CSSE 375, Rose-Hulman Based on Don Bagert’s 2006 Lecture. Today. Your feedback on HW2 Armadillo Run & requirements discussion - PowerPoint PPT Presentation

Transcript of Reuse and Reusability (Chapter 8 of maintenance text)

Page 1: Reuse and Reusability (Chapter 8 of maintenance text)

Reuse and ReusabilityReuse and Reusability(Chapter 8 of maintenance text)(Chapter 8 of maintenance text)

Steve ChenowethSteve ChenowethCSSE 375, Rose-HulmanCSSE 375, Rose-Hulman

Based on Don Bagert’s 2006 LectureBased on Don Bagert’s 2006 Lecture

Image from http://www.lancashire.gov.uk/environment/waste/reduction/reuse.asp?print=yes.

Page 2: Reuse and Reusability (Chapter 8 of maintenance text)

22

TodayToday

Your feedback on HW2Your feedback on HW2 Armadillo Run & requirements Armadillo Run & requirements

discussiondiscussion Lab time – Help on project Lab time – Help on project

design & codingdesign & coding Reuse & reusability – Reuse & reusability – thisthis

Page 3: Reuse and Reusability (Chapter 8 of maintenance text)

33

Using “Reuse Maintenance Using “Reuse Maintenance Process Model” (from Chapter 5)Process Model” (from Chapter 5)

AdvantagesAdvantages Can use components, etc. from other Can use components, etc. from other

projectsprojects Code is modularCode is modular

DisadvantagesDisadvantages Overhead in designing for reuseOverhead in designing for reuse

Page 4: Reuse and Reusability (Chapter 8 of maintenance text)

44

A prime example of reuse A prime example of reuse strategy – Product linesstrategy – Product lines

Enhance & maintain a base Enhance & maintain a base platformplatform

Enhance & maintain multiple Enhance & maintain multiple products on top of that baseproducts on top of that base

Where’s the reuse Where’s the reuse advantage?advantage?

Image from www.hobbsamerica.com/ .

Page 5: Reuse and Reusability (Chapter 8 of maintenance text)

55

Product lines – and Product lines – and where’s the overhead?where’s the overhead?

Image from www.jot.fm/issues/issue_2004_03/column6/ .

A typical ongoing activity – extract commonalities for upcoming releases:

Page 6: Reuse and Reusability (Chapter 8 of maintenance text)

66

Targets for ReuseTargets for Reuse

Process Process Specific – like “how we adapted Specific – like “how we adapted

the last system to work with the last system to work with Oracle”Oracle”

PersonnelPersonnel No such thing as a “technical No such thing as a “technical

head count year”head count year” ProductProduct

More of a business strategy, More of a business strategy, maybe – adapt software to a maybe – adapt software to a new target marketnew target market

Page 7: Reuse and Reusability (Chapter 8 of maintenance text)

77

Targets for Reuse, cntdTargets for Reuse, cntd

DataData Especially reusing test dataEspecially reusing test data

DesignDesign Higher level = more usefulHigher level = more useful Why isn’t this done more?Why isn’t this done more? Why Why is is it done in compilers?it done in compilers?

ProgramProgram This is the one you’d expectThis is the one you’d expect

Page 8: Reuse and Reusability (Chapter 8 of maintenance text)

88

Maintenance MotivationsMaintenance Motivations

Reduction in time and effortReduction in time and effort Higher qualityHigher quality Improve maintainabilityImprove maintainability Code “transportation”Code “transportation”

PC to MacPC to Mac Stand-alone to server-basedStand-alone to server-based US to JapanUS to Japan

Image from jcmc.indiana.edu/vol9/issue1/nishimura.html .

Page 9: Reuse and Reusability (Chapter 8 of maintenance text)

99

Approaches to Reuse – Approaches to Reuse – CompositionComposition Essence of the “Reuse model” – Essence of the “Reuse model” –

Fig 5.18Fig 5.18 ComponentsComponents

Black boxBlack box White boxWhite box

ClassesClasses Keep spawning Keep spawning

children,children,intelligently!intelligently!

Image from www.ppsv.net/WeProvide.htm .

Page 10: Reuse and Reusability (Chapter 8 of maintenance text)

1010

Approaches to Reuse – Approaches to Reuse – GenerationGeneration

Parameterized systemsParameterized systems Application generatorsApplication generators

Page 11: Reuse and Reusability (Chapter 8 of maintenance text)

1111

Approaches to Reuse – Approaches to Reuse – TransformationTransformation

Input the requirements…Input the requirements… Output a new system!Output a new system!

Two kinds:Two kinds: Stepwise refinementStepwise refinement Linguistic transformationLinguistic transformation

Page 12: Reuse and Reusability (Chapter 8 of maintenance text)

1212

Intro to ComponentsIntro to Components

Two strategies:Two strategies: Horizontal – use in lots of domainsHorizontal – use in lots of domains Vertical – use to solve common Vertical – use to solve common

problems in a domainproblems in a domain Require domain analysesRequire domain analyses

““Essence of OO”Essence of OO”

Page 13: Reuse and Reusability (Chapter 8 of maintenance text)

1313

Intro to Components – cntd Intro to Components – cntd

Characteristics of reusable Characteristics of reusable components:components: GeneralityGenerality Cohesion vs couplingCohesion vs coupling Interaction – with user, utility fnsInteraction – with user, utility fns Uniformity and standardizationUniformity and standardization Data & control abstractionsData & control abstractions

More on these – Read Sec 8.7More on these – Read Sec 8.7

Page 14: Reuse and Reusability (Chapter 8 of maintenance text)

1414

A Reuse Process ModelA Reuse Process Model