/// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='model'> /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <ResQYttriumWebApiModelsCreateDriverAssistServiceResultModel> CreateAsync(this IDriverAssistService operations, ResQYttriumWebApiModelsCreateDriverAssistServiceModel model, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.CreateWithHttpMessagesAsync(model, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='model'> /// </param> public static ResQYttriumWebApiModelsCreateDriverAssistServiceResultModel Create(this IDriverAssistService operations, ResQYttriumWebApiModelsCreateDriverAssistServiceModel model) { return(Task.Factory.StartNew(s => ((IDriverAssistService)s).CreateAsync(model), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult()); }