taler-auditor-httpd_spa.h (1755B)
1 /* 2 This file is part of TALER 3 Copyright (C) 2024 Taler Systems SA 4 5 TALER is free software; you can redistribute it and/or modify it under the 6 terms of the GNU General Public License as published by the Free Software 7 Foundation; either version 3, or (at your option) any later version. 8 9 TALER is distributed in the hope that it will be useful, but WITHOUT ANY 10 WARRANTY; without even the implied warranty of EXCHANGEABILITY or FITNESS FOR 11 A PARTICULAR PURPOSE. See the GNU General Public License for more details. 12 13 You should have received a copy of the GNU General Public License along with 14 TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/> 15 */ 16 /** 17 * @file taler-auditor-httpd_spa.h 18 * @brief logic to preload and serve static files 19 * @author Christian Grothoff 20 */ 21 #ifndef TALER_AUDITOR_HTTPD_SPA_H 22 #define TALER_AUDITOR_HTTPD_SPA_H 23 24 #include <microhttpd.h> 25 #include "taler-auditor-httpd.h" 26 27 28 /** 29 * Return our single-page-app user interface 30 * for staff (see contrib/wallet-core/). 31 * 32 * @param rh request context 33 * @param connection the MHD connection to handle 34 * @param[in,out] connection_cls the connection's closure (can be updated) 35 * @param upload_data upload data 36 * @param[in,out] upload_data_size number of bytes (left) in @a upload_data 37 * @param args request URL broken up into tokens at '/' characters 38 * @return MHD result code 39 */ 40 MHD_RESULT 41 TAH_spa_handler ( 42 /* const */ struct TAH_RequestHandler *rh, 43 struct MHD_Connection *connection, 44 void **connection_cls, 45 const char *upload_data, 46 size_t *upload_data_size, 47 const char *const args[]); 48 49 50 /** 51 * Preload and compress SPA files. 52 * 53 * @return #GNUNET_OK on success 54 */ 55 enum GNUNET_GenericReturnValue 56 TAH_spa_init (void); 57 58 59 #endif