Organize classes better

Closes #94
This commit is contained in:
Haacked
2013-10-26 09:52:56 -07:00
parent 85145def8c
commit 61c4cdf002
64 changed files with 115 additions and 113 deletions
@@ -0,0 +1,58 @@
using System;
using System.Diagnostics.CodeAnalysis;
using System.Reactive;
namespace Octokit.Reactive
{
public interface IObservableSshKeysClient
{
/// <summary>
/// Retrieves the <see cref="SshKey"/> for the specified id.
/// </summary>
/// <param name="id">The ID of the SSH key.</param>
/// <returns>A <see cref="SshKey"/></returns>
[SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId = "Get")]
IObservable<SshKey> Get(int id);
/// <summary>
/// Retrieves the <see cref="SshKey"/> for the specified id.
/// </summary>
/// <param name="user">The login of the user.</param>
/// <returns>A <see cref="IReadOnlyPagedCollection{SshKey}"/> of <see cref="SshKey"/>.</returns>
IObservable<SshKey> GetAll(string user);
/// <summary>
/// Retrieves the <see cref="SshKey"/> for the specified id.
/// </summary>
/// <exception cref="AuthorizationException">Thrown if the client is not authenticated.</exception>
/// <returns>A <see cref="IReadOnlyPagedCollection{SshKey}"/> of <see cref="SshKey"/>.</returns>
[SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate",
Justification = "Makes a network request")]
IObservable<SshKey> GetAllForCurrent();
/// <summary>
/// Update the specified <see cref="UserUpdate"/>.
/// </summary>
/// <param name="key"></param>
/// <exception cref="AuthorizationException">Thrown if the client is not authenticated.</exception>
/// <returns>A <see cref="User"/></returns>
IObservable<SshKey> Create(SshKeyUpdate key);
/// <summary>
/// Update the specified <see cref="UserUpdate"/>.
/// </summary>
/// <param name="id"></param>
/// <param name="key"></param>
/// <exception cref="AuthorizationException">Thrown if the client is not authenticated.</exception>
/// <returns>A <see cref="User"/></returns>
IObservable<SshKey> Update(int id, SshKeyUpdate key);
/// <summary>
/// Update the specified <see cref="UserUpdate"/>.
/// </summary>
/// <param name="id">The id of the SSH key</param>
/// <exception cref="AuthorizationException">Thrown if the client is not authenticated.</exception>
/// <returns>A <see cref="User"/></returns>
IObservable<Unit> Delete(int id);
}
}