29#ifndef LUMIERA_LIFECYCLEREGISTRY_H
30#define LUMIERA_LIFECYCLEREGISTRY_H
60 typedef void (*
Hook)(void);
62 typedef Callbacks::iterator
Iter;
77 for (
Iter p = cbs.begin();
Token or Atom with distinct identity.
Registry of callback functions accessible by a label (ID) provided at registration.
static LifecycleRegistry & instance()
get the (single) LifecycleRegistry instance.
std::set< Hook > Callbacks
void execute(Symbol label)
std::map< Symbol, Callbacks > table_
bool enrol(Symbol label, Hook toCall)
Any copy and copy construction prohibited.
Lumiera public interface.
CStr ON_BASIC_INIT
automatic static init. treated specially to run as soon as possible
bool contains(MAP &map, typename MAP::key_type const &key)
shortcut for containment test on a map
Mix-Ins to allow or prohibit various degrees of copying and cloning.
Tiny helper functions and shortcuts to be used everywhere Consider this header to be effectively incl...