| 12345678910111213141516171819202122232425262728293031 |
- using System;
- using System.Diagnostics;
- using Cirrious.CrossCore.Platform;
- namespace FormulaOneApp.Classic.Windows
- {
- public class DebugTrace : IMvxTrace
- {
- public void Trace(MvxTraceLevel level, string tag, Func<string> message)
- {
- Debug.WriteLine(tag + ":" + level + ":" + message());
- }
- public void Trace(MvxTraceLevel level, string tag, string message)
- {
- Debug.WriteLine(tag + ":" + level + ":" + message);
- }
- public void Trace(MvxTraceLevel level, string tag, string message, params object[] args)
- {
- try
- {
- Debug.WriteLine(string.Format(tag + ":" + level + ":" + message, args));
- }
- catch (FormatException)
- {
- Trace(MvxTraceLevel.Error, tag, "Exception during trace of {0} {1} {2}", level, message);
- }
- }
- }
- }
|