Conscience Core
Classes | Public Member Functions | Static Public Member Functions | List of all members
conscience_core::communication::HTTP::CscHttpClient Class Reference

#include <CscHttpClient.h>

Public Member Functions

ptr< HttpResponseget (const HttpGet &parameters) const noexcept(false)
 
ptr< HttpResponsepostMultipart (const HttpMultipartPost &parameters) const
 
ptr< HttpResponsedownload (const HttpGet &parameters, const fs::path &outFilePath, optional< function< void(float progressRatio)>> onProgress={}, optional< unsigned > timeoutSeconds=CscHttpClientConfiguration::defaultTimeoutSecondsDownload()) const noexcept(false)
 
ptr< HttpResponseupload (const string &protocol, const string &host, const string &path, int port, const fs::path &filePath) const noexcept(false)
 
ptr< HttpResponseupload (const string &protocol, const string &host, const string &path, int port, const std::vector< unsigned char > &dataBuffer, const std::string &contentType="application/octet-stream") const
 
ptr< HttpResponsepost (const HttpPost &parameters) const noexcept(false)
 

Static Public Member Functions

static CscHttpClientInstance ()
 

Member Function Documentation

◆ download()

ptr< HttpResponse > conscience_core::communication::HTTP::CscHttpClient::download ( const HttpGet parameters,
const fs::path &  outFilePath,
optional< function< void(float progressRatio)>>  onProgress = {},
optional< unsigned >  timeoutSeconds = CscHttpClientConfiguration::defaultTimeoutSecondsDownload() 
) const
noexcept
Returns
response in order to enable headers read

◆ get()

ptr< HttpResponse > conscience_core::communication::HTTP::CscHttpClient::get ( const HttpGet parameters) const
noexcept

◆ Instance()

CscHttpClient & conscience_core::communication::HTTP::CscHttpClient::Instance ( )
static

◆ post()

ptr< HttpResponse > conscience_core::communication::HTTP::CscHttpClient::post ( const HttpPost parameters) const
noexcept

◆ postMultipart()

ptr< HttpResponse > conscience_core::communication::HTTP::CscHttpClient::postMultipart ( const HttpMultipartPost parameters) const

◆ upload() [1/2]

ptr< HttpResponse > conscience_core::communication::HTTP::CscHttpClient::upload ( const string &  protocol,
const string &  host,
const string &  path,
int  port,
const fs::path &  filePath 
) const
noexcept

◆ upload() [2/2]

ptr< HttpResponse > conscience_core::communication::HTTP::CscHttpClient::upload ( const string &  protocol,
const string &  host,
const string &  path,
int  port,
const std::vector< unsigned char > &  dataBuffer,
const std::string &  contentType = "application/octet-stream" 
) const

The documentation for this class was generated from the following files: