Exemplo n.º 1
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <string> GetValueAsync(this IApiSwaggerAndMvc operations, int id, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetValueWithHttpMessagesAsync(id, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemplo n.º 2
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// </param>
 /// <param name='value'>
 /// </param>
 public static void UpdateValue(this IApiSwaggerAndMvc operations, int id, string value = default(string))
 {
     operations.UpdateValueAsync(id, value).GetAwaiter().GetResult();
 }
Exemplo n.º 3
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// </param>
 public static string GetValue(this IApiSwaggerAndMvc operations, int id)
 {
     return(operations.GetValueAsync(id).GetAwaiter().GetResult());
 }
Exemplo n.º 4
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='value'>
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task AddValueAsync(this IApiSwaggerAndMvc operations, string value = default(string), CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.AddValueWithHttpMessagesAsync(value, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
Exemplo n.º 5
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='value'>
 /// </param>
 public static void AddValue(this IApiSwaggerAndMvc operations, string value = default(string))
 {
     operations.AddValueAsync(value).GetAwaiter().GetResult();
 }
Exemplo n.º 6
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 public static IList <string> GetValues(this IApiSwaggerAndMvc operations)
 {
     return(operations.GetValuesAsync().GetAwaiter().GetResult());
 }
Exemplo n.º 7
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task DeleteValueAsync(this IApiSwaggerAndMvc operations, int id, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.DeleteValueWithHttpMessagesAsync(id, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
Exemplo n.º 8
0
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// </param>
 public static void DeleteValue(this IApiSwaggerAndMvc operations, int id)
 {
     operations.DeleteValueAsync(id).GetAwaiter().GetResult();
 }