V
主页
【重构】工厂函数比构造器加参数香不?Replace Constructor With Factory Method 以工厂函数取代构造函数
发布人
【重构】工厂函数比构造器加参数香不?Replace Constructor With Factory Method 以工厂函数取代构造函数
打开封面
下载高清视频
观看高清视频
视频下载器
【重构】重复代码?依恋情结?Replace Data Value with Object
【重构】有了高贵的多态还要if else吗?Replace Conditional With Polymorphism 以多态取代条件表达式
【重构】你写的代码是给人看的还是给计算机看的?Rename Method函数改名
【重构】比写注释更高级的做法你知道吗?Introduce Assertion 引入断言
【重构】啥是卫语句?Replace Nested Conditional With Guard Clauses 以卫语句取代嵌套条件表达式
【重构】自己要不如自己调?Replace Parameter With Methods 以函数取代参数
【重构】不要打哑谜?Replace Magic Number With Symbolic Constant以字面常量取代魔法数
【重构】一堆类型判断不如建出子类?Replace Type Code With Subclasses 以子类取代类型码
【重构】混沌统一不如直白解体?Replace Parameter With Explicit Methods 以明确函数来取代参数
【重构】儿子们动作顺序相同细节不同?Form Template Method 塑造模板函数
【重构】常用手法之一Replace Temp With Query以查询取代临时变量
【重构】子类只有常量函数没必要搞继承?Replace Subclass With Fields 以字段取代子类
【重构】不是每个儿子都会的本事?Push Down Method 函数下移
【重构】想让儿子们天生有不如让老爸有?Pull Up Constructor Body 构造函数本体上移
【重构】Java Stack败笔滥用继承?Replace Inheritance With Delegation 以委托取代继承
【重构】break、return的用武之地?Remove Control Flag 移除控制标记
【重构】一堆常量可读性差类型检验不了?Replace Type Code With Class 以类取代类型码
【重构】有了给力的异常还要错误暗号吗?Replace Error Code With Exception 以异常取代错误码
【重构】很容易做到却往往没人去做?Remove Parameter 移除参数
【重构】出双入对?数据泥团?Introduce Parameter Object 引入参数对象
【重构】物以类聚?Consolidate Conditional Expression 合并条件表达式
【重构】让不变脱离万变?Consolidate Duplicate Conditional Fragments 合并重复的条件片段
【重构】改不了源码?Introduce Local Extension引入本地扩展
【重构坏味道】小小函数大大价值?Long Method 过长函数
【重构】火眼金睛提类共性?Extract Superclass 提炼超类
【重构】想要属于自己的唯一标签?Change Value To Reference将值对象改为引用对象
【重构】该间接访问属性?Self Encapsulate Field自封装字段
【重构】if then else看不懂?Decompose Conditional 分解条件表达式
层层对象转换☹️你找到好方法了吗?🤔2分钟上手MapStruct
【重构坏味道】兄弟原来你也在这里?Alternative Classes With Different Interfaces 异曲同工的类
【DaynaBaby书架】从impossible到i'm possible少了一点和一段?一点信念和一段《微习惯》
【重构】萎缩了?Inline Class内联类
【重构】你啥都会但我只要一点?Extract Interface 提炼接口
【重构】挨个儿给不如打包给?Preserve Whole Object 保持对象完整
【重构坏味道】消灭掉平行世界的你?Parallel Inheritance Hierarchies 平行继承体系
【DaynaBaby书架】我们今天写的是明天的遗留代码?《重构》
【重构】暴露了太多?Hide Delegate隐藏委托关系
【重构】三心二意?Split Temporary Variable 分解临时变量
【重构坏味道】得到所有礼物却只想挑几样玩?Refused Bequest 被拒绝的馈赠
【重构】不是每个实例都有的特性?Extract Subclass 提炼子类