reordered methods in interfaces and implementations

This commit is contained in:
aedampir@gmail.com
2016-06-15 18:24:28 +07:00
parent 7dd5c10945
commit c6ce11d7b4
3 changed files with 42 additions and 42 deletions
@@ -10,6 +10,16 @@ namespace Octokit.Reactive
/// </remarks>
public interface IObservablePullRequestReviewCommentReactionsClient
{
/// <summary>
/// Get all reactions for a specified Pull Request Review Comment.
/// </summary>
/// <remarks>https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="number">The comment id</param>
/// <returns></returns>
IObservable<Reaction> GetAll(string owner, string name, int number);
/// <summary>
/// Creates a reaction for a specified Pull Request Review Comment.
/// </summary>
@@ -20,15 +30,5 @@ namespace Octokit.Reactive
/// <param name="reaction">The reaction to create</param>
/// <returns></returns>
IObservable<Reaction> Create(string owner, string name, int number, NewReaction reaction);
/// <summary>
/// Get all reactions for a specified Pull Request Review Comment.
/// </summary>
/// <remarks>https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="number">The comment id</param>
/// <returns></returns>
IObservable<Reaction> GetAll(string owner, string name, int number);
}
}
@@ -23,6 +23,22 @@ namespace Octokit.Reactive
_connection = client.Connection;
}
/// <summary>
/// Get all reactions for a specified Pull Request Review Comment.
/// </summary>
/// <remarks>https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="number">The comment id</param>
/// <returns></returns>
public IObservable<Reaction> GetAll(string owner, string name, int number)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return _connection.GetAndFlattenAllPages<Reaction>(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), null, AcceptHeaders.ReactionsPreview);
}
/// <summary>
/// Creates a reaction for a specified Pull Request Review Comment.
/// </summary>
@@ -40,21 +56,5 @@ namespace Octokit.Reactive
return _client.Create(owner, name, number, reaction).ToObservable();
}
/// <summary>
/// Get all reactions for a specified Pull Request Review Comment.
/// </summary>
/// <remarks>https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="number">The comment id</param>
/// <returns></returns>
public IObservable<Reaction> GetAll(string owner, string name, int number)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return _connection.GetAndFlattenAllPages<Reaction>(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), null, AcceptHeaders.ReactionsPreview);
}
}
}
@@ -16,6 +16,22 @@ namespace Octokit
{
}
/// <summary>
/// Get all reactions for a specified Pull Request Review Comment.
/// </summary>
/// <remarks>https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="number">The comment id</param>
/// <returns></returns>
public Task<IReadOnlyList<Reaction>> GetAll(string owner, string name, int number)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection.GetAll<Reaction>(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), AcceptHeaders.ReactionsPreview);
}
/// <summary>
/// Creates a reaction for a specified Pull Request Review Comment.
/// </summary>
@@ -33,21 +49,5 @@ namespace Octokit
return ApiConnection.Post<Reaction>(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), reaction, AcceptHeaders.ReactionsPreview);
}
/// <summary>
/// Get all reactions for a specified Pull Request Review Comment.
/// </summary>
/// <remarks>https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="number">The comment id</param>
/// <returns></returns>
public Task<IReadOnlyList<Reaction>> GetAll(string owner, string name, int number)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection.GetAll<Reaction>(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), AcceptHeaders.ReactionsPreview);
}
}
}