예제 #1
0
        internal bool InterceptConsoleMessage(ConsoleMessage message)
        {
            if (message.Type != ConsoleType.Debug)
            {
                return(false);
            }

            string tag = message.GetText();

            if (ConsoleMessageTags.TryRemove(tag, out var handler))
            {
                handler();
                return(true);
            }

            return(false);
        }
예제 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ConsoleEventArgs"/> class.
 /// </summary>
 /// <param name="message">Message.</param>
 public ConsoleEventArgs(ConsoleMessage message) => Message = message;