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 Postfix Completionで爆速コーディング
Search
takahirom
November 06, 2015
Programming
2
720
Android Postfix Completionで爆速コーディング
takahirom
November 06, 2015
Tweet
Share
More Decks by takahirom
See All by takahirom
AIエージェントによるテストフレームワーク Arbigent
takahirom
0
620
Google の LLM ライブラリ を Android アプリで 使うには?
takahirom
1
1.9k
Robolectric Native Graphics and Roborazzi
takahirom
1
2k
Androidアプリで安定して動作させ継続的に開発するために設計の原則を利用して開発した話
takahirom
2
1.4k
Android Tools & Performance
takahirom
1
1.2k
Jetpack Compose State Practices
takahirom
1
1.4k
Inside Jetpack Compose
takahirom
1
980
What’s new in Android Jetpack and Tools
takahirom
0
390
ABEMAのKotlin Multiplatform
takahirom
4
5.9k
Other Decks in Programming
See All in Programming
Playwrightはどのようにクロスブラウザをサポートしているのか
yotahada3
7
2.3k
CSC509 Lecture 06
javiergs
PRO
0
250
ソフトウェア設計の実践的な考え方
masuda220
PRO
3
500
私達はmodernize packageに夢を見るか feat. go/analysis, go/ast / Go Conference 2025
kaorumuta
2
500
Le côté obscur des IA génératives
pascallemerrer
0
130
大規模アプリのDIフレームワーク刷新戦略 ~過去最大規模の並行開発を止めずにアプリ全体に導入するまで~
mot_techtalk
0
400
GitHub Actions × AWS OIDC連携の仕組みと経緯を理解する
ota1022
0
240
CSC509 Lecture 02
javiergs
PRO
0
410
Django Ninja による API 開発効率化とリプレースの実践
kashewnuts
0
1.1k
(Extension DC 2025) Actor境界を越える技術
teamhimeh
1
240
ネイティブ製ガントチャートUIを作って学ぶUICollectionViewLayoutの威力
jrsaruo
0
140
CSC305 Lecture 03
javiergs
PRO
0
240
Featured
See All Featured
Principles of Awesome APIs and How to Build Them.
keavy
127
17k
For a Future-Friendly Web
brad_frost
180
9.9k
Build your cross-platform service in a week with App Engine
jlugia
232
18k
Documentation Writing (for coders)
carmenintech
75
5k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
140
34k
Writing Fast Ruby
sferik
629
62k
Imperfection Machines: The Place of Print at Facebook
scottboms
269
13k
RailsConf 2023
tenderlove
30
1.2k
It's Worth the Effort
3n
187
28k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
5.6k
VelocityConf: Rendering Performance Case Studies
addyosmani
332
24k
Learning to Love Humans: Emotional Interface Design
aarron
274
40k
Transcript
Android Postfix Completion ͰരίʔσΟϯά takahirom
takahirom • Android͕͖Ͱ͢ • AndroidͷϥΠϒϥϦ,AndroidStudioϓϥάΠϯΛ࡞͍ͬͯͨΓ͠·͢ • Github͕झຯͰ͢ • 11ίϛοτΛଓ͚͍ͯ·͢ •
Contribution streak͕365ʹͳΓ·ͨ͠ʂ
takahirom • Android͕͖Ͱ͢ • AndroidͷϥΠϒϥϦ,AndroidStudioϓϥάΠϯΛ࡞͍ͬͯͨΓ͠·͢ • Github͕झຯͰ͢ • 11ίϛοτΛଓ͚͍ͯ·͢ •
Contribution streak͕365ʹͳΓ·ͨ͠ʂ ↑ͷΛ͠·͢
Postfix Completionͱ
Postfix Completionͱ • AndroidStudioͷݩͷIntelliJ IDEAʹ͋Δػೳ
Postfix Completionͱ • AndroidStudioͷݩͷIntelliJ IDEAʹ͋Δػೳ • test.par Ͱ (test)ͱ͍ͬͨมΛͯ͘͠ΕͨΓͱ͍ͬͨิ͕ Ͱ͖ΔͷͰ͢ɻ
Postfix Completionͱ • AndroidStudioͷݩͷIntelliJ IDEAʹ͋Δػೳ • test.par Ͱ (test)ͱ͍ͬͨมΛͯ͘͠ΕͨΓͱ͍ͬͨิ͕ Ͱ͖ΔͷͰ͢ɻ
• Android StudioσϑΥϧτͰར༻Ͱ͖·͢ɻ
Postfix Completionͱ • AndroidStudioͷݩͷIntelliJ IDEAʹ͋Δػೳ • test.par Ͱ (test)ͱ͍ͬͨมΛͯ͘͠ΕͨΓͱ͍ͬͨิ͕ Ͱ͖ΔͷͰ͢ɻ
• Android StudioσϑΥϧτͰར༻Ͱ͖·͢ɻ • ৭Μͳछྨ͕͋ͬͯศརͰ͢
Postfix Completion σϞ • new ArrayList<String>().var • list.for • savedInstanceState.nn
• list.field • ɻɻɻɻ
Postfix Completion σϞ • new ArrayList<String>().var • list.for • savedInstanceState.nn
• list.field • ɻɻɻɻ • ઃఆը໘ʹҰཡ͕͋Γ·͢
࠷ߴʂAndroid൛ཉ͍͠ʂ
࠷ߴʂAndroid൛ཉ͍͠ʂ • ઃఆը໘͔Β͍͡Εͳ͍ɺɺ
࠷ߴʂAndroid൛ཉ͍͠ʂ • ઃఆը໘͔Β͍͡Εͳ͍ɺɺ • ࡞ΕΔΈ͍ͨͳͷͰ࡞Γ·ͨ͠ʂ
࠷ߴʂAndroid൛ཉ͍͠ʂ • ઃఆը໘͔Β͍͡Εͳ͍ɺɺ • ࡞ΕΔΈ͍ͨͳͷͰ࡞Γ·ͨ͠ʂ • →Android Postfix Completion
Android Postfix Completionͱ
Android Postfix Completionͱ • “Postfix Completion”ΛAndroidಛԽʹͨ͠ͷ
Android Postfix Completionͱ • “Postfix Completion”ΛAndroidಛԽʹͨ͠ͷ • ࣗ࡞Android StudioϓϥάΠϯ
Android Postfix Completionͱ • “Postfix Completion”ΛAndroidಛԽʹͨ͠ͷ • ࣗ࡞Android StudioϓϥάΠϯ •
6000μϯϩʔυಥഁ
Android Postfix Completionͱ • “Postfix Completion”ΛAndroidಛԽʹͨ͠ͷ • ࣗ࡞Android StudioϓϥάΠϯ •
6000μϯϩʔυಥഁ • https://plugins.jetbrains.com/plugin/7775?pr=
ϥΠϒίʔσΟϯά • Ϣʔβʔ໊ͱύεϫʔυ͕ೖ͍ͬͯͯ • fabΛλοϓ͢Δͱ • ”ొྃ”ͱ͍͏τʔετΛදࣔ͢Δ
Android Postfix CompletionͰͰ͖Δ͜ͱ • .toast ←τʔετ࡞ΕΔ • .log←ϩάग़ͤΔ • .findv←findViewग़ͤΔ
• isemp←TextUtils.isEmpty (@kikuchy͞Μ͋Γ͕ͱ͏) • ͳͲͳͲ
ࣗͰςϯϓϨʔτΛՃͯ͠ΈΑ͏ • ։ൃڥߏஙʹ͍ͭͯ • ͜ͷϓϥάΠϯͷΈʹ͍ͭͯ
ڥߏங 1. git clone
[email protected]
:takahirom/android-postfix-plugin.git 2. IntelliJ IDEAͰΠϯϙʔτ(Πϯετʔϧ͓͍͍ͯͯͩ͘͠͞) 3. Run/Debug
configuration͔ΒGradleͰઃఆ 4. ࣮ߦ͢ΔͱPluginΠϯετʔϧࡁΈIntelliJ IDEA͕ىಈ͢Δ
ڥߏங • Run/Debug configuration͔Β GradleͰઃఆ • ݁ߏ؆୯Ͱ͢
͜ͷϓϥάΠϯͷΈʹ͍ͭͯ (݁ߏख୳ΓͳͷͰࣗ৴͕ͳ͍෦͕ ଟʑ͋Γ·͢)
1:postfixTemplateProviderΛఆٛ • plugin.xml͕AndroidManifest.xmlͷΑ͏ͳͷͰ͢ɻ • (Ճ͢Δ߹͢Ͱʹొ͞Ε͍ͯΔͷͰมߋ͢Δඞཁ ͳ͍Ͱ͢)
2:ProviderͷΫϥεΛ࡞ΓςϯϓϨʔτҰཡΛฦ͢ • ͲΜͳςϯϓϨʔτ͕͋Δͷ͔ΛAndroidStudioʹೝࣝͤ͞Δ
3:TemplateΛ࡞Δ • .soutͰSystem.out.println($expr);Λग़͢ྫ
3:TemplateΛ࡞Δ • .soutͰSystem.out.println($expr);Λग़͢ྫ ม.soutͰදࣔ͞ΕΔ
3:TemplateΛ࡞Δ • .soutͰSystem.out.println($expr);Λग़͢ྫ ม.soutͰදࣔ͞ΕΔ ม࣌ʹީิʹදࣔ͞ΕΔྫ
3:TemplateΛ࡞Δ • .soutͰSystem.out.println($expr);Λग़͢ྫ ม.soutͰදࣔ͞ΕΔ ม࣌ʹީิʹදࣔ͞ΕΔྫ ީิʹදࣔ͢Δมͷ݅
3:TemplateΛ࡞Δ • .soutͰSystem.out.println($expr);Λग़͢ྫ ม.soutͰදࣔ͞ΕΔ ม࣌ʹީิʹදࣔ͞ΕΔྫ ީิʹදࣔ͢Δมͷ݅ ςϯϓϨʔτ $expr$ม.soutͷม $END$ऴྃ࣌ͷΧʔιϧͷҐஔ
4:มͷ༰ͳͲʹΑͬͯಈతʹม͑Δ • .logͰLog.d(“MainActivity”, “i:” + i)Ͱ͍ͬͯΔ͜ͱ
4:มͷ༰ͳͲʹΑͬͯಈతʹม͑Δ • .logͰLog.d(“MainActivity”, “i:” + i)Ͱ͍ͬͯΔ͜ͱ static import͍ͯ͠Δ͔ Ͳ͏͔Ͱɺग़͢จࣈΛม͑Δ
4:มͷ༰ͳͲʹΑͬͯಈతʹม͑Δ • .logͰLog.d(“MainActivity”, “i:” + i)Ͱ͍ͬͯΔ͜ͱ ςϯϓϨʔτจࣈྻ $TAG $expr $END$͕͋Δ
static import͍ͯ͠Δ͔ Ͳ͏͔Ͱɺग़͢จࣈΛม͑Δ
4:มͷ༰ͳͲʹΑͬͯಈతʹม͑Δ • .logͰLog.d(“MainActivity”, “i:” + i)Ͱ͍ͬͯΔ͜ͱ ςϯϓϨʔτจࣈྻ $TAG $expr $END$͕͋Δ
$exprʹೖ͢Δ Log.dͷҾStringͳͷͰ ඞཁʹԠͯ͡”expr:”+exprʹ͢Δ static import͍ͯ͠Δ͔ Ͳ͏͔Ͱɺग़͢จࣈΛม͑Δ
4:มͷ༰ͳͲʹΑͬͯಈతʹม͑Δ • .logͰLog.d(“MainActivity”, “i:” + i)Ͱ͍ͬͯΔ͜ͱ ςϯϓϨʔτจࣈྻ $TAG $expr $END$͕͋Δ
$exprʹೖ͢Δ Log.dͷҾStringͳͷͰ ඞཁʹԠͯ͡”expr:”+exprʹ͢Δ $TAGʹೖ͢Δ ඞཁʹԠͯ͡TAGมΛͬͨΓɺ Ϋϥε໊ΛͬͨΓ͢Δ static import͍ͯ͠Δ͔ Ͳ͏͔Ͱɺग़͢จࣈΛม͑Δ
5:ઃఆը໘ʹදࣔ͞ΕΔtemplateϑΝΠϧΛॻ͘
ͭΒ͍͜ͱ • ݁ߏ࣮ํ๏ख୳ΓͰ͢ • AOSP͔ΒAndroid StudioͷίʔυΛམͱͤΔͷͰɺGrep͠·͘Γ· ͠ΐ͏(R.id.text→TextViewΈ͍ͨͳͷΛ୳ͨ͠Γ͠·ͨ͠) • AOSPͷAndroid StudioͷcloneͱϏϧυ:http://tools.android.com/build
• IntelliJ Plugin ษڧձͰݟ͕ٵ͑·͢ɻ(Gradle-intellij-pluginΛڭ͑ͯ ͑ͨΓ͠·ͨ͠ɻ)
·ͱΊ • ͥͻͬͯΈ͍ͯͩ͘͞ʂ https://plugins.jetbrains.com/plugin/7775 • ϑΟʔυόοΫ͍ͬͯ·͢ʂ • ϓϧϦΫΤετ͍ͬͯ·͢ʂhttps://github.com/takahirom/android- postfix-plugin •
GradleରԠ͍ͯ͠ΔͷͰ݁ߏ؆୯ʹ։ൃڥ࡞Ε·͢ʂ • GithubͷϦϙδτϦʹ˒͚͍ͭͯͩ͘͞ʂ