add activity log feature

This commit is contained in:
Luke Pulverenti
2014-08-10 18:13:17 -04:00
parent 0f508dab47
commit e84ba17b9f
59 changed files with 1539 additions and 303 deletions

View File

@@ -28,6 +28,11 @@ namespace MediaBrowser.Common.Implementations.Configuration
/// </summary>
public event EventHandler<EventArgs> ConfigurationUpdated;
/// <summary>
/// Occurs when [configuration updating].
/// </summary>
public event EventHandler<ConfigurationUpdateEventArgs> NamedConfigurationUpdating;
/// <summary>
/// Occurs when [named configuration updated].
/// </summary>
@@ -217,6 +222,13 @@ namespace MediaBrowser.Common.Implementations.Configuration
throw new ArgumentException("Expected configuration type is " + configurationType.Name);
}
EventHelper.FireEventIfNotNull(NamedConfigurationUpdating, this, new ConfigurationUpdateEventArgs
{
Key = key,
NewConfiguration = configuration
}, Logger);
_configurations.AddOrUpdate(key, configuration, (k, v) => configuration);
var path = GetConfigurationFile(key);