Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
リファクタリングのススメ
Search
yKazihara
June 24, 2017
Education
4
4.6k
リファクタリングのススメ
2017/06/24のKANJAVA PARTY 2017!!!で発表したLT資料です。
yKazihara
June 24, 2017
Tweet
Share
More Decks by yKazihara
See All by yKazihara
ダークサイドエンジニア
ykazihara
0
330
Other Decks in Education
See All in Education
新卒研修に仕掛ける 学びのサイクル / Implementing Learning Cycles in New Graduate Training
takashi_toyosaki
1
150
子どものためのプログラミング道場『CoderDojo』〜法人提携例〜 / Partnership with CoderDojo Japan
coderdojojapan
4
16k
SkimaTalk Tutorial for Students
skimatalk
0
1.8k
ThingLink
matleenalaakso
28
4.1k
SkimaTalk Tutorial for Corporate Customers
skimatalk
0
290
Gamified Interventions for Composting Behavior: A Case Study Using the Gamiflow Framework in a Workplace Setting
ezefranca
1
130
2025/06/05_読み漁り学習
nag8
0
140
20250625_なんでもCopilot 一年の振り返り
ponponmikankan
0
210
生成AIとの上手な付き合い方【公開版】/ How to Get Along Well with Generative AI (Public Version)
handlename
0
480
仮説の取扱説明書/User_Guide_to_a_Hypothesis
florets1
4
310
Interaction - Lecture 10 - Information Visualisation (4019538FNR)
signer
PRO
0
2k
OpenRobomaster 中国のロボットコンテスト 日本連携の可能性
takasumasakazu
0
450
Featured
See All Featured
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.3k
How GitHub (no longer) Works
holman
314
140k
Designing for humans not robots
tammielis
253
25k
Build your cross-platform service in a week with App Engine
jlugia
231
18k
What's in a price? How to price your products and services
michaelherold
246
12k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.3k
The World Runs on Bad Software
bkeepers
PRO
69
11k
Done Done
chrislema
184
16k
The Pragmatic Product Professional
lauravandoore
35
6.7k
Producing Creativity
orderedlist
PRO
346
40k
Agile that works and the tools we love
rasmusluckow
329
21k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
Transcript
リファクタリングのススメ らん(@run51502)(๑و˙o˙)و 2017/06/24
自己紹介 名前:らん(@run51502) 京都生まれ、大阪在住 業界12年目の遅咲きSE 歌えるSE目指してボイストレーニングに励む
ポケモンGO:レベル39(資料作成時点) はねろ!コイキング:ランク63(資料作成時点)
参考本
リファクタリングとは? ソフトウェアを理解しやすく、変更を容易に する為に行うもの 外的振る舞いは既存を保つこと リファクタリングの利点とは? ソースの構造理解ができる
リファクタリングはいつ行う? どんな風に? 本番リリース後、手が空いたら 機能追加時 コードレビュー時に検討してみる 3度目の正直
対象となる例: エビ if (a1 == true) { if (a2
== false) { if (a3 == true) { if (a4 == false) { if (a5 == true) { if (a6 == true) { return; } } } } } }
対象となる例: 君(変数)の名は オブジェクト1:「もしかして私たち・・・」 オブジェクト2:「もしかして俺たち・・・」 「「入れ替わってる〜!?!?!?」」 マトリョーシカ
詰め放題セール 対象となる例: 名家の家系図
対象となる例: 覚えられない呪文 その他: 世界一周の旅(クラス渡り歩き) 遠距離恋愛(変数の宣言と値設定が離れている) などなど・・・
最後に リファクタリング前にテスト作成 やめる勇気を持とう ペアプロで検討してみよう 常にリファクタリングを意識して、 良いコードを育てよう!