public virtual Response PostOptionalIntegerProperty(IntOptionalWrapper bodyParameter = null, CancellationToken cancellationToken = default) { using var scope = _clientDiagnostics.CreateScope("ExplicitClient.PostOptionalIntegerProperty"); scope.Start(); try { return(RestClient.PostOptionalIntegerProperty(bodyParameter, cancellationToken)); } catch (Exception e) { scope.Failed(e); throw; } }
public virtual async Task <Response> PostOptionalIntegerPropertyAsync(IntOptionalWrapper bodyParameter = null, CancellationToken cancellationToken = default) { using var scope = _clientDiagnostics.CreateScope("ExplicitClient.PostOptionalIntegerProperty"); scope.Start(); try { return(await RestClient.PostOptionalIntegerPropertyAsync(bodyParameter, cancellationToken).ConfigureAwait(false)); } catch (Exception e) { scope.Failed(e); throw; } }
/// <summary> /// Test explicitly optional integer. Please put a valid int-wrapper with /// 'value' = null. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='bodyParameter'> /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task PostOptionalIntegerPropertyAsync(this IExplicitModel operations, IntOptionalWrapper bodyParameter = default(IntOptionalWrapper), CancellationToken cancellationToken = default(CancellationToken)) { await operations.PostOptionalIntegerPropertyWithHttpMessagesAsync(bodyParameter, null, cancellationToken).ConfigureAwait(false); }
/// <summary> /// Test explicitly optional integer. Please put a valid int-wrapper with /// 'value' = null. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='bodyParameter'> /// </param> public static void PostOptionalIntegerProperty(this IExplicitModel operations, IntOptionalWrapper bodyParameter = default(IntOptionalWrapper)) { Task.Factory.StartNew(s => ((IExplicitModel)s).PostOptionalIntegerPropertyAsync(bodyParameter), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); }
/// <summary> /// Test explicitly optional integer. Please put a valid int-wrapper with /// 'value' = null. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='bodyParameter'> /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task PostOptionalIntegerPropertyAsync( this IExplicitModel operations, IntOptionalWrapper bodyParameter = default(IntOptionalWrapper), CancellationToken cancellationToken = default(CancellationToken)) { await operations.PostOptionalIntegerPropertyWithHttpMessagesAsync(bodyParameter, null, cancellationToken).ConfigureAwait(false); }
/// <summary> /// Test explicitly optional integer. Please put a valid int-wrapper with /// 'value' = null. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='bodyParameter'> /// </param> public static void PostOptionalIntegerProperty(this IExplicitModel operations, IntOptionalWrapper bodyParameter = default(IntOptionalWrapper)) { Task.Factory.StartNew(s => ((IExplicitModel)s).PostOptionalIntegerPropertyAsync(bodyParameter), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); }