Soletta™ Framework
Framework for making IoT devices

Full online documentation | C API Index
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Functions | Variables
download.c File Reference
#include <errno.h>
#include <getopt.h>
#include <stdio.h>
#include <string.h>
#include "soletta.h"
#include "sol-http.h"
#include "sol-http-client.h"

Functions

static ssize_t on_data_func (void *userdata, struct sol_http_client_connection *connection, const struct sol_buffer *buffer)
 
static void response_func (void *userdata, struct sol_http_client_connection *connection, struct sol_http_response *response)
 
static void shutdown (void)
 
 SOL_MAIN_DEFAULT (startup, shutdown)
 
static void startup (void)
 

Variables

static FILE * fd
 
static const struct
sol_http_request_interface 
iface
 
struct sol_http_client_connectionpending
 

Function Documentation

static ssize_t on_data_func ( void *  userdata,
struct sol_http_client_connection connection,
const struct sol_buffer buffer 
)
static
static void response_func ( void *  userdata,
struct sol_http_client_connection connection,
struct sol_http_response response 
)
static
static void shutdown ( void  )
static
SOL_MAIN_DEFAULT ( startup  ,
shutdown   
)
static void startup ( void  )
static

Variable Documentation

FILE* fd
static
const struct sol_http_request_interface iface
static
Initial value:
= {
.on_data = on_data_func,
.on_response = response_func
}
static void response_func(void *userdata, struct sol_http_client_connection *connection, struct sol_http_response *response)
Definition: download.c:47
static ssize_t on_data_func(void *userdata, struct sol_http_client_connection *connection, const struct sol_buffer *buffer)
Definition: download.c:32
Examples:
/src/samples/http/download.c.
struct sol_http_client_connection* pending