Skip to content

XP123

Exploring Extreme Programming

Menu

Primary menu

  • Home
  • Refactoring Workshop
  • Start Here
    • Comics
    • TDD: Test-Driven Development
    • Refactoring
    • User Stories
    • Dungeons & Patterns
  • Update
  • About
  • Contact

Tag Archives: refactoring

Lambda to Reduce Coupling

Posted on October 27, 2021 by Bill Wake

Coupling occurs when one part of a system depends on another part. That is, if one part changes, the other must be adjusted too. Lambda expressions can reduce coupling by needing to refer to fewer things. Dependencies on Objects Consider Continue reading Lambda to Reduce Coupling→

Posted in xp123.com | Tagged design, programmer, refactoring, tdd, XPlorations

Lambda for Control Structures, a Refactoring

Posted on October 13, 2021 by Bill Wake

Several mainstream languages have added better support for lambda expressions (including lighter syntax) in the last few years. This can let you define new forms of control structures, and reduce duplication in a different way than say extracting a common Continue reading Lambda for Control Structures, a Refactoring→

Posted in xp123.com | Tagged design, refactoring, XPlorations

Extracting Parameterized Unit Tests

Posted on September 8, 2021 by Bill Wake

Duplication across tests may not be as harmful as duplication in production code, but a parameterized unit test can reduce duplication and help us create better tests. Judging Tests – The Pause Spotting duplication in tests is like spotting it Continue reading Extracting Parameterized Unit Tests→

Posted in xp123.com | Tagged design, refactoring, tdd, XPlorations

Refactoring: Forcing the Right Extract Method

Posted on August 25, 2021 by Bill Wake

Automated refactoring tools are great, but sometimes the tool doesn’t make the best choice. We can often nudge the tool to a better choice. Why Bother? Why bother nudging? Couldn’t you do the refactoring manually just as quickly? You could Continue reading Refactoring: Forcing the Right Extract Method→

Posted in xp123.com | Tagged design, programmer, refactoring, XPlorations

Nested Loops to Functional Pipeline

Posted on August 18, 2021 by Bill Wake

Nested structures are challenging to read; a pipeline is usually easier to read and think about. Nested structures have that “arrow of doom” feeling, where you work your way in multiple levels then out. It’s hard to tell what’s being Continue reading Nested Loops to Functional Pipeline→

Posted in xp123.com | Tagged refactoring, XPlorations

Wrapping a Type, All the Way

Posted on August 11, 2021 by Bill Wake

Sometimes you want to change from using a basic type (such as Int or String) to a type that contains the basic type as a value. (See Refactoring in the References.) The change itself isn’t hard, but then you have Continue reading Wrapping a Type, All the Way→

Posted in xp123.com | Tagged refactoring, XPlorations

Transliterating Old-School BASIC

Posted on July 14, 2021 by Bill Wake

Once in a while, I run into a 1980s-era BASIC program, typically written for Commodore 64, Apple ][, or TRS-80. I’d like to transliterate it into a modern language, refactor it, and explore it. These old programs make a nice Continue reading Transliterating Old-School BASIC→

Posted in xp123.com | Tagged compilers, programmer, refactoring, retrocomputing

Data Flow Analysis for Refactoring

Posted on June 16, 2021 by Bill Wake

As you refactor, you sometimes need to understand how the data flow through the code. We’ll look at several ways that can reveal that information. Data Flow Analysis Data flow analysis tracks the creation and use of data through the Continue reading Data Flow Analysis for Refactoring→

Posted in xp123.com | Tagged refactoring

Local Refactorings

Posted on February 3, 2021 by Bill Wake

To refactor is to systematically “improve the design of existing code”. There are many ways to classify refactorings, but one distinction stands out to me: local refactorings. A local refactoring affects only one file (and perhaps its tests). Why Local? Continue reading Local Refactorings→

Posted in xp123.com | Tagged programmer, refactoring, XPlorations

Refactor Template Method to Strategy

Posted on November 11, 2020 by Bill Wake

The Template Method design pattern defines an algorithm in an abstract class, and defers some steps to its subclasses. A Strategy defines a family of pluggable implementations. We’ll see how to convert from Template Method to Strategy. Template Method A Continue reading Refactor Template Method to Strategy→

Posted in xp123.com | Tagged patterns, programmer, refactoring, XPlorations

Post navigation

← Older posts
Newer posts →

Primary Sidebar Widget Area

Stay Up-to-Date

If you'd like to hear when articles come out, sign up today!

|●  Become a Patron!

Recent Posts

  • And-Or Trees
  • Run Tests Without an App — Step by Step with Xcode
  • Swift Testing – A New Unit Testing Framework
  • TDD with a Function Pipeline
  • Trees – Confidence in Design
  • Pipelines – Confidence in Design
  • Threaded Code (and Composite)
  • Time Troubles – Transitions
  • Refactor: Inline-Adjust-Extract
  • Organizing Fields and Methods

Tags

agile analysis atdd author business charts classic coach computers conference cool customer design economics fiction games HCI history improv integration interesting intro Java job aids language lean learning metaphor music myth patterns planning programmer refactoring resources reviews scrum software spreadsheet stories tdd team tester training XPlorations

Archives

counter for wordpress
Copyright © 2025 XP123. All Rights Reserved.
Theme: Catch Box by Catch Themes
Scroll Up