internal static void RegisterChannels (ArrayList channels, bool onlyDelayed)
{
foreach (ChannelData channel in channels)
{
if (onlyDelayed && channel.DelayLoadAsClientChannel != "true")
continue;
if (defaultDelayedConfigRead && channel.DelayLoadAsClientChannel == "true")
continue;
if (channel.Ref != null)
{
ChannelData template = (ChannelData) channelTemplates [channel.Ref];
if (template == null) throw new RemotingException ("Channel template '" + channel.Ref + "' not found");
channel.CopyFrom (template);
}
foreach (ProviderData prov in channel.ServerProviders)
{
if (prov.Ref != null)
{
ProviderData template = (ProviderData) serverProviderTemplates [prov.Ref];
if (template == null) throw new RemotingException ("Provider template '" + prov.Ref + "' not found");
prov.CopyFrom (template);
}
}
foreach (ProviderData prov in channel.ClientProviders)
{
if (prov.Ref != null)
{
ProviderData template = (ProviderData) clientProviderTemplates [prov.Ref];
if (template == null) throw new RemotingException ("Provider template '" + prov.Ref + "' not found");
prov.CopyFrom (template);
}
}
ChannelServices.RegisterChannelConfig (channel);
}
}