154 references to LoggingEventType
Microsoft.Build (118)
BackEnd\Components\Logging\LoggingService.cs (1)
986
if (loggingPacket.EventType ==
LoggingEventType
.CustomEvent
Instance\TaskFactories\TaskHostTask.cs (5)
526
case
LoggingEventType
.BuildErrorEvent:
529
case
LoggingEventType
.BuildWarningEvent:
532
case
LoggingEventType
.TaskCommandLineEvent:
533
case
LoggingEventType
.BuildMessageEvent:
536
case
LoggingEventType
.CustomEvent:
LogMessagePacketBase.cs (112)
39
/// An invalid eventId, used during initialization of a <see cref="
LoggingEventType
"/>.
271
private static Dictionary<
LoggingEventType
, MethodInfo> s_readMethodCache = new Dictionary<
LoggingEventType
, MethodInfo>();
276
private static Dictionary<
LoggingEventType
, MethodInfo> s_writeMethodCache = new Dictionary<
LoggingEventType
, MethodInfo>();
306
private
LoggingEventType
_eventType =
LoggingEventType
.Invalid;
389
internal
LoggingEventType
EventType
424
if (_eventType !=
LoggingEventType
.CustomEvent)
463
if (_eventType ==
LoggingEventType
.TargetFinishedEvent && _targetFinishedTranslator != null)
491
if (
LoggingEventType
.CustomEvent != _eventType)
519
if (_eventType ==
LoggingEventType
.TargetFinishedEvent && _targetFinishedTranslator != null)
622
LoggingEventType
.BuildErrorEvent => new BuildErrorEventArgs(null, null, null, -1, -1, -1, -1, null, null, null),
623
LoggingEventType
.BuildFinishedEvent => new BuildFinishedEventArgs(null, null, false),
624
LoggingEventType
.BuildMessageEvent => new BuildMessageEventArgs(null, null, null, MessageImportance.Normal),
625
LoggingEventType
.BuildStartedEvent => new BuildStartedEventArgs(null, null),
626
LoggingEventType
.BuildWarningEvent => new BuildWarningEventArgs(null, null, null, -1, -1, -1, -1, null, null, null),
627
LoggingEventType
.ProjectFinishedEvent => new ProjectFinishedEventArgs(null, null, null, false),
628
LoggingEventType
.ProjectStartedEvent => new ProjectStartedEventArgs(null, null, null, null, null, null),
629
LoggingEventType
.TargetStartedEvent => new TargetStartedEventArgs(null, null, null, null, null),
630
LoggingEventType
.TargetFinishedEvent => new TargetFinishedEventArgs(null, null, null, null, null, false),
631
LoggingEventType
.TaskStartedEvent => new TaskStartedEventArgs(null, null, null, null, null),
632
LoggingEventType
.TaskFinishedEvent => new TaskFinishedEventArgs(null, null, null, null, null, false),
633
LoggingEventType
.TaskCommandLineEvent => new TaskCommandLineEventArgs(null, null, MessageImportance.Normal),
634
LoggingEventType
.ResponseFileUsedEvent => new ResponseFileUsedEventArgs(null),
637
LoggingEventType
.AssemblyLoadEvent => new AssemblyLoadBuildEventArgs(),
638
LoggingEventType
.TaskParameterEvent => new TaskParameterEventArgs(0, null, null, true, default),
639
LoggingEventType
.ProjectEvaluationStartedEvent => new ProjectEvaluationStartedEventArgs(),
640
LoggingEventType
.ProjectEvaluationFinishedEvent => new ProjectEvaluationFinishedEventArgs(),
641
LoggingEventType
.ProjectImportedEvent => new ProjectImportedEventArgs(),
642
LoggingEventType
.TargetSkipped => new TargetSkippedEventArgs(),
643
LoggingEventType
.Telemetry => new TelemetryEventArgs(),
644
LoggingEventType
.ExtendedCustomEvent => new ExtendedCustomBuildEventArgs(),
645
LoggingEventType
.ExtendedBuildErrorEvent => new ExtendedBuildErrorEventArgs(),
646
LoggingEventType
.ExtendedBuildWarningEvent => new ExtendedBuildWarningEventArgs(),
647
LoggingEventType
.ExtendedBuildMessageEvent => new ExtendedBuildMessageEventArgs(),
648
LoggingEventType
.ExtendedCriticalBuildMessageEvent => new ExtendedCriticalBuildMessageEventArgs(),
649
LoggingEventType
.ExternalProjectStartedEvent => new ExternalProjectStartedEventArgs(null, null, null, null, null),
650
LoggingEventType
.ExternalProjectFinishedEvent => new ExternalProjectFinishedEventArgs(null, null, null, null, false),
651
LoggingEventType
.CriticalBuildMessage => new CriticalBuildMessageEventArgs(null, null, null, -1, -1, -1, -1, null, null, null),
652
LoggingEventType
.MetaprojectGenerated => new MetaprojectGeneratedEventArgs(null, null, null),
653
LoggingEventType
.PropertyInitialValueSet => new PropertyInitialValueSetEventArgs(),
654
LoggingEventType
.PropertyReassignment => new PropertyReassignmentEventArgs(),
655
LoggingEventType
.UninitializedPropertyRead => new UninitializedPropertyReadEventArgs(),
656
LoggingEventType
.GeneratedFileUsedEvent => new GeneratedFileUsedEventArgs(),
657
LoggingEventType
.BuildCheckMessageEvent => new BuildCheckResultMessage(),
658
LoggingEventType
.BuildCheckWarningEvent => new BuildCheckResultWarning(),
659
LoggingEventType
.BuildCheckErrorEvent => new BuildCheckResultError(),
660
LoggingEventType
.BuildCheckAcquisitionEvent => new BuildCheckAcquisitionEventArgs(),
661
LoggingEventType
.BuildCheckTracingEvent => new BuildCheckTracingEventArgs(),
662
LoggingEventType
.EnvironmentVariableReadEvent => new EnvironmentVariableReadEventArgs(),
663
LoggingEventType
.BuildSubmissionStartedEvent => new BuildSubmissionStartedEventArgs(),
664
LoggingEventType
.BuildCanceledEvent => new BuildCanceledEventArgs("Build canceled."),
677
private
LoggingEventType
GetLoggingEventId(BuildEventArgs eventArg)
682
return
LoggingEventType
.BuildMessageEvent;
686
return
LoggingEventType
.TaskCommandLineEvent;
691
return
LoggingEventType
.TaskParameterEvent;
696
return
LoggingEventType
.ProjectFinishedEvent;
700
return
LoggingEventType
.ProjectStartedEvent;
704
return
LoggingEventType
.ExternalProjectStartedEvent;
708
return
LoggingEventType
.ExternalProjectFinishedEvent;
714
return
LoggingEventType
.ProjectEvaluationFinishedEvent;
718
return
LoggingEventType
.ProjectEvaluationStartedEvent;
722
return
LoggingEventType
.ProjectImportedEvent;
726
return
LoggingEventType
.TargetSkipped;
730
return
LoggingEventType
.Telemetry;
734
return
LoggingEventType
.AssemblyLoadEvent;
738
return
LoggingEventType
.ExtendedCustomEvent;
742
return
LoggingEventType
.ExtendedBuildErrorEvent;
746
return
LoggingEventType
.ExtendedBuildWarningEvent;
750
return
LoggingEventType
.ExtendedBuildMessageEvent;
754
return
LoggingEventType
.CriticalBuildMessage;
758
return
LoggingEventType
.ExtendedCriticalBuildMessageEvent;
762
return
LoggingEventType
.MetaprojectGenerated;
766
return
LoggingEventType
.PropertyInitialValueSet;
770
return
LoggingEventType
.PropertyReassignment;
774
return
LoggingEventType
.UninitializedPropertyRead;
778
return
LoggingEventType
.GeneratedFileUsedEvent;
782
return
LoggingEventType
.BuildCheckMessageEvent;
786
return
LoggingEventType
.BuildCheckWarningEvent;
790
return
LoggingEventType
.BuildCheckErrorEvent;
794
return
LoggingEventType
.BuildCheckAcquisitionEvent;
798
return
LoggingEventType
.BuildCheckTracingEvent;
802
return
LoggingEventType
.EnvironmentVariableReadEvent;
806
return
LoggingEventType
.BuildSubmissionStartedEvent;
810
return
LoggingEventType
.BuildCanceledEvent;
815
return
LoggingEventType
.TargetStartedEvent;
819
return
LoggingEventType
.TargetFinishedEvent;
823
return
LoggingEventType
.TaskStartedEvent;
827
return
LoggingEventType
.TaskFinishedEvent;
831
return
LoggingEventType
.BuildFinishedEvent;
835
return
LoggingEventType
.BuildStartedEvent;
839
return
LoggingEventType
.BuildWarningEvent;
843
return
LoggingEventType
.BuildErrorEvent;
847
return
LoggingEventType
.ResponseFileUsedEvent;
851
return
LoggingEventType
.CustomEvent;
859
private void WriteEventToStream(BuildEventArgs buildEvent,
LoggingEventType
eventType, ITranslator translator)
862
if (eventType ==
LoggingEventType
.ProjectEvaluationStartedEvent)
867
else if (eventType ==
LoggingEventType
.ProjectEvaluationFinishedEvent)
885
case
LoggingEventType
.BuildMessageEvent:
888
case
LoggingEventType
.ResponseFileUsedEvent:
891
case
LoggingEventType
.TaskCommandLineEvent:
894
case
LoggingEventType
.BuildErrorEvent:
897
case
LoggingEventType
.BuildWarningEvent:
1210
private BuildEventArgs ReadEventFromStream(
LoggingEventType
eventType, ITranslator translator)
1213
if (eventType ==
LoggingEventType
.ProjectEvaluationStartedEvent)
1217
else if (eventType ==
LoggingEventType
.ProjectEvaluationFinishedEvent)
1233
LoggingEventType
.TaskCommandLineEvent => ReadTaskCommandLineEventFromStream(translator, message, helpKeyword, senderName),
1234
LoggingEventType
.BuildErrorEvent => ReadTaskBuildErrorEventFromStream(translator, message, helpKeyword, senderName),
1235
LoggingEventType
.BuildMessageEvent => ReadBuildMessageEventFromStream(translator, message, helpKeyword, senderName),
1236
LoggingEventType
.ResponseFileUsedEvent => ReadResponseFileUsedEventFromStream(translator, message, helpKeyword, senderName),
1237
LoggingEventType
.BuildWarningEvent => ReadBuildWarningEventFromStream(translator, message, helpKeyword, senderName),
Microsoft.Build.Engine.UnitTests (36)
BackEnd\NodePackets_Tests.cs (36)
84
VerifyLoggingPacket(buildFinished,
LoggingEventType
.BuildFinishedEvent);
85
VerifyLoggingPacket(buildStarted,
LoggingEventType
.BuildStartedEvent);
86
VerifyLoggingPacket(lowMessage,
LoggingEventType
.BuildMessageEvent);
87
VerifyLoggingPacket(taskStarted,
LoggingEventType
.TaskStartedEvent);
88
VerifyLoggingPacket(taskFinished,
LoggingEventType
.TaskFinishedEvent);
89
VerifyLoggingPacket(commandLine,
LoggingEventType
.TaskCommandLineEvent);
90
VerifyLoggingPacket(taskParameter,
LoggingEventType
.TaskParameterEvent);
91
VerifyLoggingPacket(warning,
LoggingEventType
.BuildWarningEvent);
92
VerifyLoggingPacket(error,
LoggingEventType
.BuildErrorEvent);
93
VerifyLoggingPacket(targetStarted,
LoggingEventType
.TargetStartedEvent);
94
VerifyLoggingPacket(targetFinished,
LoggingEventType
.TargetFinishedEvent);
95
VerifyLoggingPacket(targetSkipped,
LoggingEventType
.TargetSkipped);
96
VerifyLoggingPacket(projectStarted,
LoggingEventType
.ProjectStartedEvent);
97
VerifyLoggingPacket(projectFinished,
LoggingEventType
.ProjectFinishedEvent);
98
VerifyLoggingPacket(evaluationStarted,
LoggingEventType
.ProjectEvaluationStartedEvent);
99
VerifyLoggingPacket(evaluationFinished,
LoggingEventType
.ProjectEvaluationFinishedEvent);
100
VerifyLoggingPacket(externalStartedEvent,
LoggingEventType
.ExternalProjectStartedEvent);
101
VerifyLoggingPacket(externalFinishedEvent,
LoggingEventType
.ExternalProjectFinishedEvent);
102
VerifyLoggingPacket(assemblyLoad,
LoggingEventType
.AssemblyLoadEvent);
103
VerifyLoggingPacket(extError,
LoggingEventType
.ExtendedBuildErrorEvent);
104
VerifyLoggingPacket(extWarning,
LoggingEventType
.ExtendedBuildWarningEvent);
105
VerifyLoggingPacket(extMessage,
LoggingEventType
.ExtendedBuildMessageEvent);
106
VerifyLoggingPacket(extCustom,
LoggingEventType
.ExtendedCustomEvent);
107
VerifyLoggingPacket(criticalMessage,
LoggingEventType
.CriticalBuildMessage);
108
VerifyLoggingPacket(extCriticalMessage,
LoggingEventType
.ExtendedCriticalBuildMessageEvent);
109
VerifyLoggingPacket(propInit,
LoggingEventType
.PropertyInitialValueSet);
110
VerifyLoggingPacket(metaProjectGenerated,
LoggingEventType
.MetaprojectGenerated);
111
VerifyLoggingPacket(propReassign,
LoggingEventType
.PropertyReassignment);
112
VerifyLoggingPacket(responseFileUsed,
LoggingEventType
.ResponseFileUsedEvent);
113
VerifyLoggingPacket(uninitializedPropertyRead,
LoggingEventType
.UninitializedPropertyRead);
114
VerifyLoggingPacket(environmentVariableRead,
LoggingEventType
.EnvironmentVariableReadEvent);
115
VerifyLoggingPacket(generatedFileUsed,
LoggingEventType
.GeneratedFileUsedEvent);
116
VerifyLoggingPacket(buildSubmissionStarted,
LoggingEventType
.BuildSubmissionStartedEvent);
117
VerifyLoggingPacket(buildCheckTracing,
LoggingEventType
.BuildCheckTracingEvent);
118
VerifyLoggingPacket(buildCanceled,
LoggingEventType
.BuildCanceledEvent);
356
private static void VerifyLoggingPacket(BuildEventArgs buildEvent,
LoggingEventType
logEventType)