Introduction to Refactoring

Size: px
Start display at page:

Download "Introduction to Refactoring"

Transcription

1 Introduction to Refactoring Anders Jonsson , Daniel Blomskog , Daniel Söderholm , May 18, 2003

2 Abstract This report is written as an introduction to refactoring for those that have no knowledge of the area. It covers the basics of refactoring, a brief look at the history of refactoring and the meaning of the word refactoring. There are some examples on how different refactory-function work, what their preconditions are and what they do. It also takes a look at the use of software design patterns by refactoring to patterns. Last, but not least, it covers refactoring-tools and names a few examples of different tools available.

3 Introduction Refactoring history Refactoring code has been done since people started programming. Cleaning up code is refactoring, making small changes to make a program faster or more memory efficient is refactoring. However it is not until recently people started to discuss different techniques for it. The discussion began when Martin Fowler published his book on Refactoring 1 in which he included the first basic refactoring patterns, and the field is getting larger as imperative programming is more and more replaced by OO. This is because of the high costs involving the process of creating new software from scratch and the factor that OO-programming produces code that is easier to use. People are starting to develop special tools for refactoring and try to make the refactoring-process as automated as possible, but that is a process that is going to take time to tune to perfection. There is a section on different tools and a little explanation on the theory behind them later on. Like always when it comes to programming people think different about how things should be done. The two major directions in this matter are If it is working do not change it and Refactor everything you come across aka refactor mercilessly. Most programmers land somewhere in between these two, refactoring at the same time they are fixing small bugs. The expression refactor The expression refactoring comes from mathematics: when you factor an expression, thus getting a cleaner way of expressing a statement, but you still get the same result when using it. example: (x 1) (x + 1) = x 2 1 The leftmost expression has four terms and the rightmost has two. The leftmost has three operators while the rightmost has two. Even though the leftmost expression has more terms and operators it is easier to understand because it uses simpler operations. One also gets more information from the leftmost expression out of just looking at it, like that the roots are +1/ 1, things which are harder to see by just looking at the right one (maybe not in this case but if you have larger expressions). 1 Refactoring: Improving the Design of Existing Code

4 Refactoring code Refactoring is the process in which one takes a program and change its internal structure without changing its external behavior. The goal of the refactoring process is to make the programs internal structure better i.e. smarter design and more readable and reusable code. Refactoring has been done since people started programming, all programmers do it. example: a programmer changes the name of a function, maybe replaces some duplicate code with calls to a function, changing an interface to make it more reusable. It is typically done in small steps like the examples above and when you are done with one of those small steps you should still have a system that works and is unchanged functionality wise. Bug fixes and adding new functions should not be done during the refactoring process, instead the main goal is to keep it simple. For example, it is better to do a small change and make sure it works than do many changes and then spending hours finding out what went wrong and where. It has also been said that small changes leads to errors more times than larger changes. This is because most programmers take those small changes less seriously. This leads to less testing and less testing leads to more errors in the future. Conclusion: Do small changes and make sure that they are correct before changing anything else. Object-Oriented programming and refactoring For most people Object-Oriented programming stands for easy reusability and code that is easy to understand. Let us look at some advantages of programming in an OO-language. In most OO-languages one can use data abstraction using classes, which support encapsulation and information hiding. These are all properties that fit well for a reusable component. Then there is class inheritance which means that operations of classes can be inherited and reused by its subclasses. Another great thing about OO-programming is polymorphism. With polymorphism, methods can operate over many different types of data so that the same code can be used in many situations. On the other hand, some of the benefits of OO-languages make the refactoring process more complex due to the interrelationship between classes. As a program keep getting larger and larger the refactorings get more and more complicated and time consuming to do manually. This is why more and more tools for automating the refactoring-process are being developed. More on this in the Tools chapter. Motivations for refactoring A piece of software can be seen as a big town, it is not easy to design a perfect city on your own it takes the work of many citizens refactoring to the better all the time. One factor that highly motivates reusing already existing software is the major costs of program development. You see more and more companies buying an

5 existing system. But these systems are not always perfect for the job. There is almost always software that almost solves your own problems but they need to be restructured to fit your exact needs. You can also refactor existing designs in the cases where there is no finished software that solves your problem. Refactoring makes it easier to understand a program or design and to find reusable components. While refactoring does not change the behavior of a program, it can, and usually does, change the design, and a good design is essential for easy adaptation of software. Good design also makes it easier to add or change functionality in the future.

6 Basic refactoring Factory functions Description of a refactory function A refactory function is a transformation with some preconditions on the object that is going to be changed. The precondition is to insure that the refactory property is fullfilled so the behavior of the program is not changed. Following is a collection of examples of refactory functions, divided into seperate types of refactoring. These types are: on class, on method and on instance variable. Something to remember is that a refactoring does not change the behavior but could change the performance of the program. example: Let us take a look at adding/removing variables. Both these operations changes the amount of memory used by the program, but none of them is going to change the behavior of the program. Refactory on class This function set changes the class structure of the program and it can even change the class hierarchy. Add a class To do this a set of subclasses and a superclass is used as input. If the set of subclasses are not empty then every subclass in the set need to have a common superclass and the superclass that was given as an input need to be that class. This method inserts a empty class between the superclass and the subclasses. An easy way to change the class hierachy. See Figure 1 & 2 Figure 1: Before add/after remove

7 Figure 2: After add/before remove Rename a class This function takes a class and a new name as input and changes the name of the class. The only criteria is that it should not be any nameconflict in any way. Remove a class For indata the function takes a class and removes it. The precondition of the class is that it should be unreferenced. If the class has any subclasses all their methods and variables must be able to be removed with the refactory functions remove a method and remove an instance variable. This means that the class must be empty or be able to be emptied without changing the behavior of the program. The class hierarchy changes likes in the function add a class but in the other way around. (See figure 1 & 2) Refactory on methods This function set change a class or a set of class-methods. Add a method This function takes a class and a method name. It adds a method with that name to the class. The criteria for this operation is: If a superclass has a method with the same name it must have the same semantical meaning as the method being added. Otherwise polymorphism could change the behavior of the program. A way to move methods from a superclass to its subclasses is adding a method with the same name and same semantical meaning in every subclass then remove the method from the superclass. Rename a method This function needs a set of classes, a set of methods and the new name. The need of a set and not only one class/method is because of polymorphism. If one changes a name of a method one needs to change all polymorphs of the method. example: Let us say that you have a method named insert. You change the name of the method, overlookning the method with the same name in the superclass. This

