csharp-functions.IAsynchronousClient.mustache Maven / Gradle / Ivy
{{>partial_header}}
using System;
using System.Threading.Tasks;
namespace {{packageName}}.Client
{
///
/// Contract for Asynchronous RESTful API interactions.
///
/// This interface allows consumers to provide a custom API accessor client.
///
public interface IAsynchronousClient
{
///
/// Executes a non-blocking call to some using the GET http verb.
///
/// The relative path to invoke.
/// The request parameters to pass along to the client.
/// Per-request configurable settings.
/// Cancellation Token to cancel the request.
/// The return type.
/// A task eventually representing the response data, decorated with
Task> GetAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
///
/// Executes a non-blocking call to some using the POST http verb.
///
/// The relative path to invoke.
/// The request parameters to pass along to the client.
/// Per-request configurable settings.
/// Cancellation Token to cancel the request.
/// The return type.
/// A task eventually representing the response data, decorated with
Task> PostAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
///
/// Executes a non-blocking call to some using the PUT http verb.
///
/// The relative path to invoke.
/// The request parameters to pass along to the client.
/// Per-request configurable settings.
/// Cancellation Token to cancel the request.
/// The return type.
/// A task eventually representing the response data, decorated with
Task> PutAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
///
/// Executes a non-blocking call to some using the DELETE http verb.
///
/// The relative path to invoke.
/// The request parameters to pass along to the client.
/// Per-request configurable settings.
/// Cancellation Token to cancel the request.
/// The return type.
/// A task eventually representing the response data, decorated with
Task> DeleteAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
///
/// Executes a non-blocking call to some using the HEAD http verb.
///
/// The relative path to invoke.
/// The request parameters to pass along to the client.
/// Per-request configurable settings.
/// Cancellation Token to cancel the request.
/// The return type.
/// A task eventually representing the response data, decorated with
Task> HeadAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
///
/// Executes a non-blocking call to some using the OPTIONS http verb.
///
/// The relative path to invoke.
/// The request parameters to pass along to the client.
/// Per-request configurable settings.
/// Cancellation Token to cancel the request.
/// The return type.
/// A task eventually representing the response data, decorated with
Task> OptionsAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
///
/// Executes a non-blocking call to some using the PATCH http verb.
///
/// The relative path to invoke.
/// The request parameters to pass along to the client.
/// Per-request configurable settings.
/// Cancellation Token to cancel the request.
/// The return type.
/// A task eventually representing the response data, decorated with
Task> PatchAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy