test
Fork of mbed-libxively-6eca970 by
src/libxively/http_layer_queries.h@0:82702e998d3f, 2013-06-26 (annotated)
- Committer:
- xively
- Date:
- Wed Jun 26 10:40:43 2013 +0000
- Revision:
- 0:82702e998d3f
libxively v0.1.1-rc0 (34c8b32)
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
xively | 0:82702e998d3f | 1 | // Copyright (c) 2003-2013, LogMeIn, Inc. All rights reserved. |
xively | 0:82702e998d3f | 2 | // This is part of Xively C library, it is under the BSD 3-Clause license. |
xively | 0:82702e998d3f | 3 | |
xively | 0:82702e998d3f | 4 | /** |
xively | 0:82702e998d3f | 5 | * \file http_layer_queries.c |
xively | 0:82702e998d3f | 6 | * \author Olgierd Humenczuk |
xively | 0:82702e998d3f | 7 | * \brief Helpers for making HTTP requests (specific to Xively REST/HTTP API) |
xively | 0:82702e998d3f | 8 | * |
xively | 0:82702e998d3f | 9 | * * All functions return pointer to the buffer with request string or null in case of any error. |
xively | 0:82702e998d3f | 10 | |
xively | 0:82702e998d3f | 11 | * \warning The buffer is managed by the library, so it's forbidden to free the pointer. |
xively | 0:82702e998d3f | 12 | */ |
xively | 0:82702e998d3f | 13 | |
xively | 0:82702e998d3f | 14 | #ifndef __HTTP_LAYERS_QUERIES_H__ |
xively | 0:82702e998d3f | 15 | #define __HTTP_LAYERS_QUERIES_H__ |
xively | 0:82702e998d3f | 16 | |
xively | 0:82702e998d3f | 17 | #include <stdlib.h> |
xively | 0:82702e998d3f | 18 | #include <stdint.h> |
xively | 0:82702e998d3f | 19 | |
xively | 0:82702e998d3f | 20 | #ifdef __cplusplus |
xively | 0:82702e998d3f | 21 | extern "C" { |
xively | 0:82702e998d3f | 22 | #endif |
xively | 0:82702e998d3f | 23 | |
xively | 0:82702e998d3f | 24 | const char* http_construct_request_datapoint( |
xively | 0:82702e998d3f | 25 | const char* http_method |
xively | 0:82702e998d3f | 26 | , const int32_t* feed_id |
xively | 0:82702e998d3f | 27 | , const char* datastream_id |
xively | 0:82702e998d3f | 28 | , const char* dp_ts_str |
xively | 0:82702e998d3f | 29 | , const char* x_api_key ); |
xively | 0:82702e998d3f | 30 | |
xively | 0:82702e998d3f | 31 | const char* http_construct_request_datastream( |
xively | 0:82702e998d3f | 32 | const char* http_method |
xively | 0:82702e998d3f | 33 | , const int32_t* feed_id |
xively | 0:82702e998d3f | 34 | , const char* datastream_id |
xively | 0:82702e998d3f | 35 | , const char* x_api_key ); |
xively | 0:82702e998d3f | 36 | |
xively | 0:82702e998d3f | 37 | const char* http_construct_request_feed( |
xively | 0:82702e998d3f | 38 | const char* http_method |
xively | 0:82702e998d3f | 39 | , const int32_t* feed_id |
xively | 0:82702e998d3f | 40 | , const char* x_api_key |
xively | 0:82702e998d3f | 41 | , const char* query_suffix ); |
xively | 0:82702e998d3f | 42 | |
xively | 0:82702e998d3f | 43 | const char* http_construct_content( |
xively | 0:82702e998d3f | 44 | int32_t content_size ); |
xively | 0:82702e998d3f | 45 | |
xively | 0:82702e998d3f | 46 | #ifdef __cplusplus |
xively | 0:82702e998d3f | 47 | } |
xively | 0:82702e998d3f | 48 | #endif |
xively | 0:82702e998d3f | 49 | |
xively | 0:82702e998d3f | 50 | #endif // __HTTP_LAYERS_QUERIES_H__ |