码迷,mamicode.com
首页 > 其他好文 > 详细

重新组织函数

时间:2015-12-16 12:20:14      阅读:153      评论:0      收藏:0      [点我收藏+]

标签:

提炼函数(extract method)

 

内联函数(inline method)

 

内联临时变量(inline temp)

 

以查询取代临时变量(replace temp with query)

 

引入解释性变量(introduce explaining variable)

 

分解临时变量(split temporary variable)

 

移除对参数的赋值(remove assignments to parameters)

 

以函数对象取代函数(replace method with method object)

 

替换算法(substitute algorithm)

重新组织函数

标签:

原文地址:http://www.cnblogs.com/foreverApril/p/5050615.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!