mirror of
https://github.com/zoriya/octokit.net.git
synced 2026-06-03 11:05:56 +00:00
added new overloads
This commit is contained in:
@@ -17,6 +17,20 @@ namespace Octokit.Reactive
|
||||
/// <returns>All deployment statuses for the given deployment.</returns>
|
||||
IObservable<DeploymentStatus> GetAll(string owner, string name, int deploymentId);
|
||||
|
||||
/// <summary>
|
||||
/// Gets all the statuses for the given deployment. Any user with pull access to a repository can
|
||||
/// view deployments.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// http://developer.github.com/v3/repos/deployments/#list-deployment-statuses
|
||||
/// </remarks>
|
||||
/// <param name="owner">The owner of the repository.</param>
|
||||
/// <param name="name">The name of the repository.</param>
|
||||
/// <param name="deploymentId">The id of the deployment.</param>
|
||||
/// <param name="options">Options for changing the API response</param>
|
||||
/// <returns>All deployment statuses for the given deployment.</returns>
|
||||
IObservable<DeploymentStatus> GetAll(string owner, string name, int deploymentId, ApiOptions options);
|
||||
|
||||
/// <summary>
|
||||
/// Creates a new status for the given deployment. Users with push access can create deployment
|
||||
/// statuses for a given deployment.
|
||||
|
||||
@@ -33,8 +33,29 @@ namespace Octokit.Reactive.Clients
|
||||
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
|
||||
Ensure.ArgumentNotNullOrEmptyString(name, "name");
|
||||
|
||||
return GetAll(owner, name, deploymentId, ApiOptions.None);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets all the statuses for the given deployment. Any user with pull access to a repository can
|
||||
/// view deployments.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// http://developer.github.com/v3/repos/deployments/#list-deployment-statuses
|
||||
/// </remarks>
|
||||
/// <param name="owner">The owner of the repository.</param>
|
||||
/// <param name="name">The name of the repository.</param>
|
||||
/// <param name="deploymentId">The id of the deployment.</param>
|
||||
/// <param name="options">Options for changing the API response</param>
|
||||
/// <returns>All deployment statuses for the given deployment.</returns>
|
||||
public IObservable<DeploymentStatus> GetAll(string owner, string name, int deploymentId, ApiOptions options)
|
||||
{
|
||||
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
|
||||
Ensure.ArgumentNotNullOrEmptyString(name, "name");
|
||||
Ensure.ArgumentNotNull(options, "options");
|
||||
|
||||
return _connection.GetAndFlattenAllPages<DeploymentStatus>(
|
||||
ApiUrls.DeploymentStatuses(owner, name, deploymentId));
|
||||
ApiUrls.DeploymentStatuses(owner, name, deploymentId), options);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -33,7 +33,28 @@ namespace Octokit
|
||||
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
|
||||
Ensure.ArgumentNotNullOrEmptyString(name, "name");
|
||||
|
||||
return ApiConnection.GetAll<DeploymentStatus>(ApiUrls.DeploymentStatuses(owner, name, deploymentId));
|
||||
return GetAll(owner, name, deploymentId, ApiOptions.None);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets all the statuses for the given deployment. Any user with pull access to a repository can
|
||||
/// view deployments.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// http://developer.github.com/v3/repos/deployments/#list-deployment-statuses
|
||||
/// </remarks>
|
||||
/// <param name="owner">The owner of the repository.</param>
|
||||
/// <param name="name">The name of the repository.</param>
|
||||
/// <param name="deploymentId">The id of the deployment.</param>
|
||||
/// <param name="options">Options for changing the API response</param>
|
||||
/// <returns>All deployment statuses for the given deployment.</returns>
|
||||
public Task<IReadOnlyList<DeploymentStatus>> GetAll(string owner, string name, int deploymentId, ApiOptions options)
|
||||
{
|
||||
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
|
||||
Ensure.ArgumentNotNullOrEmptyString(name, "name");
|
||||
Ensure.ArgumentNotNull(options, "options");
|
||||
|
||||
return ApiConnection.GetAll<DeploymentStatus>(ApiUrls.DeploymentStatuses(owner, name, deploymentId), options);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -25,6 +25,20 @@ namespace Octokit
|
||||
/// <returns>All deployment statuses for the given deployment.</returns>
|
||||
Task<IReadOnlyList<DeploymentStatus>> GetAll(string owner, string name, int deploymentId);
|
||||
|
||||
/// <summary>
|
||||
/// Gets all the statuses for the given deployment. Any user with pull access to a repository can
|
||||
/// view deployments.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// http://developer.github.com/v3/repos/deployments/#list-deployment-statuses
|
||||
/// </remarks>
|
||||
/// <param name="owner">The owner of the repository.</param>
|
||||
/// <param name="name">The name of the repository.</param>
|
||||
/// <param name="deploymentId">The id of the deployment.</param>
|
||||
/// <param name="options">Options for changing the API response</param>
|
||||
/// <returns>All deployment statuses for the given deployment.</returns>
|
||||
Task<IReadOnlyList<DeploymentStatus>> GetAll(string owner, string name, int deploymentId, ApiOptions options);
|
||||
|
||||
/// <summary>
|
||||
/// Creates a new status for the given deployment. Users with push access can create deployment
|
||||
/// statuses for a given deployment.
|
||||
|
||||
Reference in New Issue
Block a user