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
ユーザインターフェイスと非同期処理
Search
cockscomb
May 15, 2018
Programming
5
1.8k
ユーザインターフェイスと非同期処理
Presented at Bonfire iOS #4
cockscomb
May 15, 2018
Tweet
Share
More Decks by cockscomb
See All by cockscomb
jq at the Shortcuts
cockscomb
1
1.8k
GraphQL放談
cockscomb
4
2k
GraphQL Highway
cockscomb
28
8.4k
吉田を支える技術
cockscomb
0
2.3k
コーポレートサイトを静的化してAmplify Consoleにデプロイする
cockscomb
0
3.4k
GUIアプリケーションの構造と設計
cockscomb
10
10k
イカリング2におけるシングルページアプリケーション
cockscomb
2
7.5k
あなたの知らない UIKit の世界 — UITableView に UITextView を置きたい
cockscomb
1
7.4k
iOSアプリエンジニアのためのAndroidアプリ開発
cockscomb
7
1.9k
Other Decks in Programming
See All in Programming
マルチアカウント環境での、そこまでがんばらない RI/SP 運用設計
wa6sn
0
570
requirements with math
moony
0
520
Compose Navigation実装の見通しを良くする
hiroaki404
0
180
今から始めるCursor / Windsurf / Cline
kengo_hayano
0
110
2025/3/18 サービスの成長で生じる幅広いパフォーマンスの問題を、 AIで手軽に解決する
shirahama_x
0
160
Devin , 正しい付き合い方と使い方 / Living and Working with Devin
yukinagae
1
520
아직도 SOLID 를 '글'로만 알고 계신가요?
sh1mj1
0
360
JavaOne 2025: Advancing Java Profiling
jbachorik
1
310
ローコードサービスの進化のためのモノレポ移行
taro28
1
330
Firebase Dynamic Linksの代替手段を自作する / Create your own Firebase Dynamic Links alternative
kubode
0
180
remix + cloudflare workers (DO) docker上でいい感じに開発する
yoshidatomoaki
0
120
CTFのWebにおける⾼難易度問題について
hamayanhamayan
1
970
Featured
See All Featured
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
25k
Code Review Best Practice
trishagee
67
18k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
4
490
Building a Modern Day E-commerce SEO Strategy
aleyda
39
7.2k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
32
2.2k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.1k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
8
700
How to Think Like a Performance Engineer
csswizardry
22
1.5k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
30
2.3k
How STYLIGHT went responsive
nonsquared
99
5.4k
Transcript
ϢʔβΠϯλʔϑΣΠεͱ ඇಉظॲཧ
id:cockscomb Ճ౻ਘथ גࣜձࣾͯͳ γχΞΞϓϦέʔγϣϯΤϯδχΞ
ࡢࠓ w (PPHMF*0Ͳ͏Ͱ͔ͨ͠ʁ w 88%$͕͍͖ۙͮͯ·ͨ͠Ͷ w ͳʹ͕ൃද͞ΕΔָ͔͠ΈͰ͢Ͷ w Έͳ͞ΜͲΜͳظΛ͍࣋ͬͯ·͔͢ʁ w
88%$Ͳ͏Ͱ͚ͨͬ͠
J04 w "3,JU$PSF.- w 6*,JU w %SBHBOE%SPQ w 'JMFT
J04ͷ֓ཁ Ӭٱ "3,JU అमҰ $PSF.-
٢ా༔Ұ 4XJGUͷ৽ػೳͱΞοϓσʔτ ాᠳ 9DPEFͷ৽ػೳ ࡔాߊҰ %SBHBOE%SPQ Ճ౻ਘथ 'JMFTͱ%PDVNFOU#BTFE"QQMJDBUJPO Ճ౻ਘथ 6*,JUͷΨΠυϥΠϯͷมߋͱ "VUP-BZPVUͷ৽ػೳɺΞοϓσʔτᬒ༤հ $PSF/'$ ؛ࠀݾ 1%',JU ؛ࠀݾ 4JSJ,JU ؛ࠀݾ )PNF,JUೖͱJ04ʹ͓͚Δ৽ػೳ ॴ༑ଠ .FUBM అमҰ "VEJP.FEJBؔ࿈ ৽ϑϨʔϜϫʔΫͱΞοϓσʔτ Ӭٱ
63-4FTTJPO5BTL open class URLSessionTask : NSObject, NSCopying, ProgressReporting { @available(iOS
11.0, *) open var progress: Progress { get } }
public protocol ProgressReporting : NSObjectProtocol { public var progress: Progress
{ get } }
%SBHBOE%SPQ open class NSItemProvider : NSObject, NSCopying { @available(iOS 11.0,
*) open func registerDataRepresentation(forTypeIdentifier typeIdentifier: String, visibility: NSItemProviderRepresentationVisibility, loadHandler: @escaping ((Data?, Error?) -> Swift.Void) -> Progress?) }
None
1SPHSFTT3FQPSUJOH w ඇಉظॲཧͷঢ়گΛϢʔβΠϯλʔϑΣΠεʹөͰ͖Δ w "DUJWJUZ*OEJDBUPS1SPHSFTT#BSΛදࣔ͢ΔͱΑ͍ w l)VNBO*OUFSGBDF(VJEFMJOFTr1SPHSFTT*OEJDBUPSTzΑΓ w ݱࡏͷ3Y4XJGUͰѻ͏ͷ͍͠
<2>ͳͥඇಉظʹ͢Δͷʁ
None
<2>ͳͥඇಉظʹ͢Δͷʁ ϝΠϯεϨουͷ3VO-PPQΛࢭΊͨ͘ͳ͍͔Β ࢭΊͯ͠·͏ͱΧΫΧΫ͢Δ
<2>ΈΜͳͲ͏ͯ͠Δʁ
3FBDUlTVTQFOTFz const movieDetailsFetcher = createFetcher( fetchMovieDetails ) const MovieDetails: React.SFC<MovieDetailsProps>
= ({id}) => { const movie = movieDetailsFetcher.read(id) return ( <div className="MovieDetails"> <MoviePoster src={movie.poster} /> <h1>{movie.title}</h1> <MovieMetrics {...movie} /> </div> ) }
'MVUUFS w 3FBDUʹΠϯεύΠΞ w %BSUΛ͏
Future<AtomFeed> fetchAtom(String atomUrl) async { var atomXml = await http.read(atomUrl);
return parse(atomXml); } class Feed extends StatelessWidget { final String url; const Feed({Key key, this.url}) : super(key: key); @override Widget build(BuildContext context) { var entries = new FutureBuilder<AtomFeed>( future: fetchAtom(url), builder: (context, snapshot) { if (snapshot.hasData) { var feed = snapshot.data; return new Entries(feed: feed); } else if (snapshot.hasError) { return new Text("${snapshot.error}"); } return new CircularProgressIndicator(); }); return new Scaffold( appBar: new AppBar(title: new Text("Feed")), body: entries, ); } }
w એݴతͳ6*ϑϨʔϜϫʔΫ͕ྲྀߦ w 3FBDU 'MVUUFS w ඇಉظॲཧΛѻ͍͘͢͢ΔΈ w 3FBDUͷTVTQFOTF w
'MVUUFSͷ'VUVSF#VJMEFS w .BS[JQBOͲ͏ͳΔʁ
.BS[JQBO w Ͳ͏͍͏ͷ͔ w 6*,JUͷҠ২ʁ w ৽͍͠6*ϑϨʔϜϫʔΫʁ w 4XJGUͱͷੑ w
ͦͦൃද͞ΕΔͷ͔