blob: 10560e0342e21cf98e90e499b2b06e6a21611aca (
plain)
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight .c { color: #888888 } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */
.highlight .k { color: #008800; font-weight: bold } /* Keyword */
.highlight .ch { color: #888888 } /* Comment.Hashbang */
.highlight .cm { color: #888888 } /* Comment.Multiline */
.highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */
.highlight .cpf { color: #888888 } /* Comment.PreprocFile */
.highlight .c1 { color: #888888 } /* Comment.Single */
.highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */
.highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */
.highlight .gr { color: #aa0000 } /* Generic.Error */
.highlight .gh { color: #333333 } /* Generic.Heading */
.highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */
.highlight .go { color: #888888 } /* Generic.Output */
.highlight .gp { color: #555555 } /* Generic.Prompt */
.highlight .gs { font-weight: bold } /* Generic.Strong */
.highlight .gu { color: #666666 } /* Generic.Subheading */
.highlight .gt { color: #aa0000 } /* Generic.Traceback */
.highlight .kc { color: #008800; font-weight: bold } /* Keyword.Constant */
.highlight .kd { color: #008800; font-weight: bold } /* Keyword.Declaration */
.highlight .kn { color: #008800; font-weight: bold } /* Keyword.Namespace */
.highlight .kp { color: #008800 } /* Keyword.Pseudo */
.highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */
.highlighusing System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Tango.BL.Entities;
using Tango.BL.Enumerations;
using Tango.PMR.Diagnostics;
namespace Tango.PPC.Common.EventLogging
{
/// <summary>
/// Represents a database events logger.
/// </summary>
public interface IEventLogger
{
/// <summary>
/// Occurs when a new machine event has been received.
/// </summary>
event EventHandler<MachinesEvent> EventReceived;
/// <summary>
/// Occurs when a machine event has been resolved.
/// </summary>
event EventHandler<MachinesEvent> EventResolved;
/// <summary>
/// Logs the specified machine event.
/// </summary>
/// <param name="machineEvent">The machine event.</param>
void Log(MachinesEvent machineEvent);
/// <summary>
/// Logs the specified event type.
/// </summary>
/// <param name="eventType">Type of the event.</param>
/// <param name="message">The message.</param>
void Log(EventTypes eventType, String message);
/// <summary>
/// Logs the specified hardware event.
/// </summary>
/// <param name="hardwareEvent">The hardware event.</param>
void Log(Event hardwareEvent);
/// <summary>
/// Logs the specified exception using the <see cref="EventTypes.ApplicationException"/>.
/// </summary>
/// <param name="exception">The exception.</param>
void Log(Exception exception);
/// <summary>
/// Logs the specified exception using the <see cref="EventTypes.ApplicationException"/>.
/// </summary>
/// <param name="exception">The exception.</param>
void Log(Exception exception, String description);
/// <summary>
/// Logs the specified message using the <see cref="EventTypes.ApplicationInformation"/>.
/// </summary>
/// <param name="message">The message.</param>
void Log(String message);
/// <summary>
/// Immediately saves all pending events to database.
/// </summary>
void FlushAll();
}
}
|