protected override void AfterInitialize()
        {
            instanceCount.Clear();
            instance = this;
            // this is called right after the Base-Classes Initialize-Method. _eventManager and disposableManager are set
#if LEAK_DETECTION
            rxOnStartup.Add(() => {
                var devui = Kernel.Instance.Resolve <Service.DevUIService.IDevUIService>();
                var view  = devui.CreateView("leak");
                view.AddElement(new DevUIService.DevUIButton("GC.Collect()", () => { GC.Collect(); }));

                view.AddElement(new DevUIService.DevUIButton("Show instance-counts", () => {
                    OutputInstanceViewToLog();
                }));
            });
#endif
        }
 public API(PerformanceTestServiceImpl instance)
 {
     this.instance = instance;
 }