/
UriSection.cs
38 lines (29 loc) · 1.72 KB
/
UriSection.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
namespace System.Configuration
{
public sealed class UriSection : ConfigurationSection
{
private static readonly ConfigurationPropertyCollection _properties = new ConfigurationPropertyCollection();
private static readonly ConfigurationProperty _idn = new ConfigurationProperty(CommonConfigurationStrings.Idn,
typeof(IdnElement), null, ConfigurationPropertyOptions.None);
private static readonly ConfigurationProperty _iriParsing = new ConfigurationProperty(
CommonConfigurationStrings.IriParsing, typeof(IriParsingElement), null, ConfigurationPropertyOptions.None);
private static readonly ConfigurationProperty _schemeSettings =
new ConfigurationProperty(CommonConfigurationStrings.SchemeSettings,
typeof(SchemeSettingElementCollection), null, ConfigurationPropertyOptions.None);
static UriSection()
{
_properties.Add(_idn);
_properties.Add(_iriParsing);
_properties.Add(_schemeSettings);
}
[ConfigurationProperty(CommonConfigurationStrings.Idn)]
public IdnElement Idn => (IdnElement)this[_idn];
[ConfigurationProperty(CommonConfigurationStrings.IriParsing)]
public IriParsingElement IriParsing => (IriParsingElement)this[_iriParsing];
[ConfigurationProperty(CommonConfigurationStrings.SchemeSettings)]
public SchemeSettingElementCollection SchemeSettings => (SchemeSettingElementCollection)this[_schemeSettings];
protected internal override ConfigurationPropertyCollection Properties => _properties;
}
}