//Allows you to easily register a callback without having to worry about keeping a reference to the poller public static void Register(OnNewQuestionEventHandler onNewQuestion, ExchangeSite site = ExchangeSite.AllSites) { Register(onNewQuestion, ex => { }, site); }
public static void Register(OnNewQuestionEventHandler onNewQuestion, OnExceptionEventHandler onException, ExchangeSite site = ExchangeSite.AllSites) { var poller = new ActiveQuestionsPoller(site); poller.OnNewQuestion += onNewQuestion; poller.OnException += onException; poller.Connect(); Pollers.Add(poller); }
public ActiveQuestionsPoller(ExchangeSite site = ExchangeSite.AllSites) { this.site = site; }