Adds overloads for adding custom timeouts

This commit is contained in:
William Barbosa
2015-09-29 22:53:13 -03:00
parent 1266ac0f3a
commit b6864c2cbf
4 changed files with 110 additions and 2 deletions

View File

@@ -96,6 +96,30 @@ namespace Octokit.Reactive
/// <returns>A promise, containing the binary contents of the archive</returns>
IObservable<byte[]> GetArchive(string owner, string name, ArchiveFormat archiveFormat, string reference);
/// <summary>
/// Get an archive of a given repository's contents, in a specific format
/// </summary>
/// <remarks>https://developer.github.com/v3/repos/contents/#get-archive-link</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="archiveFormat">The format of the archive. Can be either tarball or zipball</param>
/// <param name="reference">A valid Git reference.</param>
/// <param name="timeout"> Timeout in minutes </param>
/// <returns>The binary contents of the archive</returns>
IObservable<byte[]> GetArchive(string owner, string name, ArchiveFormat archiveFormat, string reference, int timeout);
/// <summary>
/// Get an archive of a given repository's contents, in a specific format
/// </summary>
/// <remarks>https://developer.github.com/v3/repos/contents/#get-archive-link</remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="archiveFormat">The format of the archive. Can be either tarball or zipball</param>
/// <param name="reference">A valid Git reference.</param>
/// <param name="timeout"> Time span until timeout </param>
/// <returns>The binary contents of the archive</returns>
IObservable<byte[]> GetArchive(string owner, string name, ArchiveFormat archiveFormat, string reference, TimeSpan timeout);
/// <summary>
/// Returns the contents of a file or directory in a repository.
/// </summary>