public EventContext(BloombergSessionWrapper bloombergSessionWrapper) { SessionContext = bloombergSessionWrapper; strategiesContainer = new UnityContainer(); RegisterDefaultBehaviour(); }
private void ProcessEvent(Event eventObj, BloombergSessionWrapper session) { try { var handler = strategiesContainer.Resolve <ISessionEventHandler>(eventObj.Type.ToString()); if (handler != null) { handler.ProcessEvent(eventObj, session); } } catch (Exception ex) { // take ex and pass it to the event Handler... //strategiesContainer.Resolve<ISessionEventHandler>(exceptionProcessorId).ProcessEvent(eventObj, session); Console.WriteLine(ex); } }