Share
Embed
Transcript
34 slides
-
ࣗݾհ w ాݩًʢͳΓͨͱ͖ʣ w !NP@UP@ w J04ΤϯδχΞ w ݸਓͰΧϝϥΞϓϦΛ࡞ͬͨΓ w
88%$ߦ͚ͳ͔ͬͨͷͰDBUDI88%$ͱ͍͏ே͔࣌Β 88%$ͷใަΛ͢ΔษڧձΛ88%$ͷؒຖே࣌ʹ ى͖ͯ։࠵ͯ͠·ͨ͠ -
4JSJ,JU%PNBJOT w "VEJPPSWJEFPDBMMJOH w 4UBSUBOBVEJPDBMM w 4UBSUBWJEFPDBMM w 4FBSDIUIFVTFS`TDBMMIJTUPSZ w
.FTTBHJOH w 4FOEBNFTTBHF w 4FBSDIGPSNFTTBHFT w 1IPUP4FBSDI w 4FBSDIGPSQIPUPT w 1MBZBQIPUPTMJEFTIPX w 1BZNFOUT w 4FOEBQBZNFOUUPBOPUIFSVTFS w 3FRVFTUBQBZNFOUGSPNBOPUIFS VTFS w 8PSLPVUT w 4UBSUBXPSLPVU w 1BVTFBXPSLPVU w 3FTVNFBXPSLPVU w &OEBXPSLPVU w $BODFMBXPSLPVU w 3JEFCPPLJOH w (FUBMJTUPGBWBJMBCMFSJEFT w #PPLBSJEF w (FUUIFTUBUVTPGBCPPLFESJEF -
UJQT w γϛϡϨʔλͰςετͰ͖ͳ͍ʢ࣮ػͷΈʣ w 4JSJͪʹΞϓϦͷ&YUFOTJPOΛೝࣝͯ͘͠Εͳ͍ w 4JSJΞϓϦͷ&YUFOTJPOΛ͙͢ʹೝࣝͯ͘͠Εͳ ͍ʢ͔͔Δ͔ʣ w *OGPQMJTUΛमਖ਼ͨ͠Γ͢Δࡍಉ༷
w ઃఆΞϓϦ͔Β4JSJରԠΞϓϦ͕4JSJΛ༻͢Δ͜ͱ ΛڐՄ͢Δඞཁ͕͋Δ -
UJQT w 6OJU5FTUΛॻ͜͏ w *OUFOUͷϞοΫΛ࡞ͬͯ6OJU5FTUΛॻ͘͜ͱ͕Մ ೳʹͳΔ w ϢʔβʔͷೖྗΛ*OUFOUԽ͢Δͷ4JSJʹҕͶΒ Ε͍ͯΔͷͰɺ*OUFOUΛϞοΫʹͯ͠ϩδοΫͷ ςετΛߦ͏
w ԿΑΓͬͯσόοά͢ΔΓͮΒ͞ʢஏ͔ͣ ͠͞ʣΛײ͡Δػձ͕ݮΔʢͣʣ -
import Intents import IntentsExampleKit class IntentHandler: INExtension { override func
handler(for intent: INIntent) -> AnyObject { return IntentExampleHandler() } } -
import Foundation import Intents public final class IntentExampleHandler: NSObject, INStartWorkoutIntentHandling,
INEndWorkoutIntentHandling { public func resolveWorkoutName(forStartWorkout intent: INStartWorkoutIntent, with completion: (INStringResolutionResult) -> Void) { let resolutionResult = INStringResolutionResult.success(with: "Running") completion(resolutionResult) } public func confirm(startWorkout startWorkoutIntent: INStartWorkoutIntent, completion: (INStartWorkoutIntentResponse) -> Void) { let userActivity = NSUserActivity(activityType: NSStringFromClass(INStartWorkoutIntent)) let response = INStartWorkoutIntentResponse(code: .success, userActivity: userActivity) completion(response) } public func handle(startWorkout startWorkoutIntent: INStartWorkoutIntent, completion: (INStartWorkoutIntentResponse) -> Void) { let userActivity = NSUserActivity(activityType: NSStringFromClass(INStartWorkoutIntent)) let response = INStartWorkoutIntentResponse(code: .success, userActivity: userActivity) completion(response) } } -
·ͱΊ w छྨͷ*OUFOUT%PNBJOΛαϙʔτ w 4JSJ͕*OUFOUΦϒδΣΫτʹมͯ͘͠ΕΔ w *OGPQMJTUʹαϙʔτ͢Δ*OUFOUΛهࡌ w 3FTPMWFͰύϥϝʔλͷόϦσʔγϣϯ $POpSNͰ֬ೝɺ
)BOEMFͰλεΫͷ࣮ߦ w *OUFOUΛϋϯυϦϯά͢ΔϩδοΫपΓ&NCFEEFE 'SBNFXPSLʹ࣮ w ͠ΌΒͳ͍ͱߦ͚ͳ͍ͷͰσόοά͕ΓͮΒ͍ ʢஏ͔͍ͣ͠ʣ w 65Λॻ͜͏ -
References • https://developer.apple.com/library/prerelease/content/documentation/Intents/Conceptual/ SiriIntegrationGuide/index.html • https://developer.apple.com/library/prerelease/content/samplecode/UnicornChat/ Introduction/Intro.html#//apple_ref/doc/uid/TP40017332 • https://developer.apple.com/library/prerelease/content/documentation/Intents/Conceptual/ SiriIntegrationGuide/SiriDomains.html#//apple_ref/doc/uid/TP40016875-CH9-SW2
• https://developer.apple.com/reference/intents • https://developer.apple.com/reference/intentsui • https://developer.apple.com/library/prerelease/content/documentation/Intents/Conceptual/ SiriIntegrationGuide/SpecifyingCustomVocabulary.html#//apple_ref/doc/uid/TP40016875- CH6-SW1 • https://developer.apple.com/videos/play/wwdc2016/217/ • https://developer.apple.com/videos/play/wwdc2016/225/