45 lines
1.3 KiB
C#
45 lines
1.3 KiB
C#
using System.Configuration;
|
|
|
|
namespace Kreta.MessageBroker.Configuration
|
|
{
|
|
/// <summary>
|
|
/// Message client configuration element collection
|
|
/// </summary>
|
|
public class MessageClientConfigurationElementCollection : ConfigurationElementCollection
|
|
{
|
|
/// <summary>
|
|
/// Collection type
|
|
/// </summary>
|
|
public override ConfigurationElementCollectionType CollectionType
|
|
{
|
|
get { return ConfigurationElementCollectionType.BasicMap; }
|
|
}
|
|
|
|
/// <summary>
|
|
/// Create new element
|
|
/// </summary>
|
|
/// <returns>Configuration element</returns>
|
|
protected override ConfigurationElement CreateNewElement()
|
|
{
|
|
return new MessageClientConfigurationElement();
|
|
}
|
|
|
|
/// <summary>
|
|
/// Get element key
|
|
/// </summary>
|
|
/// <param name="element">Element</param>
|
|
/// <returns>Element key</returns>
|
|
protected override object GetElementKey(ConfigurationElement element)
|
|
{
|
|
return ((MessageClientConfigurationElement)element).Name;
|
|
}
|
|
|
|
/// <summary>
|
|
/// Get element name
|
|
/// </summary>
|
|
protected override string ElementName
|
|
{
|
|
get { return MessageClientConfigurationElement.ElementName; }
|
|
}
|
|
}
|
|
}
|