simple pub/sub class with support for namespaces