示例#1
0
        public void ConfigureSubCollections(ICatalogCollection coll)
        {
            if ((_installFlags & InstallationFlags.ConfigureComponentsOnly) == 0)
            {
                foreach (Type t in _spec.ConfigurableTypes)
                {
                    ICatalogObject     obj     = (ICatalogObject)FindObject(coll, t);
                    ICatalogCollection ifcColl = (ICatalogCollection)(coll.GetCollection(CollectionName.Interfaces, obj.Key()));

                    // Poke the cache so it's up to date...
                    _cache["Component"]     = obj;
                    _cache["ComponentType"] = t;

                    InterfaceConfigCallback cb = new InterfaceConfigCallback(ifcColl, t, _cache, _driver);
                    _driver.ConfigureCollection(ifcColl, cb);

                    if (_cache["SecurityOnMethods"] != null || ServicedComponentInfo.AreMethodsSecure(t))
                    {
                        DBG.Info(DBG.Registration, "Found security on methods for: " + t);
                        FixupMethodSecurity(ifcColl);
                        _cache["SecurityOnMethods"] = null;
                    }
                }
            }
        }
示例#2
0
        public void ConfigureSubCollections(ICatalogCollection coll)
        {
            foreach (ICatalogObject ifcObj in this)
            {
                Type ifc = (Type)FindObject(coll, ifcObj);
                if (ifc == null)
                {
                    continue;
                }

                ICatalogCollection methColl = (ICatalogCollection)(coll.GetCollection(CollectionName.Methods, ifcObj.Key()));
                _driver.ConfigureCollection(methColl,
                                            new MethodConfigCallback(methColl, ifc, _type, _cache, _driver));
            }
        }