Esempio n. 1
0
        /// <summary>
        /// Updates the tree view to reflect the changes in the specified <see cref="ConfigurationObjectChangeSet" />.
        /// </summary>
        /// <param name="changeSet">The <see cref="ConfigurationObjectChangeSet" />.</param>
        public void UpdateTreeView(ConfigurationObjectChangeSet changeSet)
        {
            BeginUpdate();

            foreach (ConfigurationObjectTag tag in changeSet.AddedObjects)
            {
                HandleAdded(tag);
            }

            foreach (ConfigurationObjectTag tag in changeSet.ModifiedObjects)
            {
                HandleModified(tag);
            }

            foreach (ConfigurationObjectTag tag in changeSet.RemovedObjects)
            {
                HandleRemoved(tag);
            }

            EndUpdate();
        }
Esempio n. 2
0
        private void OnConfigurationObjectsChanged(ConfigurationObjectChangeSet changeSet)
        {
            ConfigurationChangeSetEventArgs eventArgs = new ConfigurationChangeSetEventArgs(changeSet);

            ConfigurationObjectsChanged?.Invoke(this, eventArgs);
        }
Esempio n. 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ConfigurationChangeSetEventArgs" /> class.
 /// </summary>
 /// <param name="changeSet">The <see cref="ConfigurationObjectChangeSet" />.</param>
 /// <exception cref="ArgumentNullException"><paramref name="changeSet" /> is null.</exception>
 public ConfigurationChangeSetEventArgs(ConfigurationObjectChangeSet changeSet)
 {
     ChangeSet = changeSet ?? throw new ArgumentNullException(nameof(changeSet));
 }
Esempio n. 4
0
        /// <summary>
        /// Loads all configuration objects from the database.
        /// </summary>
        public void Load()
        {
            ConfigurationObjectChangeSet loadedObjects = _enterpriseTestController.LoadConfigurationObjects();

            OnConfigurationObjectsChanged(loadedObjects);
        }