summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrakeWPF/Services/Logging/Interfaces/ILog.cs
blob: d82a1ed0d0163f9a59654bf7a2e0491514258ad6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
// --------------------------------------------------------------------------------------------------------------------
// <copyright file="ILog.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>
//   Defines the ILog type.
// </summary>
// --------------------------------------------------------------------------------------------------------------------

namespace HandBrakeWPF.Services.Logging.Interfaces
{
    using System;
    using System.Collections.Generic;

    using HandBrake.Worker.Logging.Interfaces;
    using HandBrake.Worker.Logging.Models;

    using HandBrakeWPF.Services.Logging.Model;

    using LogEventArgs = HandBrakeWPF.Services.Logging.EventArgs.LogEventArgs;

    /// <summary>
    /// The Log interface.
    /// </summary>
    public interface ILog : ILogHandler
    {
        /// <summary>
        /// The message logged.
        /// </summary>
        event EventHandler<LogEventArgs> MessageLogged;

        /// <summary>
        /// The log reset event
        /// </summary>
        event EventHandler LogReset;

        /// <summary>
        /// Enable logging for this worker process.
        /// </summary>
        /// <param name="config">
        /// Configuration for the logger.
        /// </param>
        /// <remarks>
        /// If this is not called, all log messages from libhb will be ignored.
        /// </remarks>
        void ConfigureLogging(LogHandlerConfig config);

        /// <summary>
        /// Log a message.
        /// </summary>
        /// <param name="content">
        /// The content of the log message,
        /// </param>
        void LogMessage(string content);
    }
}