Monday 15 September 2014

ios - Access SpringBoardServices.h method in objective-c? -



ios - Access SpringBoardServices.h method in objective-c? -

i downloaded springboardservices.h file given in springboardservices , added project. how access 1 of method nowadays within springboardservices.h file. trying phone call bool sbsprocessidfordisplayidentifier(cfstringref identifier, pid_t *pid); method nowadays within springboardservices.h myclass.m file. how phone call above method .m file?

i used below approach, returning null. class myclass = nsclassfromstring(@"springboardservices"); nslog(@" myclass %@", myclass); //null id myobj = [[myclass alloc] init];

i downloaded springboardservices.h file link.

there couple of methods access c methods private framework:

method 1:

link private framework (similar way how link public framework) include .h file do call:

sbsprocessidfordisplayidentifier(...)

method 2:

load framework in runtime using dlopen find method using dlsym do call

btw. applicable c method's , sec method won't work objectivec methods.

ios objective-c iphone-privateapi

No comments:

Post a Comment