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
WWDCに学ぶライブコーディングwithCoreNFC/livecoding_with_wwd...
Search
fromkk
June 30, 2017
Programming
2
3.2k
WWDCに学ぶライブコーディングwithCoreNFC/livecoding_with_wwdc_and_corenfc
LIFULLさんのWWDC - Developer's Livingというイベントで発表した内容です。
fromkk
June 30, 2017
Tweet
Share
More Decks by fromkk
See All by fromkk
note社の全員野球で品質向上活動について / note_qa_challenge #iOS_test_teatime
fromkk
3
1.8k
1年分のデータが見たいと言われてやったこと/yearly_data_with_note
fromkk
0
920
note iOSチームの自動化 ver.2021/automation_with_iOS_team_on_note_ver2021
fromkk
0
1.9k
Bitrise体験会説明資料/bitrise_explore
fromkk
1
1k
noteのiOSアプリで実装したアクセシビリティの全て #iosdc #a /a11y_with_iOS_App_on_note
fromkk
2
3.5k
dSYMのアップロードで SPMを活用する/use_spm_with_upload_dsyms
fromkk
1
2.7k
Bitriseのリモートアクセス機能 #bitrise_meetup/remote_access_of_bitrise
fromkk
1
550
note社でのMagic Pod活用事例 #af_iosdc/magicpod_with_note
fromkk
2
11k
iOSには無いmacOS独自機能をCatalystで実装する #iosdc #d/make_macos_apps_with_catalyst
fromkk
9
2.1k
Other Decks in Programming
See All in Programming
富山発の個人開発サービスで日本中の学校の業務を改善した話
krpk1900
4
380
負債になりにくいCSSをデザイナとつくるには?
fsubal
9
2.4k
Open source software: how to live long and go far
gaelvaroquaux
0
630
AWS Lambda functions with C# 用の Dev Container Template を作ってみた件
mappie_kochi
0
240
法律の脱レガシーに学ぶフロントエンド刷新
oguemon
5
730
個人アプリを2年ぶりにアプデしたから褒めて / I just updated my personal app, praise me!
lovee
0
340
ARA Ansible for the teams
kksat
0
150
DROBEの生成AI活用事例 with AWS
ippey
0
130
SRE、開発、QAが協業して挑んだリリースプロセス改革@SRE Kaigi 2025
nealle
3
4.2k
ソフトウェアエンジニアの成長
masuda220
PRO
10
920
第3回 Snowflake 中部ユーザ会- dbt × Snowflake ハンズオン
hoto17296
4
370
Boost Performance and Developer Productivity with Jakarta EE 11
ivargrimstad
0
120
Featured
See All Featured
Designing Experiences People Love
moore
139
23k
[RailsConf 2023] Rails as a piece of cake
palkan
53
5.2k
Practical Orchestrator
shlominoach
186
10k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.2k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
114
50k
Building a Modern Day E-commerce SEO Strategy
aleyda
38
7.1k
Typedesign – Prime Four
hannesfritz
40
2.5k
Embracing the Ebb and Flow
colly
84
4.6k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
49k
Building an army of robots
kneath
302
45k
Being A Developer After 40
akosma
89
590k
Transcript
WWDCʹֶͿϥΠϒίʔ σΟϯά (+CoreNFC) WWDC - Developer's Living 2017/06/30 1
Profile Kazuya Ueoka Timers inc.ͷiOSΤϯδχΞ Twitter: @fromkk Github: fromkk Qiita:
fromkk 2
օ͞Μ͏WWDCͰൃද ͞Εͨ৽ػೳνΣοΫ ͯ͠·͢ΑͶʁ 3
طʹຊޠͰͷࢿྉ͔ ͳΓଟ͍ͷͰԿൃද͢Ε ྑ͍Μͩ 4
͍͔ͭ͘ൃද͖ͯ͠·ͨ͠ 4 Swift 4͔Β࣮͞ΕΔCodable at AKIBA.swift 4 # Type ʹDrag
and Dropͷ࣮Λͯ͠Έͨ at WWDC After Party @Ebisu 4 Depth APIͰ؆қΫϩϚΩʔ߹ at GEEK GARAGE iOS vol3 5
͕ 6
ϥΠϒίʔσΟϯάͬͯ ϋʔυϧߴ͍ 7
۩ମతʹ 4 ొஃͬͯۓு͢Δ 4 ϛε͖ͭͷ 4 ൃද͢Δ͔Βʹ͏·͘Γ͍ͨ 8
ϥΠϒίʔσΟϯά͢Δ࣌ͬͯ 4 Ұ୴खݩͷXcodeͰͤ͞Δ 4 ͍ͨ͠༰ʹԊͬͯଞͷςΩετΤσΟλʹΧοτˍ ϖʔετ 4 ొஃ͢Δ࣌ʹॱ൪ʹίϐϖ Έ͍ͨͳΠϝʔδʢθϩ͔Βॻ͍͍ͯΔํଞͷํ๏ͷํ ͨ͘͞Μ͍Βͬ͠Ό͍·͢ʣ
9
WWDCϥΠϒίʔσΟϯάͰͷൃදͷๅݿ Ή͠Ζ͜ΜͳʹϥΠϒίʔσΟϯάͷൃද͕ଟ͍ΧϯϑΝϨϯ ε͍͠ؾ͕͢Δ 10
ͦͷதͰ 227 Data Delivery with Drag and Drop ͷTanu Singhal͞ΜͷϥΠϒίʔσΟϯάͷํ๏ʹײΛड
͚ͨͷͰհ͠·͢ 11
ख๏؆୯ 12
ίϝϯτʹ൪߸ΛৼͬͯίʔυεχϖοτͷγϣʔτΧοτʹಉ͡൪߸Λৼ͓͚ͬͯͩ͘ 13
Xcodeͷίʔυεχϖοτͷొํ ๏ 4 ͍͔ͭ͋͘Δ͕ઌʹίʔυΛॻ͍ͯίʔυεχϖοτͷ ॴʹυϥοά&υϩοϓ͕؆୯ 4 Completion shortcut Λઃఆ͢Εݺͼग़͠؆୯ 14
͓·͚ 15
CoreNFC 4 WWDCظؒதεέδϡʔϧʹະܝࡌ͕ͩηογϣϯಈը ͷΈެ։ 4 iOS 11͔Βղ์͞ΕͨಡΈऔΓͷػೳͷΈͷframework 4 ରԠܗࣜ: NDEF
4 λά1ʙ5ʹରԠ 4 ݱ࣌ͰiPhone 7ͱ7 PlusͷΈରԠ 16
ར༻ํ๏ 4 iTunes ConnectͰAppIDͷNFC Tag ReadingΛONʹ͢ Δ 17
ར༻ํ๏ 4 EntitlementsʹҎԼΛՃ <key>com.apple.developer.nfc.readersession.formats</key> <array> <string>NDEF</string> </array> 18
ར༻ํ๏ 4 Info.plistʹҎԼΛՃͯ͠ϢʔβʔʹڐՄΛಘΔ <key>NFCReaderUsageDescription</key> <string>Scan NFC tags message!</string> 19
ར༻ํ๏ import CoreNFC let session = NFCNDEFReaderSession(delegate: self, queue: nil,
invalidateAfterFirstRead: true) session.begin() 20
ར༻ํ๏ extension NFCViewController: NFCNDEFReaderSessionDelegate { func readerSession(_ session: NFCNDEFReaderSession, didDetectNDEFs
messages: [NFCNDEFMessage]) { messages.forEach { (message) in message.records.forEach { let payload: String = String(data: $0.payload, encoding: .utf8) ?? "" print("payload", payload) } } } func readerSession(_ session: NFCNDEFReaderSession, didInvalidateWithError error: Error) { print(error) } } 21
Recap 4 ϥΠϒίʔσΟϯάʹXcodeͷίʔυεχϖοτΛ׆༻ ! 4 ίϝϯτʹॱ൪Λهࡌͯ͠ίʔυεχϖοτͷγϣʔτ Χοτͱ߹ΘͤΔͱϛε͠ʹ͍͘" 4 ίϝϯτΛಡΉ͚ͩͰ؆୯ͳઆ໌͕ग़དྷΔ# 4
CoreNFCλάΛಡΉ͚ͩͳΒ؆୯$ 22
͜ΕͰϥΠϒίʔσΟϯάා͘ͳ͍! 23
͝ਗ਼ௌ͋Γ͕ͱ͏͍͟͝·ͨ͠! 24