* refactor: make shutdown a template method in the same manner as startup, for consistency's sake

This commit is contained in:
Justin Clarke Casey
2008-10-03 16:06:00 +00:00
parent 0487c3158b
commit 170cb935cd
5 changed files with 13 additions and 14 deletions

View File

@@ -99,6 +99,11 @@ namespace OpenSim.Framework.Servers
/// Must be overriden by child classes for their own server specific startup behaviour.
/// </summary>
protected abstract void StartupSpecific();
/// <summary>
/// Should be overriden and referenced by descendents if they need to perform extra shutdown processing
/// </summary>
protected virtual void ShutdownSpecific() {}
/// <summary>
/// Print statistics to the logfile, if they are active
@@ -222,11 +227,13 @@ namespace OpenSim.Framework.Servers
/// <summary>
/// Should be overriden and referenced by descendents if they need to perform extra shutdown processing
/// </summary>
/// </summary>
public virtual void Shutdown()
{
ShutdownSpecific();
m_log.Info("[SHUTDOWN]: Shutdown processing on main thread complete. Exiting...");
Environment.Exit(0);
}