8 will remove overloading of the insert-method in the superclass. The same is true if the method in the superclass is changed without changing the overloading method in the subclass. Both these cases change the behavior of the program, therefore all methods must be changed. Changing a name of a method in a class forces a namechange of the method in every class in the class hierarchy that has this method. Remove a method This function needs a class and the method that should be removed. The criteria in this case is that it must be unreferenced and if any superclass has a method with the same name they need to be semantically the same. Refactory on variables Changes the structure of how data is stored. Add an instance variable This function needs a class and a name. variable to the class. It adds an unreferenced instance Remove an instance variable This function needs a class and an instance variable that will to be removed from the class. The variable must be unreferenced. Rename an instance variable This function needs a class and an instance variable. The function renames and updates every use of the variable. The only precondition is that there is no name conflicts. Pullup instance variable A set of subclasses that contains the variable and their common superclass. Removes the variable from the subclasses and adds it to the superclass. The other subclasses behavior does not change because an unreferenced instance variable does not change the behavior of the class. Pushdown instance variable This function takes a superclass and an instance variable. The function removes it from the superclass and adds it to the subclasses. To hold the refactory property the variable needs to be unreferenced in the superclass. Abstract instance variable Needs a class and an instance variable. Replaces all direct use of the variable with call to get and set methods.

