Slide 14
Slide 14 text
import Foundation
import XcodeKit
class SourceEditorCommand: NSObject, XCSourceEditorCommand {
func perform(with invocation: XCSourceEditorCommandInvocation,
completionHandler: (NSError?) -> Void ) -> Void {
// Implement your command here, invoking the completion handler when
done. Pass it nil on success, and an NSError on failure.
completionHandler(nil)
}
}