using System;
using System.Reactive.Threading.Tasks;
using Octokit;
namespace Octokit.Reactive
{
///
/// A client for GitHub's Enterprise License API
///
///
/// See the Enterprise License API documentation for more information.
///
public class ObservableEnterpriseLicenseClient : IObservableEnterpriseLicenseClient
{
readonly IEnterpriseLicenseClient _client;
public ObservableEnterpriseLicenseClient(IGitHubClient client)
{
Ensure.ArgumentNotNull(client, nameof(client));
_client = client.Enterprise.License;
}
///
/// Gets GitHub Enterprise License Information (must be Site Admin user).
///
///
/// https://developer.github.com/v3/enterprise/license/#get-license-information
///
/// The statistics.
public IObservable Get()
{
return _client.Get().ToObservable();
}
}
}