using System; using System.Diagnostics.CodeAnalysis; namespace Octokit.Reactive { /// /// A client for GitHub's Pull Requests API. /// /// /// See the Pull Requests API documentation for more information. /// public interface IObservablePullRequestsClient { /// /// Client for managing comments. /// IObservablePullRequestReviewCommentsClient Comment { get; } /// /// Gets a single Pull Request by number. /// /// /// http://developer.github.com/v3/pulls/#get-a-single-pull-request /// /// The owner of the repository /// The name of the repository /// The number of the pull request [SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId = "Get", Justification = "Method makes a network request")] IObservable Get(string owner, string name, int number); /// /// Gets a single Pull Request by number. /// /// /// http://developer.github.com/v3/pulls/#get-a-single-pull-request /// /// The Id of the repository /// The number of the pull request [SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId = "Get", Justification = "Method makes a network request")] IObservable Get(int repositoryId, int number); /// /// Gets all open pull requests for the repository. /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The owner of the repository /// The name of the repository IObservable GetAllForRepository(string owner, string name); /// /// Gets all open pull requests for the repository. /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The Id of the repository IObservable GetAllForRepository(int repositoryId); /// /// Gets all open pull requests for the repository. /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The owner of the repository /// The name of the repository /// Options for changing the API response IObservable GetAllForRepository(string owner, string name, ApiOptions options); /// /// Gets all open pull requests for the repository. /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The Id of the repository /// Options for changing the API response IObservable GetAllForRepository(int repositoryId, ApiOptions options); /// /// Query pull requests for the repository based on criteria /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The owner of the repository /// The name of the repository /// Used to filter and sort the list of pull requests returned IObservable GetAllForRepository(string owner, string name, PullRequestRequest request); /// /// Query pull requests for the repository based on criteria /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The Id of the repository /// Used to filter and sort the list of pull requests returned IObservable GetAllForRepository(int repositoryId, PullRequestRequest request); /// /// Query pull requests for the repository based on criteria /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The owner of the repository /// The name of the repository /// Used to filter and sort the list of pull requests returned /// Options for changing the API response IObservable GetAllForRepository(string owner, string name, PullRequestRequest request, ApiOptions options); /// /// Query pull requests for the repository based on criteria /// /// /// http://developer.github.com/v3/pulls/#list-pull-requests /// /// The Id of the repository /// Used to filter and sort the list of pull requests returned /// Options for changing the API response IObservable GetAllForRepository(int repositoryId, PullRequestRequest request, ApiOptions options); /// /// Creates a pull request for the specified repository. /// /// http://developer.github.com/v3/pulls/#create-a-pull-request /// The owner of the repository /// The name of the repository /// A instance describing the new PullRequest to create IObservable Create(string owner, string name, NewPullRequest newPullRequest); /// /// Creates a pull request for the specified repository. /// /// http://developer.github.com/v3/pulls/#create-a-pull-request /// The Id of the repository /// A instance describing the new PullRequest to create IObservable Create(int repositoryId, NewPullRequest newPullRequest); /// /// Update a pull request for the specified repository. /// /// http://developer.github.com/v3/pulls/#update-a-pull-request /// The owner of the repository /// The name of the repository /// The PullRequest number /// An instance describing the changes to make to the PullRequest /// IObservable Update(string owner, string name, int number, PullRequestUpdate pullRequestUpdate); /// /// Update a pull request for the specified repository. /// /// http://developer.github.com/v3/pulls/#update-a-pull-request /// The Id of the repository /// The PullRequest number /// An instance describing the changes to make to the PullRequest /// IObservable Update(int repositoryId, int number, PullRequestUpdate pullRequestUpdate); /// /// Merge a pull request. /// /// http://developer.github.com/v3/pulls/#merge-a-pull-request-merge-buttontrade /// The owner of the repository /// The name of the repository /// The pull request number /// A instance describing a pull request merge IObservable Merge(string owner, string name, int number, MergePullRequest mergePullRequest); /// /// Merge a pull request. /// /// http://developer.github.com/v3/pulls/#merge-a-pull-request-merge-buttontrade /// The Id of the repository /// The pull request number /// A instance describing a pull request merge IObservable Merge(int repositoryId, int number, MergePullRequest mergePullRequest); /// /// Gets the pull request merge status. /// /// http://developer.github.com/v3/pulls/#get-if-a-pull-request-has-been-merged /// The owner of the repository /// The name of the repository /// The pull request number IObservable Merged(string owner, string name, int number); /// /// Gets the pull request merge status. /// /// http://developer.github.com/v3/pulls/#get-if-a-pull-request-has-been-merged /// The Id of the repository /// The pull request number IObservable Merged(int repositoryId, int number); /// /// Gets the list of commits on a pull request. /// /// http://developer.github.com/v3/pulls/#list-commits-on-a-pull-request /// The owner of the repository /// The name of the repository /// The pull request number IObservable Commits(string owner, string name, int number); /// /// Gets the list of commits on a pull request. /// /// http://developer.github.com/v3/pulls/#list-commits-on-a-pull-request /// The Id of the repository /// The pull request number IObservable Commits(int repositoryId, int number); /// /// Get the list of files on a pull request. /// /// https://developer.github.com/v3/pulls/#list-pull-requests-files /// The owner of the repository /// The name of the repository /// The pull request number IObservable Files(string owner, string name, int number); /// /// Get the list of files on a pull request. /// /// https://developer.github.com/v3/pulls/#list-pull-requests-files /// The Id of the repository /// The pull request number IObservable Files(int repositoryId, int number); } }