Converted over other IApplicationEventHandlers to use the simpler ApplicationEventHandler
This commit is contained in:
@@ -10,7 +10,7 @@ namespace Umbraco.Core
|
||||
/// if you need these methods to execute even if either of these are not configured you can override the properties:
|
||||
/// ExecuteWhenApplicationNotConfigured and ExecuteWhenDatabaseNotConfigured
|
||||
/// </remarks>
|
||||
public class ApplicationEventHandler : IApplicationEventHandler
|
||||
public abstract class ApplicationEventHandler : IApplicationEventHandler
|
||||
{
|
||||
public void OnApplicationInitialized(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
|
||||
{
|
||||
|
||||
@@ -22,9 +22,9 @@ namespace Umbraco.Web
|
||||
/// <remarks>
|
||||
/// This would be better left internal, however
|
||||
/// </remarks>
|
||||
public sealed class CacheHelperApplicationEventListener : IApplicationEventHandler
|
||||
public sealed class CacheHelperApplicationEventListener : ApplicationEventHandler
|
||||
{
|
||||
public void OnApplicationInitialized(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
|
||||
protected override void ApplicationInitialized(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
|
||||
{
|
||||
if (applicationContext != null)
|
||||
{
|
||||
@@ -44,13 +44,6 @@ namespace Umbraco.Web
|
||||
}
|
||||
}
|
||||
|
||||
public void OnApplicationStarting(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
|
||||
{
|
||||
}
|
||||
|
||||
public void OnApplicationStarted(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public const string PartialViewCacheKey = "Umbraco.Web.PartialViewCacheKey";
|
||||
|
||||
@@ -16,18 +16,13 @@ namespace Umbraco.Web
|
||||
// and it needs to be manually registered - which we want to avoid, in order
|
||||
// to be as unobtrusive as possible
|
||||
|
||||
internal sealed class LegacyScheduledTasks : IApplicationEventHandler
|
||||
internal sealed class LegacyScheduledTasks : ApplicationEventHandler
|
||||
{
|
||||
Timer _pingTimer;
|
||||
Timer _publishingTimer;
|
||||
CacheItemRemovedCallback _onCacheRemove;
|
||||
|
||||
public void OnApplicationInitialized(UmbracoApplicationBase umbracoApplication, Core.ApplicationContext applicationContext)
|
||||
{
|
||||
// nothing yet
|
||||
}
|
||||
|
||||
public void OnApplicationStarting(UmbracoApplicationBase umbracoApplication, Core.ApplicationContext applicationContext)
|
||||
protected override void ApplicationStarting(UmbracoApplicationBase umbracoApplication, Core.ApplicationContext applicationContext)
|
||||
{
|
||||
if (umbracoApplication.Context == null)
|
||||
return;
|
||||
@@ -48,11 +43,6 @@ namespace Umbraco.Web
|
||||
AddTask(LOG_SCRUBBER_TASK_NAME, GetLogScrubbingInterval());
|
||||
}
|
||||
|
||||
public void OnApplicationStarted(UmbracoApplicationBase httpApplication, Core.ApplicationContext applicationContext)
|
||||
{
|
||||
// nothing
|
||||
}
|
||||
|
||||
#region Log Scrubbing
|
||||
|
||||
// this is a raw copy of the legacy code in all its uglyness
|
||||
|
||||
@@ -24,7 +24,7 @@ namespace Umbraco.Web.Search
|
||||
/// <summary>
|
||||
/// Used to wire up events for Examine
|
||||
/// </summary>
|
||||
public class ExamineEvents : ApplicationEventHandler
|
||||
public sealed class ExamineEvents : ApplicationEventHandler
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user