Esempio n. 1
0
        private static void ImportModule(EventMessage message)
        {
            try
            {
                string BusinessControllerClass = message.Attributes["BusinessControllerClass"];
                object controller = Reflection.CreateObject(BusinessControllerClass, string.Empty);
                if (controller is IPortable)
                {
                    int    ModuleId = Convert.ToInt32(message.Attributes["ModuleId"]);
                    string Content  = HttpUtility.HtmlDecode(message.Attributes["Content"]);
                    string Version  = message.Attributes["Version"];
                    int    UserID   = Convert.ToInt32(message.Attributes["UserId"]);

                    // call the IPortable interface for the module/version
                    ((IPortable)controller).ImportModule(ModuleId, Content, Version, UserID);

                    // Synchronize Module Cache
                    ModuleController.SynchronizeModule(ModuleId);
                }
            }
            catch (Exception exc)
            {
                Exceptions.LogException(exc);
            }
        }
Esempio n. 2
0
 public void SynchronizeModule()
 {
     ModuleController.SynchronizeModule(ModuleId);
 }