Esempio n. 1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="xmlDoc"></param>
        public static XmlDocument AddObjectsToGroups(XmlDocument xmlDoc)
        {
            List <XmlDocument> xmlDocList = new List <XmlDocument>();
            XmlDocument        result     = null;

            DataOpContext dataOpContext = InitEventContexts();

            dataOpContext.OnBeforeAddObjectsToGroups(xmlDoc);

            using (TransactionScope scope = TransactionScopeFactory.Create())
            {
                xmlDocList = dataOpContext.OnAddObjectsToGroups(xmlDoc);
                scope.Complete();
            }

            if (xmlDocList.Count == 1)
            {
                result = xmlDocList[0];
            }
            return(result);
        }