Swift and scriptingbridge object initialization
问题 I'm trying to write an application for swift control iTunes. But when initializing the application returns an object of type AnyObject , but must iTunesApplication. This object does not respond to methods and variables iTunes. Who knows how to make it work? var iTunes = SBApplication.applicationWithBundleIdentifier("com.apple.iTunes") The iTunes.h header also holds classes that I need to access but cannot. These classes cause a compilation error as if they are not in a declared a iTunes.h.