mirror of
https://github.com/zoriya/octokit.net.git
synced 2026-06-06 20:13:40 +00:00
tidy up some xml-docs while i'm in here
This commit is contained in:
@@ -1,11 +1,24 @@
|
||||
namespace Octokit.Internal
|
||||
{
|
||||
/// <summary>
|
||||
/// Wrapper for a response from the API
|
||||
/// </summary>
|
||||
/// <typeparam name="T">Payload contained in the response</typeparam>
|
||||
public class ApiResponse<T> : IApiResponse<T>
|
||||
{
|
||||
/// <summary>
|
||||
/// Create a ApiResponse from an existing request
|
||||
/// </summary>
|
||||
/// <param name="response">An existing request to wrap</param>
|
||||
public ApiResponse(IResponse response) : this(response, GetBodyAsObject(response))
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Create a ApiResponse from an existing request and object
|
||||
/// </summary>
|
||||
/// <param name="response">An existing request to wrap</param>
|
||||
/// <param name="bodyAsObject">The payload from an existing request</param>
|
||||
public ApiResponse(IResponse response, T bodyAsObject)
|
||||
{
|
||||
Ensure.ArgumentNotNull(response, "response");
|
||||
@@ -14,8 +27,14 @@
|
||||
Body = bodyAsObject;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The payload of the response
|
||||
/// </summary>
|
||||
public T Body { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// The context of the response
|
||||
/// </summary>
|
||||
public IResponse HttpResponse { get; private set; }
|
||||
|
||||
static T GetBodyAsObject(IResponse response)
|
||||
|
||||
Reference in New Issue
Block a user