Los Techies : Blogs about software and anything tech!
Sign in
|
Join
|
Help
Home
Merchandise
Blogs
Media
Groups
RSS
Twitter
Jimmy Bogard
»
All Tags
»
Refactoring
(
RSS
)
Browse by Tags
Jimmy Bogard
Home
Contact
The Lounge
Ads by The Lounge
Friends of Pablo
Pablo's Extended Family
Syndication
RSS for Posts
Atom
RSS for Comments
Recent Posts
Refactoring challenge #2 – functionally illiterate
Refactoring Challenge Part 3 – Pattern Implementation
Refactoring challenge Part 2 – Preparation
Refactoring challenge Part 1 - Examination
Refactoring challenge
Tags
Agile
ASP.NET
ASP.NET MVC
AutoMapper
BDD
Behave#
Behavior-Driven Development
C#
Design
Domain-Driven Design
Legacy Code
LINQ
LINQ to SQL
Misc
NHibernate
Patterns
Rant
Refactoring
StructureMap
TDD
Team Build
Testing
Tools
VSTS
WCF
View more
News
Archives
March 2010 (2)
February 2010 (4)
January 2010 (9)
December 2009 (9)
November 2009 (5)
October 2009 (8)
September 2009 (8)
August 2009 (8)
July 2009 (11)
June 2009 (10)
May 2009 (11)
April 2009 (10)
March 2009 (9)
February 2009 (12)
January 2009 (10)
December 2008 (8)
November 2008 (14)
October 2008 (11)
September 2008 (10)
August 2008 (11)
July 2008 (12)
June 2008 (11)
May 2008 (15)
April 2008 (10)
March 2008 (15)
February 2008 (13)
January 2008 (19)
December 2007 (9)
November 2007 (17)
October 2007 (23)
September 2007 (10)
August 2007 (11)
July 2007 (11)
June 2007 (9)
May 2007 (14)
April 2007 (7)
Agile
ASP.NET MVC
BDD
Behavior-Driven Development
C#
Domain-Driven Design
Legacy Code
LINQ to SQL
Misc
MSBuild
PabloTV
Patterns
StructureMap
TDD
Refactoring challenge #2 – functionally illiterate
In the last refactoring challenge , I had a problem with some nasty conditional complexity. To be honest, the challenge was a subtle way to crowdsource new features in AutoMapper, but hey, it worked. One of the hard parts of being a sole contributor...
Published
Sun, Jul 07 2009 9:37 PM
by
bogardj
Filed under:
Refactoring
Refactoring Challenge Part 3 – Pattern Implementation
In the previous part to the refactoring challenge, I needed to structure the original implementation to a point where I could start applying other refactorings. Whenever I start to see a bunch of “if” statements or a big switch statement, this is...
Published
Wed, Jul 07 2009 9:21 PM
by
bogardj
Filed under:
Refactoring
Refactoring challenge Part 2 – Preparation
Other posts in this series: Refactoring challenge – cry for help Part 1 – Examination In the last part of this series, I took a closer look at the code smells found by commenters, which included: No tests Feature envy Conditional complexity Long method...
Published
Wed, Jul 07 2009 10:22 PM
by
bogardj
Filed under:
Refactoring
Refactoring challenge Part 1 - Examination
Most of the time I post code on my blog, it’s something I’m proud of. Other times, it’s code I didn’t write, which I promptly lambaste. In my last post , I threw up code I did write, but couldn’t see the design coming out. From the responses...
Published
Tue, Jul 07 2009 10:51 PM
by
bogardj
Filed under:
Refactoring
Refactoring challenge
I don’t like messy, obfuscated code. But occasionally often, I write it anyway as I can’t quite see the right way to go. Today is one of those days where I can’t seem to get past some ugly code, none of my normal tricks seem to work. ...
Published
Mon, Jul 07 2009 10:42 PM
by
bogardj
Filed under:
Refactoring
How not to do Dependency Injection, in NerdDinner
Checking out the NerdDinner code the other day, I found a common Dependency Injection anti-pattern. One of the core concepts of DI is that components are not responsible for locating their own dependencies. The code went part of the way to...
Published
Fri, Jul 07 2009 12:19 PM
by
bogardj
Filed under:
Refactoring
,
ASP.NET MVC
,
StructureMap
Fighting technical debt with the wall of pain
Technical debt, even on the agile-ist of agilista teams, still accumulates. Debt is inevitable, as initial design is always based on assumptions, not all of which pan out. I never view that as a failure, as all we can do is make the best decision...
Published
Wed, Jun 06 2009 8:57 PM
by
bogardj
Filed under:
Agile
,
Refactoring
Separation of Concerns by example: Part 5
In our last example, disaster finally struck our quaint little application. A strange defect showed up, which would be almost impossible to reproduce back on our developer machine. But because we've broken out our dependencies, our CustomerFinder...
Published
Thu, Jul 07 2008 8:23 AM
by
bogardj
Filed under:
Refactoring
,
LINQ to SQL
Separation of Concerns by example: Part 4
In the last part, we finally broke out the caching and data access concerns from our original class. The series so far includes: Separation of Concerns - how not to do it Separation of Concerns by example: Part 1 - Refactoring away from static class Separation...
Published
Thu, Jul 07 2008 7:57 AM
by
bogardj
Filed under:
Refactoring
,
BDD
,
Behavior-Driven Development
Entities and the Law of Demeter
The Law of Demeter , and its corresponding code smell, Inappropriate Intimacy , are some of the best bang-for-your-buck code smells that you can address. The basic idea behind each of these concepts is code related to an object should probably be inside...
Published
Mon, Jul 07 2008 7:51 AM
by
bogardj
Filed under:
Domain-Driven Design
,
Refactoring
Separation of Concerns by example: Part 3
We made quite a bit of progress separating out the concerns in Part 2, but there are still some issues with our current design. Other parts in this series include: Separation of Concerns - how not to do it Separation of Concerns by example: Part 1 - Refactoring...
Published
Thu, Jun 06 2008 11:14 PM
by
bogardj
Filed under:
Patterns
,
Refactoring
,
LINQ to SQL
Separation of Concerns by example: Part 2
Separation of concerns is one of the fundamental tenets of good object-oriented design. Anyone can throw a bunch of code in a method and call it a day, but that's not the most maintainable approach. So far, we've looked at: Separation of Concerns...
Published
Tue, Jun 06 2008 8:17 AM
by
bogardj
Filed under:
Refactoring
Separation of Concerns by example: Part 1
In the prelude to this series, I looked at a snippet of code that took the kitchen sink approach to concerns. Here's what we started out with: public class CustomerManager { [ DataObjectMethod ( DataObjectMethodType .Select, false )] public static...
Published
Thu, Jun 06 2008 10:12 PM
by
bogardj
Filed under:
Refactoring
Separation of Concerns - how not to do it
In a recent article on layered LINQ applications in the latest ASP.NET PRO magazine (no link, you have to pay), the author proposes separating your application into three distinct layers: User Interface (UI) layer Business Logic Layer (BLL) Data Access...
Published
Tue, Jun 06 2008 8:00 AM
by
bogardj
Filed under:
Refactoring
,
LINQ to SQL
Failures of aimless large-scale refactorings
At the recent Austin Code Camp, I heard a few stories after my Legacy Code talk about teams attacking their legacy code in prolonged refactoring binges that never seemed to end. Never ending, because no one had a good idea of what success looked like...
Published
Tue, Jun 06 2008 10:37 PM
by
bogardj
Filed under:
Refactoring
1
2
Next >
Copyright Los Techies 2008, 2009. All rights reserved.