예제 #1
0
 /// <summary>
 /// Gets the branch configuration
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='branch'>
 /// The branch name
 /// </param>
 /// <param name='ownerName'>
 /// The name of the owner
 /// </param>
 /// <param name='appName'>
 /// The name of the application
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <BranchConfiguration> GetAsync(this IBranchConfigurations operations, string branch, string ownerName, string appName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(branch, ownerName, appName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
예제 #2
0
 /// <summary>
 /// Configures the branch for build
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='branch'>
 /// The branch name
 /// </param>
 /// <param name='ownerName'>
 /// The name of the owner
 /// </param>
 /// <param name='appName'>
 /// The name of the application
 /// </param>
 public static BranchConfiguration Create(this IBranchConfigurations operations, string branch, string ownerName, string appName)
 {
     return(operations.CreateAsync(branch, ownerName, appName).GetAwaiter().GetResult());
 }
예제 #3
0
 /// <summary>
 /// Deletes the branch build configuration
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='branch'>
 /// The branch name
 /// </param>
 /// <param name='ownerName'>
 /// The name of the owner
 /// </param>
 /// <param name='appName'>
 /// The name of the application
 /// </param>
 public static SuccessResponse Delete(this IBranchConfigurations operations, string branch, string ownerName, string appName)
 {
     return(operations.DeleteAsync(branch, ownerName, appName).GetAwaiter().GetResult());
 }