mirror of
https://github.com/zoriya/octokit.net.git
synced 2026-06-05 11:40:42 +00:00
Remove the redundant ApiInfo property
This commit is contained in:
@@ -4,23 +4,55 @@ using System.Net;
|
||||
|
||||
namespace Octokit
|
||||
{
|
||||
/// <summary>
|
||||
/// A response from an API call that includes the deserialized object instance.
|
||||
/// </summary>
|
||||
public interface IApiResponse<out T>
|
||||
{
|
||||
/// <summary>
|
||||
/// Object deserialized from the JSON response body.
|
||||
/// </summary>
|
||||
T Body { get; }
|
||||
|
||||
ApiInfo ApiInfo { get; }
|
||||
|
||||
/// <summary>
|
||||
/// The response status code.
|
||||
/// </summary>
|
||||
HttpStatusCode StatusCode { get; }
|
||||
|
||||
/// <summary>
|
||||
/// The original non-deserialized http response.
|
||||
/// </summary>
|
||||
IResponse HttpResponse { get; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Represents a generic HTTP response
|
||||
/// </summary>
|
||||
public interface IResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// Raw response body. Typically a string, but when requesting images, it will be a byte array.
|
||||
/// </summary>
|
||||
object Body { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Information about the API.
|
||||
/// </summary>
|
||||
IReadOnlyDictionary<string, string> Headers { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Information about the API response parsed from the response headers.
|
||||
/// </summary>
|
||||
ApiInfo ApiInfo { get; }
|
||||
|
||||
/// <summary>
|
||||
/// The response status code.
|
||||
/// </summary>
|
||||
HttpStatusCode StatusCode { get; }
|
||||
|
||||
/// <summary>
|
||||
/// The content type of the response.
|
||||
/// </summary>
|
||||
string ContentType { get; }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user