X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=src%2Finclude%2Fgnunet_rest_lib.h;h=392ef688038fa5d1bb6c5232209d67209388a7ae;hb=418bf5953acdba2e325528d739fb115b51b7141f;hp=a4dbb0696af57a8725449cfce618416c765f9064;hpb=3611a5295f95fad5d9e1fdb3866e7db9ecf8f47e;p=oweals%2Fgnunet.git diff --git a/src/include/gnunet_rest_lib.h b/src/include/gnunet_rest_lib.h index a4dbb0696..392ef6880 100644 --- a/src/include/gnunet_rest_lib.h +++ b/src/include/gnunet_rest_lib.h @@ -2,20 +2,18 @@ This file is part of GNUnet Copyright (C) 2010-2015 GNUnet e.V. - GNUnet is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published - by the Free Software Foundation; either version 3, or (at your - option) any later version. + GNUnet is free software: you can redistribute it and/or modify it + under the terms of the GNU Affero General Public License as published + by the Free Software Foundation, either version 3 of the License, + or (at your option) any later version. GNUnet is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GNUnet; see the file COPYING. If not, write to the - Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - Boston, MA 02110-1301, USA. + Affero General Public License for more details. + + You should have received a copy of the GNU Affero General Public License + along with this program. If not, see . */ /** @@ -38,10 +36,34 @@ struct GNUNET_REST_RequestHandle { + /** + * Map of url parameters + */ struct GNUNET_CONTAINER_MultiHashMap *url_param_map; + + /** + * Map of headers + */ + struct GNUNET_CONTAINER_MultiHashMap *header_param_map; + + /** + * The HTTP method as MHD value (see microhttpd.h) + */ const char *method; + + /** + * The url as string + */ const char *url; + + /** + * The POST data + */ const char *data; + + /** + * The POST data size + */ size_t data_size; }; @@ -89,7 +111,7 @@ typedef void (*GNUNET_REST_ResultProcessor) (void *cls, * * @param url URL to check * @param namespace namespace to check against - * @retun GNUNET_YES if namespace matches + * @return GNUNET_YES if namespace matches */ int GNUNET_REST_namespace_match (const char *url, const char *namespace); @@ -98,7 +120,7 @@ GNUNET_REST_namespace_match (const char *url, const char *namespace); * Create REST MHD response * * @param data result - * @retun MHD response + * @return MHD response */ struct MHD_Response* GNUNET_REST_create_response (const char *data);