Example #1
0
        /// <summary>
        /// RegisterCommand
        /// </summary>
        public void RegisterCommand()
        {
            GlobalDefinition.LoggerWrapper.LogTraceInfo("Now we enter RegisterCommand method");
            if (null == ContaineeUtility._feCommProxy)
            {
                GlobalDefinition.LoggerWrapper.LogTraceInfo("param ContaineeUtility._feCommProxy is null");
                return;
            }

            FECommandHandler cmdHandler = null;

            //Register Command
            cmdHandler = new FECommandHandler();
            ContaineeUtility._feCommProxy.RegisterCommandHandler((int)CommandID.COMMAND_DATABASE_EVENT, cmdHandler);

            FEEventHandler eventHandler = null;

            eventHandler = new FEEventHandler();
            ContaineeUtility._feCommProxy.RegisterEventHandler(GlobalDefinition.ServicePageChangedID,
                                                               (int)EventID.SystemCommandEventIDSyncTime, eventHandler);
            ContaineeUtility._feCommProxy.SubscribeEvent(GlobalDefinition.ServicePageChangedID,
                                                         (int)EventID.SystemCommandEventIDSyncTime);
            ContaineeUtility._feEvtHandlerList.Add(eventHandler);

            RegisteredDBNotification();
        }
Example #2
0
 private void AttachCommand()
 {
     FECommandHandler.AddItemToCommandMap((int)CommandID.COMMAND_DATABASE_EVENT, NoticeEventHandlerFromDatabase);
 }