Skip to content

Instantly share code, notes, and snippets.

@tempire
Created June 23, 2015 21:37
Show Gist options
  • Save tempire/bf058e6748333d87ed26 to your computer and use it in GitHub Desktop.
Save tempire/bf058e6748333d87ed26 to your computer and use it in GitHub Desktop.
OperationQueue(
SerialOperation("S1",
SampleOp("op1", timeout: 1),
SampleOp("op2", timeout: 1)
),
ConcurrentOperation("C1",
SampleOp("op3", timeout: 1),
SampleOp("op4", timeout: 1),
ConcurrentOperation("C2",
SampleOp("op5", timeout: 1),
SampleOp("op6", timeout: 1)
)
),
SampleOp("op6", timeout: 1),
BlockOperation { operation in
return true
}
SerialOperation("S1",
SampleOp("op6", timeout: 1),
SampleOp("op7", timeout: 1)
)
).start()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment