18#ifndef _LOG4CXX_HELPERS_APRINITIALIZER_H
19#define _LOG4CXX_HELPERS_APRINITIALIZER_H
22 #error "aprinitializer.h should only be included by log4cxx implementation"
63 template <
class T>
static void setUnique(
const std::shared_ptr<T>& pObject)
65 getInstance().addObject(
typeid(T).hash_code(), pObject);
72 return cast<T>(getInstance().findOrAddObject(
typeid(T).hash_code(), creator));
81 void addObject(
size_t key,
const ObjectPtr& pObject);
85 LOG4CXX_DECLARE_PRIVATE_MEMBER_PTR(APRInitializerPrivate, m_priv)
struct apr_threadkey_t apr_threadkey_t
Definition: aprinitializer.h:31
struct apr_thread_mutex_t apr_thread_mutex_t
Definition: aprinitializer.h:30
Definition: aprinitializer.h:45
static void unregisterAll()
static apr_threadkey_t * getTlsKey()
static std::shared_ptr< T > getOrAddUnique(std::function< ObjectPtr()> creator)
Fetch or add a single instance type ObjectPtr for deletion prior to termination.
Definition: aprinitializer.h:70
static void registerCleanup(FileWatchdog *watchdog)
Register a FileWatchdog for deletion prior to termination.
static log4cxx_time_t initialize()
static apr_pool_t * getRootPool()
static void setUnique(const std::shared_ptr< T > &pObject)
Store a single instance type ObjectPtr for deletion prior to termination.
Definition: aprinitializer.h:63
static bool isDestructed
Definition: aprinitializer.h:50
static void unregisterCleanup(FileWatchdog *watchdog)
Check every now and then that a certain file has not changed.
Definition: filewatchdog.h:39
std::shared_ptr< Object > ObjectPtr
Definition: optionconverter.h:41
Definition: configuration.h:25