TOP

このエントリーをはてなブックマークに追加

リファクタリング技法

ここではCode Smellを解消するために参考となるリファクタリング技法や、その他参考になりそうな概念を紹介していこうと思います。

リファクタリングに関してはこの辺りの書籍が参考になると思います。


リファクタリング第2版
refactoring
レガシーコード改善ガイド
legacy_code

関連するリファクタリング技法

Organizing Data

Organizing Data

Self Encapsulate Field

Self Encapsulate Field

Replace Data Value with Object

Replace Data Value with Object

Change Value to Reference

Change Value to Reference

Change Reference to Value

Change Reference to Value

Replace Array with Object

Replace Array with Object

Duplicate Observed Data

Duplicate Observed Data

Change Unidirectional Association to Bidirectional

Change Unidirectional Association to Bidirectional

Change Bidirectional Association to Unidirectional

Change Bidirectional Association to Unidirectional

Replace Magic Number with Symbolic Constant

Replace Magic Number with Symbolic Constant

Encapsulate Field

Encapsulate Field

Encapsulate Collection

Encapsulate Collection

Replace Type Code with Class

Replace Type Code with Class

Replace Type Code with Subclasses

Replace Type Code with Subclasses

Replace Type Code with State/Strategy

Replace Type Code with State/Strategy

Replace Subclass with Fields

Replace Subclass with Fields