Пример #1
0
        protected void ApplyProperties(EventType eventType, EventType newEventType)
        {
            // Copy properties and commit the changes.

            eventType.CopyProperties(newEventType);
            eventType.Commit();
        }
Пример #2
0
        private static void CopyElement(Catalogue catalogue, EventType eventType)
        {
            // Check whether the event already exists.

            EventType thisEventType = catalogue.EventTypes[eventType.Name];

            if (thisEventType == null)
            {
                // Doesn't exist so create new clone.

                thisEventType = eventType.CloneProperties(catalogue, eventType.Name);
                catalogue.Add(thisEventType);
            }
            else
            {
                // Already exists so copy details.

                thisEventType.CopyProperties(eventType);
            }
        }