I am trying to convert:
NSString * helperName = @"de.mdenkmann.Xpc-Exchange”;
CFDictionaryRef diref = SMJobCopyDictionary( kSMDomainSystemLaunchd,
(__bridge CFStringRef)helperName );
NSDictionary *jobDict = (NSDictionary *)CFBridgingRelease(diref);
if ( jobDict == nil ) need to start the helper
to Swift:
let name = xpcServiceName!
let diref = SMJobCopyDictionary( kSMDomainSystemLaunchd, name )
but get an error for name: "'NSString' is not a subtype of 'CFString'"
let cref = CFString(name) → error: 'CFString' cannot be constructed
because it has no accessible initializers
How to get a CFString?
Gerriet.
_______________________________________________
Cocoa-dev mailing list ([email protected])
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to [email protected]