9 Move a instance variable Needs two classes and an instance variable. Moves the variable from one class to the other and updates the references to the variable. It must be a one to one relationship between the classes. So that there always will be a variable and so that no more than one object makes use of the variable. Refactoring to patterns Flexible code vs. Productivity Patterns are a cornerstone of object-oriented design and can be used to solve many (if not all) of the problems one may encounter while making the design for a project. However, if patterns are over-used, your code becomes more flexible than it has to be. It may be a good idea to accommodate to the needs of tomorrow, but on the other hand one can never be sure of what those needs are. This kind of over-engineering takes time and, in a commercial production, time is money. Usually, that kind of over-engineered code never gets changed (because you might still have use for it, right?), and that means that you (and your fellow programmers, especially new members of the team) will have a larger and more complicated code base to operate within. Making use of design pattern takes you far on the road to become a good programmer in the object-oriented field, but you must also know when it s simply a waste of time to do so. Keeping a steady pace While being careful not to over-engineer, one must also make sure that one does not under-engineer the project. Under-engineering is far more common than over-engineering and it s more dangerous to the project. Under-engineering usually happens when we focus on adding more and more to a system without improving it s design along the way. When the code is working you simply move along to the next part without improving the part you just wrote. This usually leads to the fast, slow, slower rhythm of development, which goes like this 1. The first release goes fast (but with some junky code in the trunk). 2. The second release takes time since you have to deal with some of the junky code, and in doing so you write even more junky code. 3. Future releases goes even slower since there is more junky code to deal with. People will probably start to lose interest in the product by now. Under-engineering can be eliminated by applying Merciless Refactoring. Merciless Refactoring is a practice of extreme programming and simply means that you should refactor as soon as you find something you CAN refactor. When you find two methods that look the same, you refactor the code to combine them. When you find two objects with common functionality, you refactor to make there be just one [ This

10 will result in a design that is upgraded continuously. The trick to merciless refactoring is to not schedule time to make small design improvements, but to make them whenever your code needs them. [Joshua Kerievsky] Motivations for RtP The motivations for refactoring to patterns are basically the same as for any other refactoring. To reduce duplication, to simplify code, to add greater flexibility and to make the code more understandable. Even though non-pattern-based refactorings can, and should, be used in most cases, you might run across places where patterns can help improve your design greatly. In those cases you should refactor to patterns, while being careful not to make overly flexible or sophisticated solutions. Knowing WHY and WHEN to use Refactoring to Patterns is more important than knowing HOW to do it. Refactoring-tools Even though refactoring can easily be used manually, in larger projects it can easily become a chore. Fortunately, there are several tools that can be used to make the process faster. A good refactoring tool should include many refactorings while being careful not to make too many changes. It should also inform the user of the motivation and consequences of the refactorings used. None of these tools include Refactoring to Patterns since that is a very difficult thing to do and the field is still relatively unknown. According to the team at the refactoring process with the help of refactoring-tools can be described like this: Refactoring is only practical with tools that automate the labor-intensive activities of streamlining and reorganizing code bases. During the research, probing and understanding phase, the work is in identifying and grasping the code architecture. This early stage involves heavy use of special query and search tools that quickly expose the functional hierarchy of methods and program elements. In the next phase of moving and reorganizing code fragments, the developer uses their code editor or IDE in conjunction with automatic transformation tools. Variables, file names, and other references must be globally converted or changed to maintain code integrity. Dependency checking tools help insure code integrity and readiness for build. The testing phase is a natural extension of refactoring, and during the frequent refactoring-testing cycles tight interaction between the editor/ide and the refactoring tools are required for maximum productivity. Finally, checking code metrics is done with special tools to detect unused methods, overcomplex constructs, and hot spots in modules. Java is by far the most represented language in the world of refactoring-tools. This is because Java is more restricted than for example C or C++ which makes it easier to do major refactorings without causing errors.

11 Crossing Refactorings rubicon Martin Fowler has written an article about the tasks that a Refactoring-tool should be able to complete to be a real asset in the process of refactoring. The article is something that should be read and considered by anyone that has plans on making a refactoring-tool. Tools, tools, tools... Following are some examples of common refactoring-tools for a few programming languages. Most of these tools are free, but some are commercial projects. The quotes are from their respective web-pages Smalltalk Refactoring Browser The Smalltalk Refactoring Browser was the first refactoring-tool to see the light of day, and it s still widely used in the Smalltalk community. Besides IBM Smalltalk it supports VisualWorks and VisualWorks/ENVY. It s refactoring support is described to Automatically perform some behavior preserving transformations such as abstracting references to an instance variable. Many of the refactorings are from Bill Opdyke s thesis.. It also includes functions as Lint, a function that automatically looks for over 60 types of common smalltalk bugs in your program. Java XRefactory XRefactory is a tool for C and Java that provides code completion, source browsing and refactoring. It is available for both Unix and Windows and provides full integration with Emacs, XEmacs and Jedit. It claims to be the world s first tool Crossing Refactoring s Rubicon. RefactorIT RefactorIT is a plugin for Forte, JDeveloper, JBuilder and NetBeans. It can also be used as a stand-alone tool. It boasts as being the first product to fully cover every part of the refactoring cycle. jfactor jfactor was the second tool Crossing Refactoring s Rubicon and according to it s website it is a product family that provides powerful new code refactoring

12 tools to professional Java integrated development environments (IDE). It provides many refactorings and claims to improve code design quickly and safely as well as to increase developer productivity. IntelliJ IDEA A full-featured Java IDE with refactoring support. It claims to be the most intelligent Java IDE around.. It includes many refactorings and more seems to be added for every release. CodeGuide CodeGuide offers advanced refactoring capabilities. It can rename methods, fields, variables, labels, classes or packages and automatically update all references throughout the project. It can move classes and packages and update all references. CodeGuide will check for potential problems prior to refactoring to make the refactorings safe. There are a couple of intelligent coding tools that will help you perform common tasks such as Javadoc stub insertion, setter & getter creation and import organization. C/C++ CppRefactory CppRefactory is a project in the makings. The finished tool will, according to the webpage, be an application that allows developers to refactor their C++ code. Its goal is to make the refactoring of C++ code as efficient and painless as possible. Alejandra Garrido garrido/ Alejandra is currently working on a refactoring-tool for C, with focus on preprocessor directives. XRefactory As mentioned above, XRefactory supports both Java and C. C# C# Refactoring Tool Fully integrated add-in for Microsoft Visual Studio.NET. It supports many refactorings as well as undo/redo.

13 C# Refactory According to the website it is a revolutionary new tool which enhances Microsoft s Visual Studio.NET IDE. It includes many refactorings and adds a refactoring item to the edit menu in Visual Studio. doteasy doteasy is a Visual Studio.Net Add-in that evaluates C# source code and performs advices in order to improve software quality. It is not exactly a refactoring-tool yet, but it still deserves to be mentioned as it seems to be a promising tool. Visual Basic Project Analyzer Project Analyzer is a complete code review and quality control tool for Visual Basic. It s not exactly a refactoring-tool, but it includes lots of related functionality. Python Bicycle Repair Man The Bicycle Repair Man project is an attempt to create a refactoring browser for python, using Extreme Programming techniques to deliver high quality functionality in as short a time frame as possible. At least it has the best name around. Perl PREFACE: The Perl REFACtoring Engine The Perl REFACtoring Engine is a project in the works. There has not yet been any releases and it s status is unknown. The project has most likely been abandoned, but you might still want to check it out once in a while. Haskell Apparently, there are plans for Haskell refactoring-tools, but none seems to be in the makings at this moment.

14 Related areas and work As you can see refactoring is highly related to many other areas of programming. For example Extreme Programming solely depends on refactoring since you develop a working product as fast as possible and then refactor the code to make it better design wise and more reusable. Refactoring does not depend on XP tough. Restructure and reworking are also related areas. If you want to learn more about refactoring you might want to read the works of Martin Fowler, William F. Opdyke and Donald Roberts, and if refactoring to pattern seems interesting you should check out the work of Joshua Kerievsky.

15 Conclusion Refactoring is a technique that most programmers use without even knowing it. However, much can be gained by learning more about the field in general, as well as good ways to go about it. By use of refactoring you can quickly become a better programmer as you gain more knowledge about good designs and solutions. You will also learn how to reuse already existing design and components better, whether they are of your own devising or not. By using some of the refactoring-functions mentioned in this report, bad code could be improved by changing name of variable, methods and class. You can also use refactoring for upgrades by adding classes, methods and variables. You can also increase the performace through factory-methods. The chapter Refactoring to patterns gives some well needed words of caution on the use of design patterns as well as advices on how and when to use patterns in your projects. The use of refactoring-tools can simplify the refactoring-process as well as make it more secure. On the other hand you, as a programmer, should make sure that you understand what the tool is doing, and why. The tools are a great help, but you should never solely depend on them.

16 Discussion When a project grows it is important to have a code that is easy to read. Changing of standards or updating existing standard could demand a hard work. Through refactoring tools could this type of work done easily instead of going through 1000 s of lines of code replaceing names. By refactoring you can change the way the code works even in runtime without changing behavior. This could be used to make optimizations for diffrent runtime-situations depending on memory-size, CPU-speed etc. We, the authors of this report, believe that refactoring as a field will grow to become a cornerstone of the programming world. In fact, it already is a cornerstone, since nearly every programmer use some sort of refactoring whether they know it or not. However the field will become more discussed and refined.

17 References & sources Martin Fowler s website on refactoring [ Refactoring to Patterns [Joshua Kerievsky, Refactoring on the Wiki [ Practical Analysis for Refactoring [Donald Roberts, droberts/thesis.pdf] Refactoring object-oriented frameworks [William Opdyke, ftp://st.cs.uiuc.edu/pub/papers/refactoring/opdyke-thesis.ps.z] And, of course, the websites mentioned in the Refactoring-tools section. 16

Understading Refactorings

Understading Refactorings Understading Refactorings Ricardo Terra terra@dcc.ufmg.br Marco Túlio Valente mtov@dcc.ufmg.br UFMG, 2010 UFMG, 2010 Understanding Refactorings 1 / 36 Agenda 1 Overview 2 Refactoring 3 Final Considerations

More information

Software Design COSC 4353/6353 D R. R A J S I N G H

Software Design COSC 4353/6353 D R. R A J S I N G H Software Design COSC 4353/6353 D R. R A J S I N G H Week 5 Refactoring What is Refactoring? Code Smells Why Refactoring? Techniques IDEs What is Refactoring? Art of improving the design of existing code

More information

Refactoring. Paul Jackson. School of Informatics University of Edinburgh

Refactoring. Paul Jackson. School of Informatics University of Edinburgh Refactoring Paul Jackson School of Informatics University of Edinburgh Refactoring definition Refactoring (noun) is a change made to the internal structure of software to make it easier to understand,

More information

Analysis of the Test Driven Development by Example

Analysis of the Test Driven Development by Example Computer Science and Applications 1 (2013) 5-13 Aleksandar Bulajic and Radoslav Stojic The Faculty of Information Technology, Metropolitan University, Belgrade, 11000, Serbia Received: June 18, 2013 /

More information

Living and Working with Aging Software. Ralph Johnson. University of Illinois at Urbana-Champaign

Living and Working with Aging Software. Ralph Johnson. University of Illinois at Urbana-Champaign Living and Working with Aging Software Ralph Johnson University of Illinois at Urbana-Champaign rjohnson@illinois.edu Old software gets brittle n n Hard to change Hard to understand Software should be

More information

McCa!"s Triangle of Quality

McCa!s Triangle of Quality McCa!"s Triangle of Quality Maintainability Portability Flexibility Reusability Testability Interoperability PRODUCT REVISION PRODUCT TRANSITION PRODUCT OPERATION Correctness Usability Reliability Efficiency

More information

Credit where Credit is Due. Lecture 25: Refactoring. Goals for this lecture. Last Lecture

Credit where Credit is Due. Lecture 25: Refactoring. Goals for this lecture. Last Lecture Credit where Credit is Due Lecture 25: Refactoring Kenneth M. Anderson Object-Oriented Analysis and Design CSCI 6448 - Spring Semester, 2002 Some of the material for this lecture and lecture 26 is taken

More information

Evolving Software. CMSC 433 Programming Language Technologies and Paradigms Spring Example. Some Motivations for This Refactoring

Evolving Software. CMSC 433 Programming Language Technologies and Paradigms Spring Example. Some Motivations for This Refactoring CMSC 433 Programming Language Technologies and Paradigms Spring 2007 Refactoring April 24, 2007 Lots of material taken from Fowler, Refactoring: Improving the Design of Existing Code 1 Evolving Software

More information

Administrivia. Programming Language Fall Example. Evolving Software. Project 3 coming out Midterm October 28. Refactoring October 14, 2004

Administrivia. Programming Language Fall Example. Evolving Software. Project 3 coming out Midterm October 28. Refactoring October 14, 2004 CMSC 433 Programming Language Fall 2004 Project 3 coming out Midterm October 28 Administrivia Refactoring October 14, 2004 Lots of material taken from Fowler, Refactoring: Improving the Design of Existing

More information

DAT159 Refactoring (Introduction)

DAT159 Refactoring (Introduction) DAT159 Refactoring (Introduction) Volker Stolz 1, with contributions by: Larissa Braz 2, Anna M. Eilertsen 3, Fernando Macías 1, Rohit Gheyi 2 Western Norway University of Applied Sciences, Universidade

More information

Refactorings. Refactoring. Refactoring Strategy. Demonstration: Refactoring and Reverse Engineering. Conclusion

Refactorings. Refactoring. Refactoring Strategy. Demonstration: Refactoring and Reverse Engineering. Conclusion Refactorings Refactoring What is it? Why is it necessary? Examples Tool support Refactoring Strategy Code Smells Examples of Cure Demonstration: Refactoring and Reverse Engineering Refactor to Understand

More information

Refactoring with Eclipse

Refactoring with Eclipse Refactoring with Eclipse Seng 371 Lab 8 By Bassam Sayed Based on IBM article Explore refactoring functions in Eclipse JDT by Prashant Deva Code Refactoring Code refactoring is a disciplined way to restructure

More information

The Legacy Bridge Problem. Douglas Lyon and Chris Huntley

The Legacy Bridge Problem. Douglas Lyon and Chris Huntley The Legacy Bridge Problem by Douglas Lyon and Chris Huntley Abstract We present a way to automate the reuse of legacy systems without multiple-inheritance, copying source code, accessing existing code

More information

COURSE 11 DESIGN PATTERNS

COURSE 11 DESIGN PATTERNS COURSE 11 DESIGN PATTERNS PREVIOUS COURSE J2EE Design Patterns CURRENT COURSE Refactoring Way refactoring Some refactoring examples SOFTWARE EVOLUTION Problem: You need to modify existing code extend/adapt/correct/

More information

As a programmer, you know how easy it can be to get lost in the details

As a programmer, you know how easy it can be to get lost in the details Chapter 1 Congratulations, Your Problem Has Already Been Solved In This Chapter Introducing design patterns Knowing how design patterns can help Extending object-oriented programming Taking a look at some

More information

Refactoring. Software Engineering, DVGC18 Faculty of Economic Sciences, Communication and IT Eivind Nordby

Refactoring. Software Engineering, DVGC18 Faculty of Economic Sciences, Communication and IT Eivind Nordby Refactoring Faculty of Economic Sciences, Communication and IT 2011-09-21 Why Refactor Refactoring is one factor in keeping your system in shape Without continuous refactoring, the system will rot It takes

More information

Small changes to code to improve it

Small changes to code to improve it Small changes to code to improve it 1 Refactoring Defined A change made to the internal structure of software to make it easier to understand and cheaper to modify without changing its observable behavior

More information

Reengineering II. Transforming the System

Reengineering II. Transforming the System Reengineering II Transforming the System Recap: Reverse Engineering We have a detailed impression of the current state We identified the important parts We identified reengineering opportunities We have

More information

Objectives: On completion of this project the student should be able to:

Objectives: On completion of this project the student should be able to: ENGI-0655/5232 Software Construction and Evolution Project 1 Reverse Engineering Refactoring & Object Oriented Design Due date November 10, 2009-4:00 pm 1. Aims The aim of this project is to give you more

More information

Course December Adrian Iftene

Course December Adrian Iftene Course 10 12 December 2016 Adrian Iftene adiftene@info.uaic.ro Recapitulation QoS Functional Testing Non-Functional Testing Rotting Design Refactoring 2 QoS = ability to provide different priority to different

More information

CSE 403 Lecture 21. Refactoring and Code Maintenance. Reading: Code Complete, Ch. 24, by S. McConnell Refactoring, by Fowler/Beck/Brant/Opdyke

CSE 403 Lecture 21. Refactoring and Code Maintenance. Reading: Code Complete, Ch. 24, by S. McConnell Refactoring, by Fowler/Beck/Brant/Opdyke CSE 403 Lecture 21 Refactoring and Code Maintenance Reading: Code Complete, Ch. 24, by S. McConnell Refactoring, by Fowler/Beck/Brant/Opdyke slides created by Marty Stepp http://www.cs.washington.edu/403/

More information

XP: Backup Your Important Files for Safety

XP: Backup Your Important Files for Safety XP: Backup Your Important Files for Safety X 380 / 1 Protect Your Personal Files Against Accidental Loss with XP s Backup Wizard Your computer contains a great many important files, but when it comes to

More information

This chapter is intended to take you through the basic steps of using the Visual Basic

This chapter is intended to take you through the basic steps of using the Visual Basic CHAPTER 1 The Basics This chapter is intended to take you through the basic steps of using the Visual Basic Editor window and writing a simple piece of VBA code. It will show you how to use the Visual

More information

Refactoring Practice: How it is and How it Should be Supported

Refactoring Practice: How it is and How it Should be Supported Refactoring Practice: How it is and How it Should be Supported Zhenchang Xing and EleniStroulia Presented by: Sultan Almaghthawi 1 Outline Main Idea Related Works/Literature Alignment Overview of the Case

More information

Computer Science 2 Lecture 4 Inheritance: Trinidad Fruit Stand 02/15/2014 Revision : 1.7

Computer Science 2 Lecture 4 Inheritance: Trinidad Fruit Stand 02/15/2014 Revision : 1.7 Computer Science 2 Lecture 4 Inheritance: Trinidad Fruit Stand 02/15/2014 Revision : 1.7 1 Problem Ralph owns the Trinidad Fruit Stand that sells its fruit on the street, and he wants to use a computer

More information

Expanding Our Horizons. CSCI 4448/5448: Object-Oriented Analysis & Design Lecture 9 09/25/2011

Expanding Our Horizons. CSCI 4448/5448: Object-Oriented Analysis & Design Lecture 9 09/25/2011 Expanding Our Horizons CSCI 4448/5448: Object-Oriented Analysis & Design Lecture 9 09/25/2011 1 Goals of the Lecture Cover the material in Chapter 8 of our textbook New perspective on objects and encapsulation

More information

Software Development. Modular Design and Algorithm Analysis

Software Development. Modular Design and Algorithm Analysis Software Development Modular Design and Algorithm Analysis Data Encapsulation Encapsulation is the packing of data and functions into a single component. The features of encapsulation are supported using

More information

Chapter 5 Object-Oriented Programming

Chapter 5 Object-Oriented Programming Chapter 5 Object-Oriented Programming Develop code that implements tight encapsulation, loose coupling, and high cohesion Develop code that demonstrates the use of polymorphism Develop code that declares

More information

Q&A Session for Connect with Remedy - CMDB Best Practices Coffee Break

Q&A Session for Connect with Remedy - CMDB Best Practices Coffee Break Q&A Session for Connect with Remedy - CMDB Best Practices Coffee Break Date: Thursday, March 05, 2015 Q: When going to Asset Management Console and making an update on there, does that go to a sandbox

More information

5. Application Layer. Introduction

5. Application Layer. Introduction Book Preview This is a sample chapter of Professional PHP - Building maintainable and secure applications. The book starts with a few theory chapters and after that it is structured as a tutorial. The

More information

Safety SPL/2010 SPL/20 1

Safety SPL/2010 SPL/20 1 Safety 1 system designing for concurrent execution environments system: collection of objects and their interactions system properties: Safety - nothing bad ever happens Liveness - anything ever happens

More information

Case study on PhoneGap / Apache Cordova

Case study on PhoneGap / Apache Cordova Chapter 1 Case study on PhoneGap / Apache Cordova 1.1 Introduction to PhoneGap / Apache Cordova PhoneGap is a free and open source framework that allows you to create mobile applications in a cross platform

More information

Implementing evolution: Refactoring

Implementing evolution: Refactoring 2IS55 Software Evolution Sources Implementing evolution: Refactoring Alexander Serebrenik / SET / W&I 17-5-2010 PAGE 1 Last week Problem: changing code is difficult Assignment 6 Deadline: Today Assignment

More information

Best practices for OO 10 content structuring

Best practices for OO 10 content structuring Best practices for OO 10 content structuring With HP Operations Orchestration 10 two new concepts were introduced: Projects and Content Packs. Both contain flows, operations, and configuration items. Organizations

More information

Overcoming the Challenges of Reusing Software

Overcoming the Challenges of Reusing Software Overcoming the Challenges of Reusing Software The amount of software produced per year is increasing exponentially. To enable producing more and more software, the most economical way is to reuse as much

More information

Patterns in Software Engineering

Patterns in Software Engineering Patterns in Software Engineering Lecturer: Raman Ramsin Lecture 10 Refactoring Patterns Part 1 1 Refactoring: Definition Refactoring: A change made to the internal structure of software to make it easier

More information

Practical Object-Oriented Design in Ruby

Practical Object-Oriented Design in Ruby Practical Object-Oriented Design in Ruby Anyone that has done a decent amount of programming in Ruby is bound hear about the book Practical Object-Oriented Design in Ruby [1] (http://www.poodr.com/) by

More information

Three OPTIMIZING. Your System for Photoshop. Tuning for Performance

Three OPTIMIZING. Your System for Photoshop. Tuning for Performance Three OPTIMIZING Your System for Photoshop Tuning for Performance 72 Power, Speed & Automation with Adobe Photoshop This chapter goes beyond speeding up how you can work faster in Photoshop to how to make

More information

CS 370 The Pseudocode Programming Process D R. M I C H A E L J. R E A L E F A L L

CS 370 The Pseudocode Programming Process D R. M I C H A E L J. R E A L E F A L L CS 370 The Pseudocode Programming Process D R. M I C H A E L J. R E A L E F A L L 2 0 1 5 Introduction At this point, you are ready to beginning programming at a lower level How do you actually write your

More information

Be careful when deciding whether to represent data as integers or floats, and be sure that you consider all possible behaviors in computation.

Be careful when deciding whether to represent data as integers or floats, and be sure that you consider all possible behaviors in computation. Table of Contents: 1. Integers and floats 2. for vs. while loops 3. Checking boolean conditions with if/else 4. Docstrings 5. Changing collections while iterating over them 6. Directly Accessing Instance

More information

An Overview of Visual Basic.NET: A History and a Demonstration

An Overview of Visual Basic.NET: A History and a Demonstration OVERVIEW o b j e c t i v e s This overview contains basic definitions and background information, including: A brief history of programming languages An introduction to the terminology used in object-oriented

More information

Session 4b: Review of Program Quality

Session 4b: Review of Program Quality Session 4b: Review of Program Quality What makes one program "better" than another? COMP 170 -- Fall, 2013 Mr. Weisert What is a good program? Suppose we give the same assignment to two programmers (or

More information

Multi-Project Workspace

Multi-Project Workspace Multi-Project Workspace Manage multiple projects within BlueJ Version 2008.06.25 by Manuel Haim C o n t e n t s Preface... 3 Software requirements... 4 Software used for developing / testing... 4 License...

More information

Chapter01.fm Page 1 Monday, August 23, :52 PM. Part I of Change. The Mechanics. of Change

Chapter01.fm Page 1 Monday, August 23, :52 PM. Part I of Change. The Mechanics. of Change Chapter01.fm Page 1 Monday, August 23, 2004 1:52 PM Part I The Mechanics of Change The Mechanics of Change Chapter01.fm Page 2 Monday, August 23, 2004 1:52 PM Chapter01.fm Page 3 Monday, August 23, 2004

More information

CSC 408F/CSC2105F Lecture Notes

CSC 408F/CSC2105F Lecture Notes CSC 408F/CSC2105F Lecture Notes These lecture notes are provided for the personal use of students taking CSC 408H/CSC 2105H in the Fall term 2004/2005 at the University of Toronto. Copying for purposes

More information

AntiPatterns. EEC 421/521: Software Engineering. AntiPatterns: Structure. AntiPatterns: Motivation

AntiPatterns. EEC 421/521: Software Engineering. AntiPatterns: Structure. AntiPatterns: Motivation AntiPatterns EEC 421/521: Software Engineering Definition: An AntiPattern describes a commonly occurring solution to a problem that generates decidedly negative consequences Refactoring Reference: Refactoring

More information

A study of the impact of C++ on software maintenance

A study of the impact of C++ on software maintenance A study of the impact of C++ on software maintenance Dennis Mancl AT&T Bell Laboratories Warren, NJ 07059 William Havanas AT&T Bell Laboratories Columbus, OH 43213 Abstract This is a case study of the

More information

Object Oriented Programming in Java. Jaanus Pöial, PhD Tallinn, Estonia

Object Oriented Programming in Java. Jaanus Pöial, PhD Tallinn, Estonia Object Oriented Programming in Java Jaanus Pöial, PhD Tallinn, Estonia Motivation for Object Oriented Programming Decrease complexity (use layers of abstraction, interfaces, modularity,...) Reuse existing

More information

Software Design and Analysis CSCI 2040

Software Design and Analysis CSCI 2040 Software Design and Analysis CSCI 2040 Introduce two important development practices in the context of the case studies: Test-Driven Development Refactoring 2 Logic is the art of going wrong with confidence

More information

Introduction to Testing and Maintainable code

Introduction to Testing and Maintainable code Introduction to Testing and Maintainable code Reasons not to write unit tests 1. I don't know how to write tests. 2. Writing tests is too hard. 3. I don't have enough time to write tests. 4. Testing is

More information

Principles of Programming Languages. Objective-C. Joris Kluivers

Principles of Programming Languages. Objective-C. Joris Kluivers Principles of Programming Languages Objective-C Joris Kluivers joris.kluivers@gmail.com History... 3 NeXT... 3 Language Syntax... 4 Defining a new class... 4 Object identifiers... 5 Sending messages...

More information

POC Evaluation Guide May 09, 2017

POC Evaluation Guide May 09, 2017 POC Evaluation Guide May 09, 2017 This page intentionally left blank P r o p r i e t a r y a n d C o n f i d e n t i a l. 2 0 1 7 R F P M o n k e y. c o m L L C Page 2 CONTENTS Read Me First... 4 About

More information

Hello World! Computer Programming for Kids and Other Beginners. Chapter 1. by Warren Sande and Carter Sande. Copyright 2009 Manning Publications

Hello World! Computer Programming for Kids and Other Beginners. Chapter 1. by Warren Sande and Carter Sande. Copyright 2009 Manning Publications Hello World! Computer Programming for Kids and Other Beginners by Warren Sande and Carter Sande Chapter 1 Copyright 2009 Manning Publications brief contents Preface xiii Acknowledgments xix About this

More information

Object-Oriented Programming and Design

Object-Oriented Programming and Design C Sc 335 Course Overview Object-Oriented Programming and Design Rick Mercer Major Topics in C Sc 335 1. Java 2. Object-Oriented Programming 3. Object-Oriented Design 4. Technology 5. Object-Oriented Principles

More information

CS 575: Software Design

CS 575: Software Design CS 575: Software Design Introduction 1 Software Design A software design is a precise description of a system, using a variety of different perspectives Structural Behavioral Packaging Requirements, Test/Validation

More information

Setting the stage... Key Design Issues. Main purpose - Manage software system complexity by improving software quality factors

Setting the stage... Key Design Issues. Main purpose - Manage software system complexity by improving software quality factors Setting the stage... Dr. Radu Marinescu 1 1946 Key Design Issues Main purpose - Manage software system complexity by...... improving software quality factors... facilitating systematic reuse Dr. Radu Marinescu

More information

REVIEW OF THE BASIC CHARACTERISTICS OF OBJECT ORIENTATION

REVIEW OF THE BASIC CHARACTERISTICS OF OBJECT ORIENTATION c08classandmethoddesign.indd Page 282 13/12/14 2:57 PM user 282 Chapter 8 Class and Method Design acceptance of UML as a standard object notation, standardized approaches based on work of many object methodologists

More information

Appendix A - Glossary(of OO software term s)

Appendix A - Glossary(of OO software term s) Appendix A - Glossary(of OO software term s) Abstract Class A class that does not supply an implementation for its entire interface, and so consequently, cannot be instantiated. ActiveX Microsoft s component

More information

QUIZ #5 - Solutions (5pts each)

QUIZ #5 - Solutions (5pts each) CS 435 Spring 2014 SOFTWARE ENGINEERING Department of Computer Science Name QUIZ #5 - Solutions (5pts each) 1. The best reason for using Independent software test teams is that a. software developers do

More information

Chapter 12. OOP: Creating Object-Oriented Programs The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill

Chapter 12. OOP: Creating Object-Oriented Programs The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill Chapter 12 OOP: Creating Object-Oriented Programs McGraw-Hill 2010 The McGraw-Hill Companies, Inc. All rights reserved. Chapter Objectives - 1 Use object-oriented terminology correctly Create a two-tier

More information

The BITS & BYTES. Solving PC Problems with iolo technologies System Mechanic 9.5. By Dave Dunsmoor

The BITS & BYTES. Solving PC Problems with iolo technologies System Mechanic 9.5. By Dave Dunsmoor The Broadcasters Desktop Resource www.thebdr.net edited by Barry Mishkind the Eclectic Engineer BITS & BYTES Solving PC Problems with iolo technologies System Mechanic 9.5 By Dave Dunsmoor [May 2010] When

More information

Problem Solving through Programming In C Prof. Anupam Basu Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur

Problem Solving through Programming In C Prof. Anupam Basu Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur Problem Solving through Programming In C Prof. Anupam Basu Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur Lecture - 04 Introduction to Programming Language Concepts

More information

MSO Refactoring. Hans Philippi. October 2, Refactoring 1 / 49

MSO Refactoring. Hans Philippi. October 2, Refactoring 1 / 49 MSO Refactoring Hans Philippi October 2, 2018 Refactoring 1 / 49 This lecture What is refactoring?... or how to deal with the horrible code your colleagues have created... or how to deal with the horrible

More information

CS125 : Introduction to Computer Science. Lecture Notes #11 Procedural Composition and Abstraction. c 2005, 2004 Jason Zych

CS125 : Introduction to Computer Science. Lecture Notes #11 Procedural Composition and Abstraction. c 2005, 2004 Jason Zych CS125 : Introduction to Computer Science Lecture Notes #11 Procedural Composition and Abstraction c 2005, 2004 Jason Zych 1 Lecture 11 : Procedural Composition and Abstraction Solving a problem...with

More information

CS112 Lecture: Defining Instantiable Classes

CS112 Lecture: Defining Instantiable Classes CS112 Lecture: Defining Instantiable Classes Last revised 2/3/05 Objectives: 1. To describe the process of defining an instantiable class 2. To discuss public and private visibility modifiers. Materials:

More information

Lethbridge/Laganière 2005 Chapter 9: Architecting and designing software 6

Lethbridge/Laganière 2005 Chapter 9: Architecting and designing software 6 Trying to deal with something big all at once is normally much harder than dealing with a series of smaller things Separate people can work on each part. An individual software engineer can specialize.

More information

Elliotte Rusty Harold August From XML to Flat Buffers: Markup in the Twenty-teens

Elliotte Rusty Harold August From XML to Flat Buffers: Markup in the Twenty-teens Elliotte Rusty Harold elharo@ibiblio.org August 2018 From XML to Flat Buffers: Markup in the Twenty-teens Warning! The Contenders XML JSON YAML EXI Protobufs Flat Protobufs XML JSON YAML EXI Protobuf Flat

More information

CS125 : Introduction to Computer Science. Lecture Notes #38 and #39 Quicksort. c 2005, 2003, 2002, 2000 Jason Zych

CS125 : Introduction to Computer Science. Lecture Notes #38 and #39 Quicksort. c 2005, 2003, 2002, 2000 Jason Zych CS125 : Introduction to Computer Science Lecture Notes #38 and #39 Quicksort c 2005, 2003, 2002, 2000 Jason Zych 1 Lectures 38 and 39 : Quicksort Quicksort is the best sorting algorithm known which is

More information

G52CPP C++ Programming Lecture 9

G52CPP C++ Programming Lecture 9 G52CPP C++ Programming Lecture 9 Dr Jason Atkin http://www.cs.nott.ac.uk/~jaa/cpp/ g52cpp.html 1 Last lecture const Constants, including pointers The C pre-processor And macros Compiling and linking And

More information

Example: Fibonacci Numbers

Example: Fibonacci Numbers Example: Fibonacci Numbers Write a program which determines F n, the (n + 1)-th Fibonacci number. The first 10 Fibonacci numbers are 0, 1, 1, 2, 3, 5, 8, 13, 21, and 34. The sequence of Fibonacci numbers

More information

OOP Design Conclusions and Variations

OOP Design Conclusions and Variations CS108, Stanford Handout #20 Fall, 2008-09 Osvaldo Jiménez OOP Design Conclusions and Variations Thanks to Nick Parlante for much of this handout Part 1 -- Mainstream OOP Design First, we have the standard,

More information

A Comparison of Software Refactoring Tools

A Comparison of Software Refactoring Tools A Comparison of Software Refactoring Tools Jocelyn Simmonds Ecole des Mines de Nantes jocelyn.simmonds@eleve.emn.fr Tom Mens Vrije Universiteit Brussel tom.mens@vub.ac.be November 25, 2002 Abstract The

More information

CS 147: Computer Systems Performance Analysis

CS 147: Computer Systems Performance Analysis CS 147: Computer Systems Performance Analysis Test Loads CS 147: Computer Systems Performance Analysis Test Loads 1 / 33 Overview Overview Overview 2 / 33 Test Load Design Test Load Design Test Load Design

More information

Promoting Component Architectures in a Dysfunctional Organization

Promoting Component Architectures in a Dysfunctional Organization Promoting Component Architectures in a Dysfunctional Organization by Raj Kesarapalli Product Manager Rational Software When I first began my career as a software developer, I didn't quite understand what

More information

Refactoring and Rearchitecturing

Refactoring and Rearchitecturing Refactoring and Rearchitecturing Overview Introduction Refactoring vs reachitecting Exploring the situation Legacy code Code written by others Code already written Not supported code Code without automated

More information

Software Evolution. Dr. James A. Bednar. With material from

Software Evolution. Dr. James A. Bednar.  With material from Software Evolution Dr. James A. Bednar jbednar@inf.ed.ac.uk http://homepages.inf.ed.ac.uk/jbednar With material from Massimo Felici, Conrad Hughes, and Perdita Stevens SAPM Spring 2012: Evolution 1 Software

More information

Azon Master Class. By Ryan Stevenson Guidebook #5 WordPress Usage

Azon Master Class. By Ryan Stevenson   Guidebook #5 WordPress Usage Azon Master Class By Ryan Stevenson https://ryanstevensonplugins.com/ Guidebook #5 WordPress Usage Table of Contents 1. Widget Setup & Usage 2. WordPress Menu System 3. Categories, Posts & Tags 4. WordPress

More information

OO Development and Maintenance Complexity. Daniel M. Berry based on a paper by Eliezer Kantorowitz

OO Development and Maintenance Complexity. Daniel M. Berry based on a paper by Eliezer Kantorowitz OO Development and Maintenance Complexity Daniel M. Berry based on a paper by Eliezer Kantorowitz Traditional Complexity Measures Traditionally, Time Complexity Space Complexity Both use theoretical measures,

More information

Software Engineering Testing and Debugging Testing

Software Engineering Testing and Debugging Testing Software Engineering Testing and Debugging Testing Prof. Dr. Peter Thiemann Universitt Freiburg 08.06.2011 Recap Testing detect the presence of bugs by observing failures Debugging find the bug causing

More information

Clean & Speed Up Windows with AWO

Clean & Speed Up Windows with AWO Clean & Speed Up Windows with AWO C 400 / 1 Manage Windows with this Powerful Collection of System Tools Every version of Windows comes with at least a few programs for managing different aspects of your

More information

Chapter 8: Class and Method Design

Chapter 8: Class and Method Design Chapter 8: Class and Method Design Objectives Become familiar with coupling, cohesion, and connascence. Be able to specify, restructure, and optimize object designs. Be able to identify the reuse of predefined

More information

BASIC CONCEPT OF OOP

BASIC CONCEPT OF OOP Chapter-6 BASIC CONCEPT OF OOP Introduction: Object oriented programmingg is the principle of design and development of programs using modular approach. Object oriented programmingg approach provides advantages

More information

FUNCTIONAL BEST PRACTICES ORACLE USER PRODUCTIVITY KIT

FUNCTIONAL BEST PRACTICES ORACLE USER PRODUCTIVITY KIT FUNCTIONAL BEST PRACTICES ORACLE USER PRODUCTIVITY KIT Purpose Oracle s User Productivity Kit (UPK) provides functionality that enables content authors, subject matter experts, and other project members

More information

Inheritance and Polymorphism in Java

Inheritance and Polymorphism in Java Inheritance and Polymorphism in Java Introduction In this article from my free Java 8 course, I will be discussing inheritance in Java. Similar to interfaces, inheritance allows a programmer to handle

More information

Introduction. Object Orientated Analysis and Design. Benjamin Kenwright

Introduction. Object Orientated Analysis and Design. Benjamin Kenwright Introduction Object Orientated Analysis and Design Benjamin Kenwright Outline What do we mean by Object Orientated? Why do we need to analyze and design our solutions? Give examples What analysis and design

More information

shortcut Tap into learning NOW! Visit for a complete list of Short Cuts. Your Short Cut to Knowledge

shortcut Tap into learning NOW! Visit  for a complete list of Short Cuts. Your Short Cut to Knowledge shortcut Your Short Cut to Knowledge The following is an excerpt from a Short Cut published by one of the Pearson Education imprints. Short Cuts are short, concise, PDF documents designed specifically

More information

SOFTWARE ENGINEERING SOFTWARE EVOLUTION. Saulius Ragaišis.

SOFTWARE ENGINEERING SOFTWARE EVOLUTION. Saulius Ragaišis. SOFTWARE ENGINEERING SOFTWARE EVOLUTION Saulius Ragaišis saulius.ragaisis@mif.vu.lt CSC2008 SE Software Evolution Learning Objectives: Identify the principal issues associated with software evolution and

More information

Object Oriented Programming

Object Oriented Programming Object Oriented Programming Ray John Pamillo 1/27/2016 1 Nokia Solutions and Networks 2014 Outline: Brief History of OOP Why use OOP? OOP vs Procedural Programming What is OOP? Objects and Classes 4 Pillars

More information

Alan J. Perlis - Epigrams on Programming

Alan J. Perlis - Epigrams on Programming Programming Languages (CS302 2007S) Alan J. Perlis - Epigrams on Programming Comments on: Perlis, Alan J. (1982). Epigrams on Programming. ACM SIGPLAN Notices 17(9), September 1982, pp. 7-13. 1. One man

More information

Advanced Programming & C++ Language

Advanced Programming & C++ Language Advanced Programming & C++ Language ~6~ Introduction to Memory Management Ariel University 2018 Dr. Miri (Kopel) Ben-Nissan Stack & Heap 2 The memory a program uses is typically divided into four different

More information

Admin. How's the project coming? After these slides, read chapter 13 in your book. Quizzes will return

Admin. How's the project coming? After these slides, read chapter 13 in your book. Quizzes will return Recursion CS 1 Admin How's the project coming? After these slides, read chapter 13 in your book Yes that is out of order, but we can read it stand alone Quizzes will return Tuesday Nov 29 th see calendar

More information

Restructuring. What is restructuring? Tudor Gîrba Reengineering life cycle. What? forward engineering. reverse engineering

Restructuring. What is restructuring? Tudor Gîrba   Reengineering life cycle. What? forward engineering. reverse engineering Restructuring Tudor Gîrba www.tudorgirba.com Reengineering life cycle Reengineering... is the examination and alteration of a subject system to reconstitute it in a new form and the subsequent implementation

More information

Welcome to Python! If you re the type of person who wants to know

Welcome to Python! If you re the type of person who wants to know In This Chapter The history of Python What people use Python for Chapter 1 Introducing Python Useful concepts for Python programming Welcome to Python! If you re the type of person who wants to know what

More information

Object-Oriented Software Engineering Practical Software Development using UML and Java. Chapter 2: Review of Object Orientation

Object-Oriented Software Engineering Practical Software Development using UML and Java. Chapter 2: Review of Object Orientation Object-Oriented Software Engineering Practical Software Development using UML and Java Chapter 2: Review of Object Orientation 2.1 What is Object Orientation? Procedural paradigm: Software is organized

More information

Refactoring. Chen Tang March 3, 2004

Refactoring. Chen Tang March 3, 2004 Refactoring Chen Tang March 3, 2004 What Is Refactoring (Definition) Refactoring is the process of changing a software system in such a way that it does not alter the external behavior of the code yet

More information

Make $400 Daily. With Only. 5 Minutes Of Work

Make $400 Daily. With Only. 5 Minutes Of Work Make $400 Daily With Only 5 Minutes Of Work Hello friends, I am not a professional copywriter, so you will find a lot of mistakes and lack of professional touch in this e-book. But I have not made this

More information

From Design Patterns: Elements of Reusable Object Oriented Software. Read the sections corresponding to patterns covered in the following slides.

From Design Patterns: Elements of Reusable Object Oriented Software. Read the sections corresponding to patterns covered in the following slides. From Design Patterns: Elements of Reusable Object Oriented Software Read the sections corresponding to patterns covered in the following slides. DESIGN PRINCIPLES Modularity Cohesion Coupling Separation

More information

Tools for SW Projects

Tools for SW Projects Tools for SW Projects Dr. James A. Bednar jbednar@inf.ed.ac.uk http://homepages.inf.ed.ac.uk/jbednar SAPM Spring 2012: Tools 1 Automating Drudgery Most of the techniques we ll talk about can benefit from

More information

void printowing(double amount) { printbanner(); printdetails(); void printdetails(double amount) {

void printowing(double amount) { printbanner(); printdetails(); void printdetails(double amount) { Refactoring References: Martin Fowler, Refactoring: Improving the Design of Existing Code; ; Bruce Wampler, The Essence of Object-Oriented Oriented Programming with Java and UML A recent OO technique that

More information

Cache Coherence Tutorial

Cache Coherence Tutorial Cache Coherence Tutorial The cache coherence protocol described in the book is not really all that difficult and yet a lot of people seem to have troubles when it comes to using it or answering an assignment

More information