2using System.Collections.Generic;
24 #endregion Constructors
26 #region Implicit Operators
30 return value.Get(
timeout: value.DefaultTimeout);
32 #endregion Implicit Operators
81 response.StatusCode +
". The response stream likely contains an error message " +
82 "from the API, rather than the expected requested data. Please check the data " +
83 "returned to the 'consumeStream' delegate for details.");
85 #endregion REST Methods
A custom exception class that includes the RestSharp.IRestResponse that generated the exception,...
Describes a collection of resources which can be listed.
Describes an additional sub-resource available off a resource which is not actually a property of tha...
void ValidateOwnerHasId()
Verifies the owner exists and has been POSTed, ensuring that it is safe to invoke actions on this Sub...
string Path
The relative path to this endpoint from the root server URL.
Describes an additional sub-resource available off a resource which is not actually a property of tha...
IRestResponse GetStream(Action< Stream > consumeStream, IEnumerable< Parameter > parameters=null, int? timeout=null)
Perform a GET on the supplied URL and provide an action for consuming the response stream rather than...
SubResource(IEndpoint owner, string relativePath)
Defines a new sub-resource or endpoint off of some other endpoint.
IRestResponse Head(IEnumerable< Parameter > parameters=null, int? timeout=null)
Performs a HEAD request at this endpoint.
T Get(IEnumerable< Parameter > parameters=null, int? timeout=null)
Performs a GET request a at this endpoint.
int? DefaultTimeout
Can be used to override the API.DefaultRequestTimeout with one that better suits this SubResource.
API methods / requests made available to the user.
static object RequestAndParse(Type deserializeType, string resource, Method method, IEnumerable< Parameter > requestParameters=null, int? timeout=null)
Perform a REST request on the server and serializes the response to the desired run-time type.
static IRestResponse ExecuteRestRequest(string resource, Method method, IEnumerable< Parameter > requestParameters=null, int? timeout=null, bool returnRawResponse=false, Action< Stream > responseStreamReader=null)
Perform a REST request on the server.
Describes an endpoint on the server that can be interacted with. Inheriting from this interface means...