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
RxSwift, Codable, Moya で API クッキング!
Search
Akio Itaya
April 19, 2018
Technology
0
1.4k
RxSwift, Codable, Moya で API クッキング!
potatotips 50
Akio Itaya
April 19, 2018
Tweet
Share
More Decks by Akio Itaya
See All by Akio Itaya
How to support Privacy Manifest
akkeylab
0
280
Let's make it compatible with visionOS!
akkeylab
0
130
Let's Join the Android community!
akkeylab
0
81
顔写真メイクアップアプリの開発におけるプライバシー保護とコスト削減のための手法
akkeylab
1
260
How to hide the key
akkeylab
0
250
Present and Future of targeted Ad
akkeylab
1
73
iOS team meeting by AppBrew #01
akkeylab
0
81
About published Ad
akkeylab
0
90
me in 2022
akkeylab
0
91
Other Decks in Technology
See All in Technology
BDD(Cucumber)コミュニティが無料提供しているコンテンツの紹介と現在起きている危機
nihonbuson
4
750
Oracle Database で機械学習を始めよう! Oracle Machine Learning
oracle4engineer
PRO
1
140
AFTを運用していたらAWS Configの課金が急増していた件
msato
0
110
私のRSpecの書き方 / How I write RSpec
tmtms
4
840
技術広報として2023年度に頑張ったこと / What we did well in FY2023 as a DevRel
pauli
5
490
イチから学ぶdbt / Learn dbt from scratch
shinyaa31
0
150
Building a RAG app to chat with your data (on Azure)
pamelafox
0
130
長文から長文を生成するLLMツールをオープンソースで作ってみた。
tomohisa
2
150
GraphQLに入門してみた
chiroruxx
2
130
KTC_DBRE.pdf
_awache
1
290
Castor - Symfony Live 2024 - Paris
lyrixx
1
110
統計的学習理論読み Chapter 1
kmatsui
4
970
Featured
See All Featured
Building Applications with DynamoDB
mza
88
5.6k
Designing on Purpose - Digital PM Summit 2013
jponch
109
6.4k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
225
51k
Building a Modern Day E-commerce SEO Strategy
aleyda
15
6.3k
The Cult of Friendly URLs
andyhume
73
5.6k
The Straight Up "How To Draw Better" Workshop
denniskardys
227
130k
From Idea to $5000 a Month in 5 Months
shpigford
376
45k
Build The Right Thing And Hit Your Dates
maggiecrowley
23
1.9k
ParisWeb 2013: Learning to Love: Crash Course in Emotional UX Design
dotmariusz
101
6.6k
Docker and Python
trallard
33
2.6k
Documentation Writing (for coders)
carmenintech
59
3.8k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
1
3.3k
Transcript
AKKEY / AKIO ITAYA Cyberagent, Inc. RxSwift, Codable, Moya API
cookingʂ
໊લɿ൘୩ ߊྑɹ/ɹ͖͋ͬʔʢAKKEYʣ ৬छɿiOS ׆ಈɿ@AkkeyLab Ұݴɿప։ൃޙͷԾதʹίʔσΟϯά͠·ͤΜʁ ࣗݾհ ※ֶੜ࣌ͷݸਓ։ൃʹͯ
ֶੜ࣌ͷݸਓ։ൃ͕ݩͷ͓ ʻ ҙ ʼ
ٕज़બఆ • RxSwift ɹɹʔʼɹKVO ຣফܭըͰͬͱษڧ͍ͨ͠ͱࢥͬͨ • Codable ɹɹʔʼɹApple ७ਖ਼ʹऒ͔Εͯ •
Moya ɹɹʔʼɹAlamofire Λར༻ͯ͠ Rx Ͱॻ͖͔ͨͬͨ
YouTube API Λͨͨ͘
TargetType protocol ڞ௨߲Λ extension Ͱఆٛ Codable
TargetType protocol ↓API ϦΫΤετͷ1ͭˣ Response Λ Codable Ͱࢦఆ
TargetType protocol - MultiTarget Singleton Ͱ provider ։์ʹΑΔ subscribe ෆՄΛࢭ
Singleton
TargetType protocol - MultiTarget Singleton Ͱ provider ։์ʹΑΔ subscribe ෆՄΛࢭ
Singleton TargetType ͷܕʹґଘ͠ͳ͍
TargetType protocol - MultiTarget Singleton Ͱ provider ։์ʹΑΔ subscribe ෆՄΛࢭ
Response Λ subscribe Մೳ Singleton TargetType ͷܕʹґଘ͠ͳ͍
TargetType protocol - MultiTarget Singleton Ͱ provider ։์ʹΑΔ subscribe ෆՄΛࢭ
Response ͷ Json ΛϚοϐϯά Response Λ subscribe Մೳ Singleton TargetType ͷܕʹґଘ͠ͳ͍
Codable ↓API ϦΫΤετͷ1ͭˣ
API ͷݺͼग़͠ Rx ͳॲཧͰγϯϓϧʹهड़Մ औಘ݅
API ͷݺͼग़͠ Rx ͳॲཧͰγϯϓϧʹهड़Մ औಘ݅ ֤छΛར༻ͨ͠ݸਓతͳ࣮
Result YouTube ranking Top 50 !!
࠷ۙͷ͓ؾʹೖΓͰ͢ʢস
GitHub / Qiita : @AkkeyLab
Thank you !!