示例#1
0
        /// <summary>
        /// Closes the PluginGraph for adding or removing members.  Runs all the <see cref="AssemblyScanner"> AssemblyScanner's</see>
        /// and attempts to attach concrete types to the proper plugin types.  Calculates the Profile defaults.
        /// </summary>
        public void Seal()
        {
            if (_sealed)
            {
                return;
            }

            _scanners.ForEach(scanner => scanner.ScanForAll(this));

            _pluginFamilies.Each(family => family.AddTypes(_pluggedTypes));
            _pluginFamilies.Each(family => family.Seal());

            _profileManager.Seal(this);

            _sealed = true;
        }
示例#2
0
        /// <summary>
        /// Closes the PluginGraph for adding or removing members.  Runs all the <see cref="AssemblyScanner"> AssemblyScanner's</see>
        /// and attempts to attach concrete types to the proper plugin types.  Calculates the Profile defaults.
        /// </summary>
        public void Seal()
        {
            if (_sealed)
            {
                return;
            }

            // This was changed to support .Net 4.5 which is stricture on collection modification
            int index = 0;

            while (index < _scanners.Count())
            {
                _scanners[index++].ScanForAll(this);
            }

            _pluginFamilies.Each(family => family.AddTypes(_pluggedTypes));
            _pluginFamilies.Each(family => family.Seal());

            _profileManager.Seal(this);

            _sealed = true;
        }