Exemplo n.º 1
0
        internal void WriteMsgWithLog(string msg, StatusNotificationType statusType)
        {
            Messenger.Default.Send(new StatusNotificationMessage(msg, statusType), LogMsgId);
            var logMsg = $"舞台灯光_{HeaderName}_{msg}";

            switch (statusType)
            {
            case StatusNotificationType.RInfo:
                _logWraper.Info(logMsg);
                break;

            case StatusNotificationType.NInfo:
                _logWraper.Info(logMsg);
                break;

            case StatusNotificationType.Error:
                _logWraper.Error(logMsg);
                break;

            default:
                throw new ArgumentOutOfRangeException(nameof(statusType), statusType, null);
            }
        }
Exemplo n.º 2
0
 public StatusNotificationMessage(object sender, object target, string notification, StatusNotificationType statusType)
     : base(sender, target, notification)
 {
     StatusType = statusType;
 }
Exemplo n.º 3
0
 public StatusNotificationMessage(object sender, string notification, StatusNotificationType statusType)
     : this(sender, null, notification, statusType)
 {
 }
Exemplo n.º 4
0
 public StatusNotificationMessage(string notification, StatusNotificationType statusType)
     : this(null, null, notification, statusType)
 {
 }