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
Objective-C Runtime Swizzle
Search
Wei Wang
November 20, 2014
Programming
0
170
Objective-C Runtime Swizzle
Wei Wang
November 20, 2014
Tweet
Share
More Decks by Wei Wang
See All by Wei Wang
網路之難,難於上青天 - iPlayground 2019
onevcat
11
4.8k
GMTC 2019 - 在分歧中发展,2019 我们能用 Swift 做什么
onevcat
0
880
从 Swift 到机器学习
onevcat
2
920
iOS Dev - The Dark Side
onevcat
0
110
面向协议编程与 Cocoa 的邂逅
onevcat
14
4.7k
Swift 3 - From Expert to Beginner
onevcat
2
210
如何打造一个让人愉快的框架
onevcat
4
22k
JSPatch Introduction
onevcat
0
180
Unity Memory
onevcat
0
130
Other Decks in Programming
See All in Programming
Kaigi on Rails 2024 〜運営の裏側〜
krpk1900
1
190
Webの技術スタックで マルチプラットフォームアプリ開発を可能にするElixirDesktopの紹介
thehaigo
2
1k
Content Security Policy入門 セキュリティ設定と 違反レポートのはじめ方 / Introduction to Content Security Policy Getting Started with Security Configuration and Violation Reporting
uskey512
1
520
Contemporary Test Cases
maaretp
0
130
WebフロントエンドにおけるGraphQL(あるいはバックエンドのAPI)との向き合い方 / #241106_plk_frontend
izumin5210
4
1.4k
RubyLSPのマルチバイト文字対応
notfounds
0
120
見せてあげますよ、「本物のLaravel批判」ってやつを。
77web
7
7.7k
What’s New in Compose Multiplatform - A Live Tour (droidcon London 2024)
zsmb
1
470
ローコードSaaSのUXを向上させるためのTypeScript
taro28
1
610
リアーキテクチャxDDD 1年間の取り組みと進化
hsawaji
1
220
TypeScript Graph でコードレビューの心理的障壁を乗り越える
ysk8hori
2
1.1k
3 Effective Rules for Using Signals in Angular
manfredsteyer
PRO
0
100
Featured
See All Featured
Bash Introduction
62gerente
608
210k
For a Future-Friendly Web
brad_frost
175
9.4k
5 minutes of I Can Smell Your CMS
philhawksworth
202
19k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
10
720
Building Better People: How to give real-time feedback that sticks.
wjessup
364
19k
Bootstrapping a Software Product
garrettdimon
PRO
305
110k
Making Projects Easy
brettharned
115
5.9k
We Have a Design System, Now What?
morganepeng
50
7.2k
The Straight Up "How To Draw Better" Workshop
denniskardys
232
140k
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
Building a Scalable Design System with Sketch
lauravandoore
459
33k
A Modern Web Designer's Workflow
chriscoyier
693
190k
Transcript
0CKFDUJWF$3VOUJNF 4XJ[[MF࣮ફ Ԧቨ
ࣗݾհ w ઌ݄ೖ͔ࣾΓɺલຊདྷͨ w J04։ൃ͙Β͍ɻલ৬6OJUZ% w ࠓ-JOF"ET4%,ͷࣄΛ୲͍ͯ͠Δ w ࠷ۙ"OESPJEษڧத w
IUUQHJUIVCDPNPOFWDBU
Ͳ͏ͯ͠0CKFDUJWF$͕ੜ͖Δ ͔Βɺࠓ·Ͱࡀա͗ɻݴޠʹͷ͓دΓ
None
4NBMM5BML ϝοηʔδૹ৴ 4XJ[[MJOH ϝλݴޠ $ͱ$ ޓ "3$ "TTPDJBUFE 0CKFDU --7.$MBOH
($% ັྗతͳ ॊೈੑ
4XJ[[MJOH
.FUIPE$BMMJOH ClassName *object = [[ClassName alloc] init]; [object doItWithA:a]; objc_msgSend(object,
@selector(doItWithA:), a); %JTQBUDI5BCMF .FUIPE *.1 @selector(doIt) doIt @selector(doItWithA:) doItWithA: - (void)doIt { //... } - (void)doItWithA:(id)a { //... }
.FUIPE4XJ[[MJOH %JTQBUDI5BCMF .FUIPE *.1 @selector(doIt) doIt @selector(doItWithA:) doItWithA: @selector(alt_doItWithA:) alt_doItWithA:
- (void)doIt { //... } - (void)doItWithA:(id)a { //... } - (void)alt_doItWithA:(id)a { //... } EP*U8JUI"ͱBMU@EP*U8JUI"Λ4XJ[[MF͠·͢
.FUIPE4XJ[[MJOH %JTQBUDI5BCMF .FUIPE *.1 @selector(doIt) doIt @selector(doItWithA:) doItWithA: @selector(alt_doItWithA:) alt_doItWithA:
- (void)doIt { //... } - (void)doItWithA:(id)a { //... } - (void)alt_doItWithA:(id)a { //... } EP*U8JUI"ͱBMU@EP*U8JUI"Λ4XJ[[MF͠·͢
.FUIPE4XJ[[MJOH %JTQBUDI5BCMF .FUIPE *.1 @selector(doIt) doIt @selector(doItWithA:) doItWithA: @selector(alt_doItWithA:) alt_doItWithA:
- (void)doIt { //... } - (void)doItWithA:(id)a { //... } - (void)alt_doItWithA:(id)a { //... } *.1Λަ͠·͢
%FNP -JOF"ET4%,ΦϦΤϯςʔγϣϯ
αϚϦʔ w ΫϥεͷϝιουςʔϒϧΛॻ͖͑Δ w ڧྗͰ͋ΔͨΊཚ༻Λආ͚Δ͖ w ඞͣަલͷϝιʔυΛݺͼ·͢ w ΫϥεͷΧςΰϦʔͱ MPBE࿈ܞ͕Φεεϝ
'"2 NBJMXFJXBOH!MJOFDPSQDPN )JQ$IBUPOFWDBU %FNPDPEFIUUQTHJUIVCDPNPOFWDBU-BOETDBQF7JFX$POUSPMMFS%FNP