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
RuntimePermissionChecker
Search
taptappun
February 22, 2018
Technology
0
88
RuntimePermissionChecker
RuntimePermissionCheckerというAndroidのライブラリを作成したのでその紹介。
taptappun
February 22, 2018
Tweet
Share
More Decks by taptappun
See All by taptappun
勢いで作った便利ツールのご紹介
takukobayashi
1
510
Other Decks in Technology
See All in Technology
Oracle Database@AWS:サービス概要のご紹介
oracle4engineer
PRO
2
660
フルカイテン株式会社 エンジニア向け採用資料
fullkaiten
0
10k
#22 CA × atmaCup 3rd 1st Place Solution
yumizu
1
120
Eight Engineering Unit 紹介資料
sansan33
PRO
0
6.1k
Introduction to Sansan for Engineers / エンジニア向け会社紹介
sansan33
PRO
5
59k
CQRS/ESになぜアクターモデルが必要なのか
j5ik2o
0
320
国井さんにPurview の話を聞く会
sophiakunii
1
290
純粋なイミュータブルモデルを設計してからイベントソーシングと組み合わせるDeciderの実践方法の紹介 /Introducing Decider Pattern with Event Sourcing
tomohisa
1
380
AI時代のアジャイルチームを目指して ー スクラムというコンフォートゾーンからの脱却 ー / Toward Agile Teams in the Age of AI
takaking22
9
3k
AWSと生成AIで学ぶ!実行計画の読み解き方とSQLチューニングの実践
yakumo
2
150
「アウトプット脳からユーザー価値脳へ」がそんなに簡単にできたら苦労しない #RSGT2026
aki_iinuma
6
3.3k
スクラムを一度諦めたチームにアジャイルコーチが入ってどう変化したか
kyamashiro73
0
140
Featured
See All Featured
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.4k
The Curse of the Amulet
leimatthew05
0
6.7k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
2.2k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
32
Why You Should Never Use an ORM
jnunemaker
PRO
61
9.7k
What does AI have to do with Human Rights?
axbom
PRO
0
1.9k
Digital Ethics as a Driver of Design Innovation
axbom
PRO
0
140
Leo the Paperboy
mayatellez
0
1.3k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
270
A Modern Web Designer's Workflow
chriscoyier
698
190k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
7.9k
Building Applications with DynamoDB
mza
96
6.9k
Transcript
RUNTIMEPERMISSIONCHECKER ͱ͍͏ϥΠϒϥϦΛ࡞ͬͨ
ࣗݾհ ɾখྛ (@taptappun) Facebookͬͯ·͢ ɾϋοΧιϯδϟϯΩʔ ɾαʔόʔ݉ΫϥΠΞϯτɾήʔϜΤϯδχΞ (ϑϧεελοΫΤϯδχΞ) ɾࠓNCJapanʹॴଐ ɾPS4ΞΧϯτ: tappun
ɾχϯςϯυʔεΠονΞΧϯτ: SW-0178- 9450-2426
RUNTIME PERMISSIONͬͯ? https://qiita.com/caad1229/items/35bab757217b204711df https://developer.android.com/training/permissions/requesting.html?hl=ja ରݖݶ͕ඞཁͳૢ࡞͕ߦΘΕ ΔલʹϢʔβͷڐՄΛΒ͏ػ ೳɻ targetSdkVersion 23Ҏ্ (Android6.0
Lolipop)Ͱඞཁʹͳ ͬͨػೳɻ
͜Μͳ͜ͱͬͯͳ͔ͬͨͰ͔͢? ϓϩάϥϛϯάهड़ྃ ͋Ε?ͳ͔ͥಈ͔ͳ͍… ͋ΕʁͰ͓͔͍͠ͱ͜Ζͳ͍Αͳ͊…
͋!PERMISSIONΛ ฉ͘ͷΕͯͨ!!!
লΛ౿·͑ͯɺ͍࣮͟!! if(Build.VERSION.SDK_INT >= 23) { requestPermissions(new String[]{"android.permission.CAMERA"}, 0); } @Override
public void onRequestPermissionsResult(int requestCode, String permissions[], int[] grantResults) { switch (requestCode) { case 0: { if (grantResults.length > 0 && grantResults[0] == PackageManager.PERMISSION_GRANTED){ Log.i("permission", "permitted"); } else { Log.i("permission", "not permitted"); } break; } } }
PERMISSIONͷ͜ͱͳΜ͔ͯΜ͕͑ͨ͘Ͷ͐ͬ͢ ॲཧଟ͍ͬ͢… AndroidManifest.xmlʹpermissionهड़ͨ͠Β ࣗಈతʹΑΖͬͯ͘͠΄͍ͬ͢͠ɻ Android2.0ܥ͔Β։ൃ͍ͯ͠Δ͔Β͢Δ ͱɺ ͤΊͯҰߦՃ͢Δ͚ͩͰޙΑΖͬ͘͠ ͯ΄͍ͬ͢͠…
ϥΠϒϥϦ࡞Γ·ͨ͠ https://qiita.com/taptappun/items/7fae4317d751245b2089 https://github.com/TakuKobayashi/RuntimePermissionChecker
Ͷ?؆୯Ͱ͠ΐ?
Έͳ͞Μ͍ͬͯͩ͘͞ ελʔͱ͔͍͍Ͷ͍ͩ͘͞