Skip to content

Instantly share code, notes, and snippets.

@berikv
Created August 7, 2025 11:43
Show Gist options
  • Select an option

  • Save berikv/71e890cb561efebe2960a2e3ffba9bd1 to your computer and use it in GitHub Desktop.

Select an option

Save berikv/71e890cb561efebe2960a2e3ffba9bd1 to your computer and use it in GitHub Desktop.
List the runtime (hidden) methods of an objc object
let clazz: AnyClass = UIDocumentInteractionController.self // <- Replace the class name with the class you want to get the methods of
var count: UInt32 = 0
if let methods = class_copyMethodList(clazz, &count) {
for i in 0..<Int(count) {
let sel = method_getName(methods[i])
print(NSStringFromSelector(sel))
}
free(methods)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment