1

MacOS Swift Project, but would for iOS. I am targeting 10.14

I have an OperationQueue. I want to schedule an operation to run later. Easy enough...

func schedule(after date: OperationQueue.SchedulerTimeType, interval: OperationQueue.SchedulerTimeType.Stride, tolerance: OperationQueue.SchedulerTimeType.Stride, options: OperationQueue.SchedulerOptions?, _ action: @escaping () -> Void) -> Cancellable

Available 10.9

        operQ.schedule(after: .init(restartDate), interval: .zero, tolerance: .zero, options: nil){self.restart("")}

I get the error 'schedule(after:interval:tolerance:options:_:)' is only available in macOS 10.15 or newer

Which I tracked down to combine, which seems to be masking the default implementation.

Screen Shot of the Xcode doc

MongoTheGeek
  • 294
  • 1
  • 10
  • 2
    where do you see 10.9? I see 10.15: https://developer.apple.com/documentation/foundation/operationqueue/3329364-schedule – timbre timbre Aug 18 '20 at 19:41

0 Answers0