Пример #1
0
        /// <summary>
        ///     Constructs a channel-set config by binding its corresponding section
        ///     in the BAPS server configuration.
        /// </summary>
        /// <param name="channelSetSection">The section of the main BAPS configuration that contains channel-set config.</param>
        /// <returns>The created config node.</returns>
        private ChannelSetConfig MakeChannelSet(IConfigurationSection channelSetSection)
        {
            var logger           = CreateLogger <ChannelSetConfig>();
            var channelSetConfig = new ChannelSetConfig(logger);

            channelSetSection.Bind(channelSetConfig);

            channelSetConfig.Channels = MakeChannelConfigs(channelSetSection, channelSetConfig.Count);

            return(channelSetConfig);
        }
Пример #2
0
 public ServerConfig(ListenConfig listen, ChannelSetConfig channelSet, ILogger <ServerConfig>?logger) : base(logger)
 {
     Listen     = listen;
     ChannelSet = channelSet;
 }