Beispiel #1
0
        private void AddModulesSection()
        {
            var section = new ValueDiagnosticsSection
            {
                Headline = "Modules",
            };

            section.Value.AppendLine("- Enabled modules");
            foreach (var module in _moduleManager.EnabledModules)
            {
                section.Value.AppendLine($"   - {module.Name}");
            }

            section.Value.AppendLine("- Disabled modules");
            foreach (var module in _moduleManager.DisabledModules)
            {
                section.Value.AppendLine($"   - {module.Name}");
            }

            section.Value.AppendLine("- Autorun modules");
            // TODO:

            section.Value.AppendLine("- Boot sequence");
            foreach (var module in _bootSequenceFactory.New())
            {
                section.Value.AppendLine($"   - {module.Name}");
            }

            _diagnostics.AddSection("Modules", section);
        }
Beispiel #2
0
        private void AddFlagsSection()
        {
            var section = new ValueDiagnosticsSection
            {
                Headline = "Flags",
            };

            section.Value.AppendLine($"- diagnostics: {_runtimeFlags.Diagnostics}");
            section.Value.AppendLine($"- verbose: {_runtimeFlags.Verbose}");

            _diagnostics.AddSection("Flags", section);
        }
Beispiel #3
0
        private void AddTimetableSection()
        {
            var section = new ValueDiagnosticsSection
            {
                Headline = "Timetable",
            };

            foreach (var lapTime in _diagnostics.Timetable)
            {
                section.Value.AppendLine($"{lapTime.At:s} {lapTime.Elapsed} {lapTime.Name}");
            }

            _diagnostics.ClearTimetable();

            _diagnostics.AddSection(TimetableSectionKey, section);
        }