Search code examples
iosiphone-privateapibridging-headerxcode7.3swift2

Private api CTGetSignalStrength() not working on Xcode 7.3


NSString * CTSIMSupportGetSIMStatus();
int CTGetSignalStrength();

giving compilation error on xcode 7.3 using bridging header in swift, it was working fine on previous versions.


Solution

  • define your own objective-c method like

    + (int)getSignalStrength {
         return CTGetSignalStrength();
    }
    

    and call c style method there, as in xcode7.3 c-style methods in objective-c class not calling.