diff options
author | sr55 <[email protected]> | 2018-05-08 21:31:26 +0100 |
---|---|---|
committer | sr55 <[email protected]> | 2018-05-08 21:31:26 +0100 |
commit | a6f3cd670f492a3474bf4695f1a8a6302fc3ed56 (patch) | |
tree | f862920629c676c23d095da6e9cb2877bb1f413d /win/CS/HandBrakeWPF/Services/Logging/Model/LogMessage.cs | |
parent | 1a16ebead7e49a214276859f53ce18a0c844f102 (diff) |
WinGui: Remove Logging abstraction from the Services library. Let the library consumers decide how to log instead utilising the log events instead.
Diffstat (limited to 'win/CS/HandBrakeWPF/Services/Logging/Model/LogMessage.cs')
-rw-r--r-- | win/CS/HandBrakeWPF/Services/Logging/Model/LogMessage.cs | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/win/CS/HandBrakeWPF/Services/Logging/Model/LogMessage.cs b/win/CS/HandBrakeWPF/Services/Logging/Model/LogMessage.cs new file mode 100644 index 000000000..7fa98d1d2 --- /dev/null +++ b/win/CS/HandBrakeWPF/Services/Logging/Model/LogMessage.cs @@ -0,0 +1,61 @@ +// -------------------------------------------------------------------------------------------------------------------- +// <copyright file="LogMessage.cs" company="HandBrake Project (http://handbrake.fr)"> +// This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License. +// </copyright> +// <summary> +// The message. +// </summary> +// -------------------------------------------------------------------------------------------------------------------- + +namespace HandBrakeWPF.Services.Logging.Model +{ + /// <summary> + /// An Immutable Log Entry. + /// </summary> + public class LogMessage + { + /// <summary> + /// Initializes a new instance of the <see cref="LogMessage"/> class. + /// </summary> + /// <param name="content"> + /// The content. + /// </param> + /// <param name="messageType"> + /// The message type. + /// </param> + /// <param name="logLevel"> + /// The log level. + /// </param> + /// <param name="messageIndex"> + /// The message Index. + /// </param> + public LogMessage(string content, LogMessageType messageType, LogLevel logLevel, long messageIndex) + { + this.Content = content; + this.MessageType = messageType; + this.LogLevel = logLevel; + this.MessageIndex = messageIndex; + } + + /// <summary> + /// Gets the content. + /// </summary> + public string Content { get; private set; } + + /// <summary> + /// Gets a value indicating whether this message was generated by the GUI. + /// If false, it was provided by libhb. + /// </summary> + public HandBrakeWPF.Services.Logging.Model.LogMessageType MessageType { get; private set; } + + /// <summary> + /// Gets the log level. + /// </summary> + public HandBrakeWPF.Services.Logging.Model.LogLevel LogLevel { get; private set; } + + /// <summary> + /// Gets the message index. + /// </summary> + public long MessageIndex { get; private set; } + } +} |