Adding IObservableUserEmailsClient and...

default implementation. Still needs delete method which is skipped
because it's a HTTP DELETE. There's currently nothing in the
ApiConnection to handle this scenario and it's a rather unorthodox thing
to support.
delete.
This commit is contained in:
Peter MacNaughton
2014-02-08 12:48:53 -07:00
parent 56cbb0cf2f
commit 133298789f
5 changed files with 68 additions and 19 deletions
@@ -0,0 +1,35 @@
using System;
using System.Diagnostics.CodeAnalysis;
namespace Octokit.Reactive
{
/// <summary>
/// A client for GitHub's User Emails API.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/users/emails/">User Emails API documentation</a> for more information.
/// </remarks>
public interface IObservableUserEmailsClient
{
/// <summary>
/// Gets all email addresses for the authenticated user.
/// </summary>
/// <remarks>
/// http://developer.github.com/v3/users/emails/#list-email-addresses-for-a-user
/// </remarks>
/// <returns>The <see cref="EmailAddress"/>es for the authenticated user.</returns>
[SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")]
IObservable<EmailAddress> GetAll();
/// <summary>
/// Adds email addresses for the authenticated user.
/// </summary>
/// <remarks>
/// http://developer.github.com/v3/users/emails/#add-email-addresses
/// </remarks>
/// <param name="emailAddresses">The email addresses to add.</param>
/// <returns>Returns the added <see cref="EmailAddress"/>es.</returns>
IObservable<string> Add(params string[] emailAddresses);
}
}