Professional Refactoring in C# & ASP.NET

Overview

Refactoring is an effective way to quickly uncover problematic code and fix it. In this first book to provide a hands-on approach to refactoring in C# and ASP.NET, you'll discover to apply refactoring techniques to manage and modify your code. Plus, you'll learn how to build a prototype application from scratch and discover how to refactor the prototype into a properly designed, enterprise-level application.

With the help of step-by-step directions, you'll gain a better ...

See more details below
Paperback
$42.28
BN.com price
(Save 29%)$59.99 List Price
Other sellers (Paperback)
  • All (13) from $4.59   
  • New (8) from $31.08   
  • Used (5) from $4.59   
Sending request ...

Overview

Refactoring is an effective way to quickly uncover problematic code and fix it. In this first book to provide a hands-on approach to refactoring in C# and ASP.NET, you'll discover to apply refactoring techniques to manage and modify your code. Plus, you'll learn how to build a prototype application from scratch and discover how to refactor the prototype into a properly designed, enterprise-level application.

With the help of step-by-step directions, you'll gain a better understanding of different code issues and refactoring transformations. Many of these transformations are developed from real-world scenarios that are the result of key business decisions. In addition, you'll find formal definitions of refactoring techniques that you'll be able to refer to while on the job.

This book covers the refactoring techniques that will enable you to become more efficient and productive. You'll be able to use this information to respond to change and improve the design of existing code.

What you will learn from this book

  • How to assemble your own refactoring toolkit
  • Techniques for performing unit testing
  • Tips on refactoring to patterns
  • How to use refactoring to upgrade legacy C# and ASP.NET code
  • Ways to take advantage of the method extraction to eliminate duplicated code
  • How to make code simpler, easier to modify, and more understandable
  • All about object oriented theory and design patterns
  • Methods for using LINQ and other C# 3.0 enhancements

Who this book is for

This book is for C# and ASP.NET developers who want to learn how to effectively manage and modify their code with refactoring tools and features.

Wrox Professional guides are planned and written by working programmers to meet the real-world needs of programmers, developers, and IT professionals. Focused and relevant, they address the issues technology professionals face every day. They provide examples, practical solutions, and expert education in new technologies, all designed to help programmers do a better job.

Read More Show Less

Product Details

  • ISBN-13: 9780470434529
  • Publisher: Wiley, John & Sons, Incorporated
  • Publication date: 4/20/2009
  • Edition number: 1
  • Pages: 552
  • Product dimensions: 7.30 (w) x 9.10 (h) x 1.50 (d)

Meet the Author

Danijel Arsenovski is an author, software architect, and agile coach. Currently, he works as Product and Solutions Architect at Excelsys S.A., designing web 2.0 banking solutions for numerous clients in the region. He started experimenting with refactoring while overhauling a huge banking system, and he hasn’t lost interest in refactoring ever since. He is known for evangelizing about refactoring on the .NET platform. Arsenovski is a contributing author for Visual Studio Magazine, .NET Developers Journal, and Visual Systems Journal. He holds the Microsoft Certified Solution Developer (MCSD) certification, and was named Microsoft MVP in 2005. You can reach him at danijel.arsenovski@empoweragile.com, and feel free to drop by at his blog at http://blog.refactoring.net.

Read More Show Less

Table of Contents

Introduction.

Chapter 1: Refactoring: What’s All the Fuss About?

A Quick Refactoring Overview.

The Refactoring Process: A Closer Look.

No Programmer Is an Island.

C# and Refactoring.

Summary.

Chapter 2: A First Taste of Refactoring.

Sample Application: Calories Calculator.

Refactoring in Action.

Implementing the Persistence Functionality.

Calories Calculator, Refactored Version.

Summary.

Chapter 3: Assembling a Refactoring Toolkit.

Using an Automated Refactoring Tool.

Unit-Testing Basics: The Testing Harness.

About Version Control.

Summary.

Chapter 4: Application Prototype: Rent-a-Wheels.

Interviewing the Client.

Taking the Initial Steps in the Rent-a-Wheels Project.

Making the Prototype Work.

Fast and Furious Approach to Programming.

Summary.

Chapter 5: Basic Hygiene.

Eliminating Dead Code.

Reducing the Scope and Access Level of Unduly Exposed Elements.

Using Explicit Imports.

Removing Unused Assembly References.

Basic Hygiene in the Rent-a-Wheels Application.

Summary.

Chapter 6: From Problem Domain to Code: Closing the Gap.

Understanding the Problem Domain.

Published and Public Interfaces.

Summary.

Chapter 7: The Method Extraction Remedy for Duplicated Code.

Encapsulating Code and Hiding the Details.

DecomposingMethods.

InliningMethods.

The Duplicated Code Smell.

Extract Method and Replace Magic Literal Refactoring in the Rent-a-Wheels Application.

Summary.

Chapter 8: Method Consolidation and Extraction Techniques.

Dealing with Temporary Variables.

Dealing with Long and Nested Conditionals.

Method Reorganization and Rent-a-Wheels.

Summary.

Chapter 9: Discovering Objects.

A Brief Object-Oriented Programming Overview.

Designing Classes.

Discovering Hidden Classes.

Summary.

Chapter 10: Advanced Object-Oriented Concepts and Related Refactorings.

Inheritance, Polymorphism, and Genericity.

Inheritance Abuse and Refactoring Solutions.

Making Use of Generics.

Summary.

Chapter 11: Code Organization on a Large Scale.

Namespaces.

Assemblies

C# Project File Structure Organization.

Namespace Organization and Windows Forms Inheritance in Rent-a-Wheels.

Summary.

Chapter 12: Refactoring to Patterns.

Design Patterns: What’s All the Fuss About?

Example Design Pattern: Abstract Factory.

Dependency Injection Pattern.

Refactoring to Patterns and the Rent-a-Wheels Application.

Summary.

Chapter 13: LINQ and Other C# 3.0 Enhancements.

Type Inference for Local Variables.

Summary.

Chapter 14: A Short History of the Web for Developers and ASP.NET Tooling.

Refactor! for ASP.NET.

HTML History and Its Legacy.

Catching Up with theWeb.

Summary.

Chapter 15: Refactoring ASP.NET Applications.

Refactoring HTML.

Refactoring ASP.NET Code.

Rent-a-Wheels and ASP.NET Refactorings.

Summary.

Appendix A: Rent-a-Wheels Prototype Internals and Intricacies.

Hand Over Button Click Event-Handling Code.

Display Button Click Event-Handling Routine.

Summary.

Appendix B: Unleash Refactor! for ASP.NET.

Index.

Read More Show Less

Customer Reviews

Be the first to write a review
( 0 )
Rating Distribution

5 Star

(0)

4 Star

(0)

3 Star

(0)

2 Star

(0)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously

    If you find inappropriate content, please report it to Barnes & Noble
    Why is this product inappropriate?
    Comments (optional)