Example #1
0
 public override void Release()
 {
     if (m_tblEvent != null)
     {
         m_tblEvent.Clear();
         m_tblEvent = null;
     }
     base.Release();
 }
Example #2
0
        protected EventTable GetEventTable()
        {
            if (m_tblEvent == null)
            {
                m_tblEvent = new EventTable();
            }

            return(m_tblEvent);
        }
Example #3
0
        private void InitPreListenEventsForModule(BusinessModule module)
        {
            if (m_mapPreListenEvents.ContainsKey(module.Name))
            {
                EventTable tblEvent = m_mapPreListenEvents[module.Name];
                m_mapPreListenEvents.Remove(module.Name);

                module.setEventTable(tblEvent);
            }
        }
Example #4
0
        private EventTable GetPreListenEventTable(string target)
        {
            EventTable table = null;

            if (!m_mapPreListenEvents.ContainsKey(target))
            {
                table = new EventTable();
                m_mapPreListenEvents.Add(target, table);
            }
            else
            {
                table = m_mapPreListenEvents[target];
            }

            return(table);
        }
Example #5
0
        //=================================================================================

        public ModuleEvent Event(string target, string type)
        {
            ModuleEvent    evt    = null;
            BusinessModule module = GetModule(target);

            if (module != null)
            {
                evt = module.Event(type);
            }
            else
            {
                EventTable table = GetPreListenEventTable(target);
                evt = table.GetEvent(type);
            }

            return(evt);
        }
Example #6
0
 internal void setEventTable(EventTable tblEvent)
 {
     m_tblEvent = tblEvent;
 }