Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Notifications in iOS10
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Tachibana Kaoru
July 21, 2016
Technology
2k
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Notifications in iOS10
Tachibana Kaoru
July 21, 2016
More Decks by Tachibana Kaoru
See All by Tachibana Kaoru
GeoLocationAnchor and MKTileOverlay
toyship
0
420
Custom Group Activities
toyship
3
1.5k
Synchronized iPhones, Again!
toyship
2
1.7k
ARKit4.pdf
toyship
1
2.4k
Custom Gesture Recognizer on iOS
toyship
3
1.5k
HEVC Video with Alpha Channel
toyship
1
1.3k
RealityKit & Reality Composer
toyship
3
700
ARKit3
toyship
4
7.7k
UIViewPropertyAnimator and Easing
toyship
2
1.2k
Other Decks in Technology
See All in Technology
DevelopersIO 2026 知識の地図を描く ─ オントロジーとは何か?
ishikawa_satoru
1
1.7k
AI × アーキテクト 第1・2章|生成AIの課題とアーキテクトの素養
daidaidai
0
170
自作バイナリを動かす「入口」8選
puhitaku
2
1.3k
脆弱性診断って、何をしているの? 〜弱点を見つけて、会社の改善につなげるまで〜
keeg
0
930
アウトプット初心者、半年間のふりかえり
4o1sobblue
0
440
オントロジーって 結局なにもの? AI エージェントに「意味」を渡す知識設計の話
greenmidori
0
220
しろおびから始める!ログ活用の第一歩
shumei_ito
0
950
Kiro Crewをはじめよう
kizawa2020
1
160
ストレスなくAIと付き合いたい!こんなときどうしてる?
namiki64
3
560
M5Stackで作る BLEマウス GPSログの世界
tomokusaba
0
430
触りたくないデータに、どう触るか AI時代のRBACアクセスガバナンス
ivry_presentationmaterials
0
270
QA4AI 2026-Oct 生成AI時代の品質保証
tokuty
1
880
Featured
See All Featured
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
1
360
The Cult of Friendly URLs
andyhume
79
7k
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
68
59k
Why You Should Never Use an ORM
jnunemaker
PRO
61
10k
SEO for Brand Visibility & Recognition
aleyda
0
4.8k
First, design no harm
axbom
PRO
2
1.3k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
3.1k
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
3
280
The untapped power of vector embeddings
frankvandijk
2
1.9k
The Curse of the Amulet
leimatthew05
3
16k
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
460
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
69
67k
Transcript
No#fica#ons in iOS10 2016/07/21 @TachibanaKaoru
ࣗݾհ ϑϦʔϥϯεͷiOSΤϯδχΞΛ͍ͯ͠· ͢ɻ (20168݄͔Βʂ) • Twi%er: @TachibanaKaoru • Blog :
h%p:/ /www.toyship.org/ • ϘϧμϦάϯ͖
What's new in No.fica.on of iOS • ௨ʹ"tle/sub"tle͕͚ͭΒΕΔΑ͏ʹͳͬͨ • ௨ʹΠϝʔδը૾͕͚ͭΒΕΔΑ͏ʹͳͬͨ
• ௨ʹCustom UI͕͚ͭΒΕΔΑ͏ʹͳͬͨ • Ϣʔβʔ͕௨ΛڐՄ͔ͨ͠Ͳ͏͔ͷઃఆ͕ͱΕΔΑ͏ʹͳͬ ͨ • ৴ɾະ৴ͷ௨Λ؆୯ʹϋϯυϦϯάͰ͖ΔΑ͏ʹͳͬͨ
৴ɾະ৴ͷ௨Λ؆୯ʹϋϯυ ϦϯάͰ͖ΔΑ͏ʹͳͬͨ
Local No(fica(onͱRemote No(fica(on͕౷ Ұ͞Ε·ͨ͠ɻ
Remote No(fica(on { "aps" : { "alert" : { "title"
: "Introduction to Notifications", "subtitle" : "Session 707", "body" : "Woah! These new notifications look amazing!" }, "badge" : 1 }, }
Local No(fica(on let center = UNUserNotificationCenter.current() let content = UNMutableNotificationContent()
content.title = "Hello" content.body = "This is a big news!" content.sound = UNNotificationSound.default() let trigger = UNTimeIntervalNotificationTrigger.init(timeInterval: 10, repeats: false) let request = UNNotificationRequest.init( identifier: "NewsUpdate", // ͜ͷIDΛΩʔʹͯ͠আฤूΛ͠·͢ content: content, trigger: trigger) center.add(request)
௨ͷཧ ·ͣɺ௨ͷঢ়ଶʹԼهͷ͕̏ͭ͋Γ·͢ɻ • Pending : ·ͩൃՐ͍ͯ͠ͳ͍௨ • Delivered : ൃՐ͕ͨ͠ɺϢʔβʔ͕ॲཧʢλοϓͳͲʣΛͯ͠
͍ͳ͍௨ • (Read) : Ϣʔβʔ͕ॲཧΛͨ͠௨ɹʢ͜ͷঢ়ଶͷ௨औಘͰ ͖·ͤΜɻʣ
௨ͷঢ়ଶભҠ • ొ͞Εͨ௨ɺPendingঢ়ଶͱͳΔ • τϦΨʔΠϕϯτʢ࣌ؒҐஔͳͲʣʹΑΓൃՐͯ͠Delivered ঢ়ଶͱͳΔ • Ϣʔβʔ͕ॲཧΛ͢ΔͱReadͱͳΓɺ UNUserNo2fica2onCenter͔ΒऔಘͰ͖ͳ͘ͳΔ
get pending no*fica*ons UNUserNotificationCenter.current().getPendingNotificationRequests { requests in print("== Pending Notification
: \(requests.count) == ") for request in requests { request.identifier request.content.title request.content.subtitle request.content.body request.trigger print(" -- title : \(request.content.title) body:\(request.content.body)") } }
delete pending no+fica+ons //ಛఆͷpending௨Λফ͢ UNUserNotificationCenter.current().removePendingNotificationRequests(withIdentifiers: ["NewsUpdate","NewsDelivery"]) //શ෦ͷpending௨Λফ͢ UNUserNotificationCenter.current().removeAllPendingNotificationRequests()
update pending no,fica,ons // ৽͍͠contentΛͭ͘Δ let content = UNMutableNotificationContent() content.title
= "Hello" content.body = "This is a more big news!" content.sound = UNNotificationSound.default() let trigger = UNTimeIntervalNotificationTrigger.init(timeInterval: 5, repeats: false) // ৽͍͠requestΛͭ͘Δ let newRequest = UNNotificationRequest.init(identifier: "NewsUpdate", content: content, trigger: trigger) // ৽͍͠requestΛͭ͘Δʢݹ͍ͷΛdelete͢Δඞཁͳ͍ʣ UNUserNotificationCenter.current().add(newRequest) { error in // error }
get delivered no,fica,ons UNUserNotificationCenter.current().getDeliveredNotifications { notifications in // [UNNotification]) print("==
Delivred Notification : \(notifications.count) == ") for notification in notifications { notification.date notification.request print(" -- title : \(notification.request.content.title) body:\(notification.request.content.body) date: \(notification.date)") } }
delete delivered no+fica+ons //ಛఆͷdeliver͞Εͨ௨Λফ͢ UNUserNotificationCenter.current().removeDeliveredNotifications(withIdentifiers: ["NewsUpdate","NewsDelivery"]) //શ෦ͷdeliver͞Εͨ௨Λফ͢ UNUserNotificationCenter.current().removeAllDeliveredNotifications()
No#fica#on in ac#on • ΞϓϦ͕ Foregroundʹ͋Δঢ়ଶͰ௨͕৴͞Εͨ߹ʹɺγ εςϜͷ௨ը໘ΛͩͤΔΑ͏ʹͳΓ·ͨ͠ɻ func userNotificationCenter(_ center:
UNUserNotificationCenter, willPresent notification: UNNotification, withCompletionHandler completionHandler: (UNNotificationPresentationOptions) -> Void) { print("! Notification came!\(notification.request.content.title)") completionHandler([.alert, .sound])// ͜ΕΛ͍Ε͓ͯ͘ͱɺγεςϜͷ௨ը໘Λͩͯ͘͠ΕΔ }
iOS9ͱiOS10ͷ௨ϋϯυϦϯάͷҧ͍ • Fav௨ • iOS9·ͰɺFav͞ΕΔͨͼʹ௨͕͘ΔͷͰɺ௨ཝ͕ಛ ఆͷtweetͷFav௨Ͱ͏·ͬͯ͠·ͬͨ • iOS10ͰɺFav͞ΕΔͨͼʹ௨Λߋ৽͢ΔͨΊɺಛఆͷ tweetͷFav௨ৗʹҰͭ
iOS9ͱiOS10ͷ௨ϋϯυϦϯάͷҧ͍ • ίϝϯτ௨ • iOS9·Ͱɺίϝϯτ͕ͭͨ͘ͼʹ௨Λૹ͍ͬͯͨͨΊɺ Γ͕͍͋ͬͯΔεϨουͷίϝϯτ௨Ͱ͏·ͬͯ͠·ͬ ͨ • iOS10Ͱɺίϝϯτ͕ͭͨ͘ͼʹ௨Λߋ৽͢ΔͨΊɺಛ ఆͷεϨουͷ௨ৗʹҰͭ
·ͱΊ • iOS10Ͱ௨ͷ༰Λมߋ͢Δ͜ͱ͕Ͱ͖ΔΑ͏ʹͳͬͨͨ Ίɺॊೈͳ௨ઃܭ͕Ͱ͖ΔΑ͏ʹͳΓ·ͨ͠ • ແବͳ௨Λ;ͣ͞ɺ͢Ͱʹ͋Δ௨Λߋ৽͠Α͏ • ΞϓϦ௨ͰɺγεςϜ௨ը໘Λදࣔ͠Α͏