From 9497a7c7bd901686999da7bc1cba0b587186570b Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 16 Mar 2012 03:32:14 +0000 Subject: refactor: separate out console and status report generation parts of XEngine --- OpenSim/Region/ScriptEngine/XEngine/XEngine.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs index 3697f78..d4108d7 100644 --- a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs @@ -380,6 +380,11 @@ namespace OpenSim.Region.ScriptEngine.XEngine if (!(MainConsole.Instance.ConsoleScene == null || MainConsole.Instance.ConsoleScene == m_Scene)) return; + MainConsole.Instance.OutputFormat(GetStatusReport()); + } + + public string GetStatusReport() + { StringBuilder sb = new StringBuilder(); sb.AppendFormat("Status of XEngine instance for {0}\n", m_Scene.RegionInfo.RegionName); @@ -407,7 +412,7 @@ namespace OpenSim.Region.ScriptEngine.XEngine Listener l = AsyncCommandManager.GetListenerPlugin(this); sb.AppendFormat("Listeners : {0}\n", l.ListenerCount); - MainConsole.Instance.OutputFormat(sb.ToString()); + return sb.ToString(); } public void HandleShowScripts(string module, string[] cmdparams) -- cgit v1.1