public virtual Response PostOptionalClassProperty(ClassOptionalWrapper bodyParameter = null, CancellationToken cancellationToken = default)
 {
     using var scope = _clientDiagnostics.CreateScope("ExplicitClient.PostOptionalClassProperty");
     scope.Start();
     try
     {
         return(RestClient.PostOptionalClassProperty(bodyParameter, cancellationToken));
     }
     catch (Exception e)
     {
         scope.Failed(e);
         throw;
     }
 }
 public virtual async Task <Response> PostOptionalClassPropertyAsync(ClassOptionalWrapper bodyParameter = null, CancellationToken cancellationToken = default)
 {
     using var scope = _clientDiagnostics.CreateScope("ExplicitClient.PostOptionalClassProperty");
     scope.Start();
     try
     {
         return(await RestClient.PostOptionalClassPropertyAsync(bodyParameter, cancellationToken).ConfigureAwait(false));
     }
     catch (Exception e)
     {
         scope.Failed(e);
         throw;
     }
 }
 /// <summary>
 /// Test explicitly optional complex object. Please put a valid class-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 PostOptionalClassPropertyAsync(this IExplicitModel operations, ClassOptionalWrapper bodyParameter = default(ClassOptionalWrapper), CancellationToken cancellationToken = default(CancellationToken))
 {
     await operations.PostOptionalClassPropertyWithHttpMessagesAsync(bodyParameter, null, cancellationToken).ConfigureAwait(false);
 }
 /// <summary>
 /// Test explicitly optional complex object. Please put a valid class-wrapper
 /// with 'value' = null.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='bodyParameter'>
 /// </param>
 public static void PostOptionalClassProperty(this IExplicitModel operations, ClassOptionalWrapper bodyParameter = default(ClassOptionalWrapper))
 {
     Task.Factory.StartNew(s => ((IExplicitModel)s).PostOptionalClassPropertyAsync(bodyParameter), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult();
 }
 /// <summary>
 /// Test explicitly optional complex object. Please put a valid class-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 PostOptionalClassPropertyAsync( this IExplicitModel operations, ClassOptionalWrapper bodyParameter = default(ClassOptionalWrapper), CancellationToken cancellationToken = default(CancellationToken))
 {
     await operations.PostOptionalClassPropertyWithHttpMessagesAsync(bodyParameter, null, cancellationToken).ConfigureAwait(false);
 }
 /// <summary>
 /// Test explicitly optional complex object. Please put a valid class-wrapper
 /// with 'value' = null.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='bodyParameter'>
 /// </param>
 public static void PostOptionalClassProperty(this IExplicitModel operations, ClassOptionalWrapper bodyParameter = default(ClassOptionalWrapper))
 {
     Task.Factory.StartNew(s => ((IExplicitModel)s).PostOptionalClassPropertyAsync(bodyParameter), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult();
 }