public void UniTask() { UniTaskCompletionSource <object> deferred = new UniTaskCompletionSource <object>(); var promise = deferred.Task; for (int i = 0; i < N; ++i) { int index = i; promise = promise .ContinueWith(_ => UniTaskHelper.uniVoids[index].Task) .ContinueWith(() => UniTaskHelper.uniVectors[index].Task) .ContinueWith(_ => UniTaskHelper.uniObjects[index].Task); } promise.Forget(); deferred.TrySetResult(Instances.obj); UniTaskHelper.ResolveCompletionSources(); }
public void CleanupUniTasks() { UniTaskHelper.ClearUniTasks(); }
public void SetupUniTasks() { UniTaskHelper.SetUniTasks(); }
public void CleanupUniTasks() { UniTaskHelper.ClearContinuationSources(); }
public void SetupUniTasks() { UniTaskHelper.SetContinuationSources(N); }
public void UniTask() { _ = AwaitUniTasks(); UniTaskHelper.ResolveCompletionSources(); }