All Projects → inamiy → Swizzle

inamiy / Swizzle

Licence: MIT license
Method-Swizzling for Swift.

Programming Languages

swift
15916 projects
objective c
16641 projects - #2 most used programming language
ruby
36898 projects - #4 most used programming language
c
50402 projects - #5 most used programming language

Swizzle

Method-Swizzling for Swift.

Example

swizzleInstanceMethod(MyObject.self, from: #selector(MyObject.hello), to: #selector(MyObject.bye))
swizzleInstanceMethodString(MyObject.self, from: "dealloc", to: "_my_dealloc")

swizzleClassMethod(MyObject.self, from: #selector(MyObject.hello), to: #selector(MyObject.bye))
swizzleClassMethodString(MyObject.self, from: "privateObjCClassMethod", to: "myClassMethod")

Licence

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].