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
コードを変更せずに デバッグメニューで Androidアプリの動作を変更する
Search
takahirom
December 08, 2017
Programming
280
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
コードを変更せずに デバッグメニューで Androidアプリの動作を変更する
takahirom
December 08, 2017
More Decks by takahirom
See All by takahirom
AIエージェントで 変わるAndroid開発環境
takahirom
3
830
AndroidアプリのAI実装をAndroidifyで学ぶ ー Google公式サンプルによる体験と実装 ー
takahirom
0
150
AIエージェントによるテストフレームワーク Arbigent
takahirom
0
1.1k
Google の LLM ライブラリ を Android アプリで 使うには?
takahirom
1
2.2k
Robolectric Native Graphics and Roborazzi
takahirom
1
2.4k
Androidアプリで安定して動作させ継続的に開発するために設計の原則を利用して開発した話
takahirom
3
1.5k
Android Tools & Performance
takahirom
1
1.3k
Jetpack Compose State Practices
takahirom
1
1.5k
Inside Jetpack Compose
takahirom
1
1.1k
Other Decks in Programming
See All in Programming
「人を評価する AI」の設計と実装
ryoyanara
0
240
生成AIで帳票OCRが「簡単に」作れる時代になった?
kon_shou
0
1.2k
承認済みなのに差戻しできてしまうバグ、型で潰せます
shinchit
0
110
ドリフトを絶対に許さない(?)CDK運用 / CDK Ops with Zero Tolerance for Drifts (?)
akihisaikeda
1
230
今さら聞けない .NET CLI
htkym
0
210
Detecting Compromised CI with eBPF and Cilium Tetragon
lizrice
0
250
「つくるAI」だけではバグは見つからない ~テストに必要な「見つけるAI」を分離させる戦略~
mfunaki
0
170
in-process GraphQL のすすめ #ginzajs
izumin5210
4
1.5k
AIの中の人になってみる
htkym
0
120
初めての模倣学習とVLA
natsutan
0
230
思考垂れ流し開発 ~音声入力 × AIエージェント × 開発ハーネスによる試行錯誤~
npostring
0
140
FastAPI の並行処理モデルを完全に理解する
hoto17296
8
2.9k
Featured
See All Featured
Deep Space Network (abreviated)
tonyrice
0
270
The Spectacular Lies of Maps
axbom
PRO
1
940
The innovator’s Mindset - Leading Through an Era of Exponential Change - McGill University 2025
jdejongh
PRO
1
290
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
37
6.6k
The Illustrated Children's Guide to Kubernetes
chrisshort
51
53k
The #1 spot is gone: here's how to win anyway
tamaranovitovic
3
1.1k
BBQ
matthewcrist
89
10k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
3k
Accessibility Awareness
sabderemane
1
180
Reality Check: Gamification 10 Years Later
codingconduct
0
2.3k
Game over? The fight for quality and originality in the time of robots
wayneb77
1
250
Un-Boring Meetings
codingconduct
0
390
Transcript
؝٦س㢌刿ׇ׆ח رغحًؚصُ٦ד "OESPJE،فٔך⹛⡲㢌刿ׅ UBLBIJSPN
˖ "OESPJEָ㥨ֹ ˖ UBLBIJSPNהְֲせד 2JJUBהַ剅ְגְךד ״׃ֶֻ격ְ׃תׅ 荈䊹稱➜
˖ "#ذأزך"#ⴖ剏ְִ ˖ ח⳿זְت؎،ؚٗرغحؚ⚥כ嫣㔐⳿׃ְ ˖ رغحؚ⚥ח؟٦غ٦橆㞮ⴖ剏ְִ ˖ זוזו ،فٔךرغحؚװ2"ח״ ذأز⚥կկ
˖ رغحؚ⚥חرغحؚ׃װְׅ堣腉ًصُ٦ח׃ ךկ ˖ رغحؚ⚥חֽ鸐濼זו⳿׃גְֶגծ ةحفׅהرغحًؚصُ٦ָ⳿״ֲח׃גծ 㢌刿דֹ״ֲח׃גرغحؚ⡲噟⸬桦涸ח ׅ رغحًؚصُ٦
if (isShowTutorialTiming()) { showTutorial() } fun isShowTutorialTiming(): Boolean { //
࣍ͷλΠϛϯά·Ͱදࣔ͠ͳ͍ if (System.currentTimeMillis() < pref.getNextTutorialtiming()) { return false; } // 3ճ͔͠දࣔ͠ͳ͍ if (3 <= pref.getTutorialCount()) { return false; } return true; } ثُ٦زٔ،ٕ䌢ח邌爙׃ְ 儗וֲ׃תַׅ JT4IPX5VUPSJBM5JNJOHדUSVF鵤׃ְ
pref.setNextTutorialtiming(currentMills + 100000) pref.setTutorialCount(0) رغحًؚصُ٦ⰻ ❌㔐׃ַ邌爙דֹזְ
if (isShowTutorialTiming()) { showTutorial() } fun isShowTutorialTiming(): Boolean { //
࣍ͷλΠϛϯά·Ͱදࣔ͠ͳ͍ if (System.currentTimeMillis() < pref.getNextTutorialtiming()) { return false; } // 3ճ͔͠දࣔ͠ͳ͍ if (3 <= pref.getTutorialCount()) { return false; } return true; } ؝٦س湫ׅ
if (isShowTutorialTiming()) { showTutorial() } fun isShowTutorialTiming(): Boolean { if
(pref.isAlwaysShowTutorialTiming()) { return true; } // ࣍ͷλΠϛϯά·Ͱදࣔ͠ͳ͍ if (System.currentTimeMillis() < pref.getNextTutorialtiming()) { return false; } // 3ճ͔͠දࣔ͠ͳ͍ if (3 <= pref.getTutorialCount()) { return false; } return true; } ؝٦س湫ׅ ❌ٔٔ٦أתד ؝٦سָⰅג׃תֲ
if (isShowTutorialTiming()) { showTutorial() } } fun isShowTutorialTiming(): Boolean {
if (BuildConfig.DEBUG) { if (pref.isAlwaysShowTutorialTiming()) { return true; } } // ࣍ͷλΠϛϯά·Ͱදࣔ͠ͳ͍ if (System.currentTimeMillis() < pref.getNextTutorialtiming()) { return false; } // 3ճ͔͠දࣔ͠ͳ͍ if (3 <= pref.getTutorialCount()) { return false; } return true; } ؝٦س湫ׅ ❌醱꧟ז؝٦سָ فٗتؙءّٝח
ΦϒδΣΫτࢦͰ͏·͘Ͱ͖ͳ͍ಛʢΫϥεؒ Λԣஅ (cross-cutting) ͢ΔΑ͏ͳػೳʣΛʮΞεϖΫτʯ ͱΈͳ͠ɺΞεϖΫτهड़ݴޠΛ͍ͪͯͯ͠هड़͢ Δ͜ͱ (WikipediaΑΓ) ،ألؙز䭷ぢفؚٗٓىؚٝ
@Aspect public class AspectExample { @Before("execution(* on*(..))") public void before()
{ System.out.println("before !!"); } } "TQFDU+ ֽֿדPOד㨣תًاحسָㄎל儗ח ؚٗ⳿ֿׅהָ⳿勻
@Around("execution(boolean com...MainActivity.isShowTutorialTiming(..))") public boolean isShowTutorialDebug(ProceedingJoinPoint jp) { return true; }
"TQFDU+⢪ג ⭕ֽֿדثُ٦زٔ،ٕ⳿ׇ ⭕EFCVHؿٕؓتח縧ֽלرغحؚ儗ך黝䘔דֹ
"TQFDU+⢪ג @Around("execution(boolean com...MainActivity.isShowTutorialTiming(..))") public boolean isShowTutorialDebug(ProceedingJoinPoint jp) { return true;
} !"SPVOEדJT4IPX5VUPSJBM5JNJOHך䖓חⳢ椚㙵鴥 ֿֿדכًاحسך鵤⦼חUSVF鵤׃גְ
@Around("execution(boolean com...MainActivity.isShowTutorialTiming(..))") public boolean isShowTutorialDebug(ProceedingJoinPoint jp) { return true; }
"TQFDU+⢪ג ❌ًاحسせך㢌刿ד堣腉׃זֻז ❌رغحؚךןחֿ剅ֻ
@Around("execution(* *.*(..)) && @annotation(com...DebugReturn)”) public boolean isShowTutorialDebug(ProceedingJoinPoint jp) { return
true; } @DebugReturn fun isShowTutorialTiming(): Boolean { ... } "TQFDU+⢪ג 暴㹀ך،ظذ٦ءّٝאְגְًاحسד USVF鵤ׅ״ֲח
@Around("execution(* *.*(..)) && @annotation(com...DebugReturn)”) public boolean isShowTutorialDebug(ProceedingJoinPoint jp) { return
true; } @DebugReturn fun isShowTutorialTiming(): Boolean { ... } "TQFDU+⢪ג ❌ֿה䌢חUSVFחזג׃תֲ ❌رؿٕؓزך㹋鄲ָㄎן⳿ׇזְ
@Around("execution(* *.*(..)) && @annotation(com...DebugReturn)”) public Object debugReturnMethod(ProceedingJoinPoint jp) { //
ΞϊςʔγϣϯͷதͷҾ(key)Λऔಘ͢Δॲཧ ... final DebugSetting debugSetting = DebugSetting.getInstance(); if (debugSetting.contains(key)) { return debugSetting.get(key); } return jp.proceed(); } @DebugReturn(“tutorial”) fun isShowTutorialTiming(): Boolean { ... } "TQFDU+⢪ג
@Around("execution(* *.*(..)) && @annotation(com...DebugReturn)”) public Object debugReturnMethod(ProceedingJoinPoint jp) { //
ΞϊςʔγϣϯͷதͷҾ(key)Λऔಘ͢Δॲཧ ... final DebugSetting debugSetting = DebugSetting.getInstance(); if (debugSetting.contains(key)) { return debugSetting.get(key); } return jp.proceed(); } @DebugReturn(“tutorial”) fun isShowTutorialTiming(): Boolean { ... } "TQFDU+⢪ג ،ظذ٦ءّٝחLFZ床ׅ
@Around("execution(* *.*(..)) && @annotation(com...DebugReturn)”) public Object debugReturnMethod(ProceedingJoinPoint jp) { //
ΞϊςʔγϣϯͷதͷҾ(key)Λऔಘ͢Δॲཧ ... final DebugSetting debugSetting = DebugSetting.getInstance(); if (debugSetting.contains(key)) { return debugSetting.get(key); } return jp.proceed(); } "TQFDU+⢪ג ،ظذ٦ءָّٝאְًاحسךⳢ椚 ההךثُ٦زٔ،ٕⴻ㹀ٗآحؙ 㹋遤 1SFGFSFODFח⥂䭯׃גְ鏣㹀⢪ֲ
@Around("execution(* *.*(..)) && @annotation(com...DebugReturn)”) public Object debugReturnMethod(ProceedingJoinPoint jp) { //
ΞϊςʔγϣϯͷதͷҾ(key)Λऔಘ͢Δॲཧ ... final DebugSetting debugSetting = DebugSetting.getInstance(); if (debugSetting.contains(key)) { return debugSetting.get(key); } return jp.proceed(); } "TQFDU+⢪ג 鏣㹀⥂㶷׃גְֶגծ鏣㹀ָ֮ל⢪ְ זֽלծًاحسⰻך傀㶷ךⳢ椚遤ֲ
"TQFDU+⢪ג ❌"TQFDU+ך㼪Ⰵָ⦜
ٓ؎ـٓٔ⡲ת׃ IUUQTHJUIVCDPNUBLBIJSPNEFCVHBMUFS החַֻأة٦ָ妜׃ְדׅ
˖ رغحًؚصُ٦㹋鄲ׅ儗ח"TQFDU+⢪ֲהفٗتؙءّٝ ך؝٦س寅ׁ׆ח㹋鄲׃גְֽתׅկ ˖ 䩛鯪חװז%FCVH"MUFS⢪גגְֻׁկ 㹋鄲ה׃גכ ַז謬ְדׅ ˖ ⟃♴ךٔهآزٔأة٦׃גְֻׁկխ
IUUQTHJUIVCDPNUBLBIJSPNEFCVHBMUFS ˖ 2JJUBח֮ךד״׃ֶֻ격ְ׃תׅկ IUUQTRJJUBDPNUBLBIJSPNJUFNTFCCDGED תה