--- parser3/src/include/pa_globals.h 2003/07/24 11:31:21 1.104 +++ parser3/src/include/pa_globals.h 2026/04/25 13:38:46 1.121 @@ -1,37 +1,43 @@ /** @file Parser: global decls. - Copyright (c) 2001-2003 ArtLebedev Group (http://www.artlebedev.com) - Author: Alexandr Petrosian (http://paf.design.ru) + Copyright (c) 2001-2026 Art. Lebedev Studio (https://www.artlebedev.com) + Authors: Konstantin Morshnev , Alexandr Petrosian */ #ifndef PA_GLOBALS_H #define PA_GLOBALS_H -static const char* IDENT_GLOBALS_H="$Date: 2003/07/24 11:31:21 $"; +#define IDENT_PA_GLOBALS_H "$Id: pa_globals.h,v 1.121 2026/04/25 13:38:46 moko Exp $" +#ifdef XML +# include "libxml/tree.h" +#endif -#include "pa_hash.h" -#include "pa_string.h" - -class Dictionary; -class Charset; -class Table; +class Request; -/// core func +/// initialize global variables void pa_globals_init(); +/// finalize global variables +void pa_globals_done(); + +/// for lt_dlinit to be called once +void pa_dlinit(); + /// hex_value[c] = hex value of c extern short hex_value[0x100]; #ifdef XML -/// DOMImplementation -extern GdomeDOMImplementation *domimpl; - /// flag whether there were some xml generic errors on current thread bool xmlHaveGenericErrors(); /// get xml generic error accumulated for current thread. WARNING: it is up to caller to free up const char* xmlGenericErrors(); #endif +/// register request for local thread to retrive later with pa_get_request() +void pa_register_thread_request(Request&); +/// retrives request set by pa_set_request function, useful in contextless places [slow] +Request& pa_thread_request(); + #endif