C# Class log4net.Util.CompositeProperties

This class aggregates several PropertiesDictionary collections together.

Provides a dictionary style lookup over an ordered list of PropertiesDictionary collections.

Show file Open project: nithinphilips/SMOz Class Usage Examples

Public Methods

Method Description
Add ( log4net.Util.ReadOnlyPropertiesDictionary properties ) : void

Add a Properties Dictionary to this composite collection

Properties dictionaries added first take precedence over dictionaries added later.

Flatten ( ) : log4net.Util.PropertiesDictionary

Flatten this composite collection into a single properties dictionary

Reduces the collection of ordered dictionaries to a single dictionary containing the resultant values for the keys.

this ( string key ) : object

Gets the value of a property

Looks up the value for the key specified. The PropertiesDictionary collections are searched in the order in which they were added to this collection. The value returned is the value held by the first collection that contains the specified key.

If none of the collections contain the specified key then null is returned.

Private Methods

Method Description
CompositeProperties ( ) : System

Constructor

Initializes a new instance of the CompositeProperties class.

Method Details

Add() public method

Add a Properties Dictionary to this composite collection

Properties dictionaries added first take precedence over dictionaries added later.

public Add ( log4net.Util.ReadOnlyPropertiesDictionary properties ) : void
properties log4net.Util.ReadOnlyPropertiesDictionary the properties to add
return void

Flatten() public method

Flatten this composite collection into a single properties dictionary

Reduces the collection of ordered dictionaries to a single dictionary containing the resultant values for the keys.

public Flatten ( ) : log4net.Util.PropertiesDictionary
return log4net.Util.PropertiesDictionary

this() public method

Gets the value of a property

Looks up the value for the key specified. The PropertiesDictionary collections are searched in the order in which they were added to this collection. The value returned is the value held by the first collection that contains the specified key.

If none of the collections contain the specified key then null is returned.

public this ( string key ) : object
key string
return object