コード例 #1
0
ファイル: IOService.cs プロジェクト: someone243/CupCake
 private void LogPlatform_LogReceived(object sender, LogEventArgs e)
 {
     if (e.Priority >= this.MinPriority)
     {
         string output = this.SyntaxProvider.ParseOutput(e);
         var outputEvent = new OutputEvent(output);
         this.Events.Raise(outputEvent);
     }
 }
コード例 #2
0
 public string ParseOutput(LogEventArgs e)
 {
     return "[" + DateTime.Now.ToLongTimeString() + "] (" + e.Priority + ") <" + e.Source + "> " + e.Message;
 }
コード例 #3
0
ファイル: LogPlatform.cs プロジェクト: KylerM/CupCake
 protected virtual void OnLogReceived(LogEventArgs e)
 {
     EventHandler<LogEventArgs> handler = this.LogReceived;
     if (handler != null) handler(this, e);
 }
コード例 #4
0
 public string ParseOutput(LogEventArgs e)
 {
     return "[" + e.Priority + "] " + e.Source + ": " + e.Message;
 }