private void PackageClient_OnPushApplicationPackage(string filename, RemoteTaskCompletionSource taskHandle) { var packageRequest = new ApplicationPackagePushRequest { Filename = filename, }; Transceiver.Send(packageRequest) .GetResponseAsync() .ContinueWith(taskHandle.FromTask); }
private void PackageClient_OnPushApplicationPackage(string filename, RemoteTaskCompletionSource <object> taskHandle) { Task.Run(async() => { var packageRequest = new ApplicationPackagePushRequest { Filename = filename, }; await Transceiver.Send(packageRequest) .GetResponseAsync(); return((object)null); }).ContinueWith(taskHandle.FromTask); }