Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Speaker Deck
PRO
Sign in
Sign up for free
Push通知を届けるために
futabooo
July 14, 2015
Programming
1
3.2k
Push通知を届けるために
futabooo
July 14, 2015
Tweet
Share
More Decks by futabooo
See All by futabooo
Android Jetpack Navigation Deep Links Tips
futaboooo
0
420
チームの学びを活かす全社での取り組み / company wide efforts to make use of team's learning
futaboooo
1
480
ペアプロ・モブプロを広めるのに役立ったControl Chartの使い方 / How to use Control Chart which helped spread Pair or Mob Programing
futaboooo
2
210
スクラムチームをやめて、20人でカンバン運用してきた半年間の軌跡 / Stop Scrum Start Kanban
futaboooo
19
17k
InvisionのAndroidアプリでみる4つのデザイン基本原則 / Four design basic principles seen in Invision's Android application
futaboooo
2
1.9k
Pairsの開発のすべて / all of Pairs development
futaboooo
1
2.1k
モブプログラミングという開発スタイル、あるいは生産性について / On development style called mob programming, or productivity
futaboooo
5
7.8k
Androidでスクレイピングした話 / Talk of scraping with Android
futaboooo
0
4.6k
新人スクラムマスターが開発者と兼任しながらやってきた事と成果/What the newcomer Scrum Master came while concurrently serving as a developer and the result
futaboooo
1
1.6k
Other Decks in Programming
See All in Programming
10年以上続くプロダクトの フロントエンド刷新プロジェクトのふりかえり
yotahada3
2
340
Findy - エンジニア向け会社紹介 / Findy Letter for Engineers
findyinc
2
42k
低レイヤーから始める GUI
fadis
18
9.4k
Circuit⚡
monaapk
0
200
Swift Concurrency in GoodNotes
inamiy
4
1.4k
ipa-medit: Memory search and patch tool for IPA without Jailbreaking/ipa-medit-bh2022-europe
tkmru
0
130
Qiita Night PHP 2023
fuwasegu
0
11k
PHP でガチの電卓を作る
memory1994
PRO
1
120
Functional Data Engineering - A Blueprint for adopting functional principles in data pipeline
vananth22
0
190
2023年にクル(かもしれない)通信ミドルウェア技術(仮)
s_hosoai
0
220
データドリブンな組織の不正検知
fkubota
0
280
domain層のモジュール化 / MoT TechTalk #15
mot_techtalk
0
130
Featured
See All Featured
Design by the Numbers
sachag
271
18k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
270
12k
The Brand Is Dead. Long Live the Brand.
mthomps
48
2.9k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
120
29k
Six Lessons from altMBA
skipperchong
15
2.3k
What’s in a name? Adding method to the madness
productmarketing
12
1.9k
The Straight Up "How To Draw Better" Workshop
denniskardys
226
130k
The World Runs on Bad Software
bkeepers
PRO
59
5.7k
Streamline your AJAX requests with AmplifyJS and jQuery
dougneiner
128
8.8k
How to Ace a Technical Interview
jacobian
270
21k
How New CSS Is Changing Everything About Graphic Design on the Web
jensimmons
214
12k
Designing the Hi-DPI Web
ddemaree
273
32k
Transcript
Push௨Λಧ͚ΔͨΊʹ #potatotips 19 @futabooo
About me futabooo (Takahiro futagawa) - Engineer @eureka - Android
Developer - ࠷ۙΓΛײ͍ͯ͡Δ͜ͱ - ΫϥυϑΝϯσΟϯάͰߪೖͨ͠ ೣࣖܕϔουϑΥϯͷ։ൃԆ 4݄ૹ → 10݄ૹ http://www.axentwear.jp/
About eureka
ࠓ͢͜ͱ
ࠓ͢͜ͱ - InstanceID - RegistrationID(iOSͰ͍͏σόΠετʔΫϯ) - τϥϒϧγϡʔςΟϯά
GCMʹ͍ͭͯ
GCMͷྲྀΕ https://developers.google.com/cloud-messaging/gcm - ࣄલʹRegistrationIDΛอଘ - αʔό͔ΒRegistrationIDΛͬͯ PushΛૹ৴ RegistrationID
GCMͷ࣮ʹ͍ͭͯ - ࣮ํ๏ެࣜυΩϡϝϯτࢀর https://developers.google.com/cloud-messaging/android/legacy-regid - ΞϓϦΞοϓσʔτͰRegistrationID͕ มߋ͞ΕΔͱ͜ΖΧόʔ - ͷ࠶ىಈͰมߋ͞ΕΔ߹͕͋Δ
αʔόʹมߋޙͷIDΛૹΒͳ͍ͱ ಧ͔ͳ͘ͳΔ
ͷ࠶ىಈʹରԠ <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" /> AndroidManifest.xml <receiver android:name=".BootReceiver"> <intent-filter> <action
android:name="android.intent.action.BOOT_COMPLETED" /> </intent-filter> </receiver>
ͷ࠶ىಈʹରԠ BootReceiver.java @Override public void onReceive(Context c, Intent i)
{ //RegistrationIDͷ࠶ొॲཧ }
τϥϒϧγϡʔςΟϯά
τϥϒϧγϡʔςΟϯά - GCMஅ https://support.google.com/googleplay/android-developer/answer/2663268
τϥϒϧγϡʔςΟϯά - GCMஅ εςʔλεʹΑͬͯMessage͕ਖ਼ ৗʹಧ͍͔ͨͲ͏͔֬ೝͰ͖Δ
͓·͚
͓·͚ - અిΞϓϦ - ͷઅిػೳ - wifiͷஅ - Serviceͷఀࢭ Push௨Λಧ͚ΔͨΊͷઓ͍ଓ͘
- DozeϞʔυ
Thank you :)