From c9276f20518d3e6895ace534a1098f49eb2dbf1c Mon Sep 17 00:00:00 2001 From: Melanie Date: Sat, 16 Jan 2010 04:38:24 +0000 Subject: [PATCH] Shorten the names of the tags in monitorstats summary to the immediate type name sans namespace. Needs adjustment of scripts using these!. Request my name still uses full namespace path. --- .../CoreModules/Framework/Monitoring/MonitorModule.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/OpenSim/Region/CoreModules/Framework/Monitoring/MonitorModule.cs b/OpenSim/Region/CoreModules/Framework/Monitoring/MonitorModule.cs index d84f4ea56c..96d65d7676 100644 --- a/OpenSim/Region/CoreModules/Framework/Monitoring/MonitorModule.cs +++ b/OpenSim/Region/CoreModules/Framework/Monitoring/MonitorModule.cs @@ -112,7 +112,11 @@ namespace OpenSim.Region.CoreModules.Framework.Monitoring string xml = ""; foreach (IMonitor monitor in m_monitors) { - xml += "<" + monitor.ToString() + ">" + monitor.GetValue() + ""; + string elemName = monitor.ToString(); + if (elemName.StartsWith(monitor.GetType().Namespace)) + elemName = elemName.Substring(monitor.GetType().Namespace.Length + 1); + + xml += "<" + elemName + ">" + monitor.GetValue() + ""; } xml += "";