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
💥 Custom Playgrounds 🎯
Search
Boris Bügling
June 26, 2014
Technology
1
350
💥 Custom Playgrounds 🎯
Talk on using your own frameworks inside Xcode Playgrounds, given at NSLondon, June 2014.
Boris Bügling
June 26, 2014
Tweet
Share
More Decks by Boris Bügling
See All by Boris Bügling
Testing ⌚️ Apps and Other Extensions
neonichu
1
4.7k
Cross-platform Swift
neonichu
4
18k
Building better API clients in Swift
neonichu
1
310
Cross-platform Swift
neonichu
3
920
Swift Package Manager
neonichu
2
340
Swift Package Manager
neonichu
0
54
📺
neonichu
0
2k
Cross-Platform Swift
neonichu
0
93
Swift Package Manager
neonichu
6
4.4k
Other Decks in Technology
See All in Technology
Observability for LLM Application lifecycle
ivry_presentationmaterials
1
230
S3のライフサイクル設計でハマったポイント
mkumada
0
100
はじめての転職講座/The Guide of First Career Change
kwappa
5
4.5k
生成AI活用のROI、どう測る? DMM.com 開発責任者から学ぶ「AI効果検証のノウハウ」 / ROI of AI
i35_267
4
150
あなたの知らない OneDrive
murachiakira
0
230
Yahoo!広告ビジネス基盤におけるバックエンド開発
lycorptech_jp
PRO
1
230
夢の印税生活 / Life on Royalties
tmtms
0
280
株式会社ARAV 採用案内
maqui
0
240
2025新卒研修・Webアプリケーションセキュリティ #弁護士ドットコム
bengo4com
3
10k
いま、あらためて考えてみるアカウント管理 with IaC / Account management with IaC
kohbis
2
660
AIが住民向けコンシェルジュに?Amazon Connectと生成AIで実現する自治体AIエージェント!
yuyeah
0
260
AIとTDDによるNext.js「隙間ツール」開発の実践
makotot
4
170
Featured
See All Featured
Navigating Team Friction
lara
188
15k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
7
820
Stop Working from a Prison Cell
hatefulcrawdad
271
21k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
Scaling GitHub
holman
462
140k
Reflections from 52 weeks, 52 projects
jeffersonlam
351
21k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.8k
How to train your dragon (web standard)
notwaldorf
96
6.2k
Large-scale JavaScript Application Architecture
addyosmani
512
110k
GitHub's CSS Performance
jonrohan
1031
460k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
33
2.4k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Transcript
! CUSTOM PLAYGROUNDS " NSLONDON, JUNE 2014 BORIS BÜGLING -
@NEONACHO
None
COCOAPODS - CONTENTFUL
SWIFT?
SWIFT!
REPL
$ swift Welcome to Swift! Type :help for assistance. 1>
import ContentfulDeliveryAPI <REPL>:1:8: error: no such module 'ContentfulDeliveryAPI' import ContentfulDeliveryAPI ^
Copy your framework over to /Applications/Xcode6-Beta2.app/ Contents/Developer/Platforms/MacOSX.platform/Developer/ SDKs/MacOSX10.10.sdk/System/Library/Frameworks
1> import ContentfulDeliveryAPI 2> var client = CDAClient() client: CDAClient
= <extracting data from value failed> error: Couldn't lookup symbols: _OBJC_CLASS_$_CDAClient
LOAD THE DYNAMIC LIBRARY FROM YOUR FRAMEWORK USING dlopen()
3> var handle = dlopen("/Applications/.../Versions/A/ContentfulDeliveryAPI", 2) handle: COpaquePointer = Builtin.RawPointer
= 0x0000000102e2b6e0 -> 0x00007fff5fc37e50 vtable for ImageLoaderMachOCompressed + 16 4> var client = CDAClient() client: CDAClient = {}
SUCCESS
// Playground - noun: a place where people can play
None
None
24/06/14 01:00:00,780 Xcode[84816]: IDEPlaygroundExecutionSessionThread(pid=85188) IDEPlaygroundExecution: [PlaygroundSession <0x7fff12750c70>] Received error from
expr: error: error: Couldn't lookup symbols: _OBJC_CLASS_$_CDAClient
None
SAM MARSHALL
None
XCODE PLUGIN?
None
#import <IDELanguageSupportUI/IDEPlaygroundExecutionDeviceService.h> @interface IDELocalComputerPlaygroundExecutionDeviceService : IDEPlaygroundExecutionDeviceService + (id)capability; - (id)sessionForExecutingPlaygroundWithParameters:(id)arg1;
- (id)defaultStubPathForSDK:(id)arg1; @end
DVTPLAYGROUNDCOMMUNICATION.FRAMEWORK @interface DVTPlaygroundCommunicationListener @interface DVTPlaygroundCommunicationSender Uses TCP/IP on the local
machine to communicate between Xcode and Stub
None
None
None
None
None
DEMO
None
XCODE PLUGIN!
RELEVANT WWDC 2014 SESSIONS ▸ Session 408: Swift Playgrounds ▸
Session 409: Introduction to LLDB and the Swift REPL
LINKS ▸ http://samdmarshall.com/blog/ custom_frameworks_and_swift.html ▸ https://github.com/jas/swift-playground-builder ▸ http://stackoverflow.com/questions/24058336/how-do-i-run- asynchronous-callbacks-in-playground
THANK YOU!
HTTP://VU0.ORG/PLAYGROUNDS