4 types derived from BuildEventArgs
Microsoft.Build.Framework (4)
BuildCheck\BuildCheckEventArgs.cs (1)
15internal abstract class BuildCheckEventArgs : BuildEventArgs
LazyFormattedBuildEventArgs.cs (1)
15public class LazyFormattedBuildEventArgs : BuildEventArgs
Telemetry\WorkerNodeTelemetryEventArgs.cs (1)
10internal sealed class WorkerNodeTelemetryEventArgs(IWorkerNodeTelemetryData workerNodeTelemetryData) : BuildEventArgs
TelemetryEventArgs.cs (1)
14public sealed class TelemetryEventArgs : BuildEventArgs
183 references to BuildEventArgs
Microsoft.Build (145)
BackEnd\BuildManager\BuildManager.cs (5)
206private readonly Dictionary<int, BuildEventArgs> _projectStartedEvents; 313_projectStartedEvents = new Dictionary<int, BuildEventArgs>(); 1105foreach (KeyValuePair<int, BuildEventArgs> projectStartedEvent in _projectStartedEvents) 2732BuildEventContext buildEventContext = _projectStartedEvents.TryGetValue(result.SubmissionId, out BuildEventArgs? buildEventArgs) 3141if (_projectStartedEvents.TryGetValue(e.BuildEventContext!.SubmissionId, out var originalArgs))
BackEnd\Components\Communications\LogMessagePacket.cs (4)
35internal LogMessagePacket(KeyValuePair<int, BuildEventArgs>? nodeBuildEvent) 68protected override void WriteEventToStream(BuildEventArgs buildEvent, LoggingEventType eventType, ITranslator translator) 84protected override BuildEventArgs ReadEventFromStream(LoggingEventType eventType, ITranslator translator) 495protected override void TranslateAdditionalProperties(ITranslator translator, LoggingEventType eventType, BuildEventArgs buildEvent)
BackEnd\Components\Logging\BuildEventArgTransportSink.cs (3)
124public void Consume(BuildEventArgs buildEvent) 133public void Consume(BuildEventArgs buildEvent, int sinkId) 147LogMessagePacket logPacket = new LogMessagePacket(new KeyValuePair<int, BuildEventArgs>(sinkId, buildEvent));
BackEnd\Components\Logging\CentralForwardingLogger.cs (1)
115private void EventSource_AnyEventRaised(object sender, BuildEventArgs buildEvent)
BackEnd\Components\Logging\EventRedirectorToSink.cs (1)
51void IEventRedirector.ForwardEvent(BuildEventArgs buildEvent)
BackEnd\Components\Logging\EventSourceSink.cs (3)
221public void Consume(BuildEventArgs buildEvent, int sinkId) 234public void Consume(BuildEventArgs buildEvent) 403private void RaiseAnyEvent(BuildEventArgs buildEvent)
BackEnd\Components\Logging\ILoggingService.cs (3)
394void LogBuildEvent(BuildEventArgs buildEvent); 722void Consume(BuildEventArgs buildEvent, int sinkId); 727void Consume(BuildEventArgs buildEvent);
BackEnd\Components\Logging\LoggingContext.cs (1)
288internal void LogBuildEvent(BuildEventArgs buildEvent)
BackEnd\Components\Logging\LoggingService.cs (13)
1237public void LogBuildEvent(BuildEventArgs buildEvent) 1400private static WarningsConfigKey GetWarningsConfigKey(BuildEventArgs buildEventArgs) 1594BuildEventArgs buildEventArgs = loggingEvent as BuildEventArgs ?? (loggingEvent as KeyValuePair<int, BuildEventArgs>?)?.Value; 1725if (loggingEvent is BuildEventArgs) 1729else if (loggingEvent is KeyValuePair<int, BuildEventArgs> loggingEventKeyValuePair) 1734loggingEventKeyValuePair = new KeyValuePair<int, BuildEventArgs>(loggingEventKeyValuePair.Key, buildEventArgs); 1744private void RouteBuildEvent(KeyValuePair<int, BuildEventArgs> nodeEvent) 1763private void RouteBuildEvent(BuildEventArgs eventArg) 1942private void TryRaiseProjectStartedEvent(BuildEventArgs args) 1959private void TryRaiseProjectFinishedEvent(BuildEventArgs args) 1976private string GetAndVerifyProjectFileFromContext(BuildEventArgs eventArgs, bool allowCacheMiss)
BackEnd\Components\RequestBuilder\IntrinsicTasks\ItemGroupLoggingHelper.cs (1)
52BuildEventArgs.ResourceStringFormatter = ResourceUtilities.FormatResourceStringIgnoreCodeAndKeyword;
BackEnd\Components\RequestBuilder\TaskHost.cs (1)
1116internal bool IsEventSerializable(BuildEventArgs e)
BackEnd\Node\OutOfProcNode.cs (1)
606BuildEventArgs buildEvent = logMessage.NodeBuildEvent.Value.Value;
BuildCheck\API\BuildCheckResult.cs (1)
30internal BuildEventArgs ToEventArgs(CheckResultSeverity severity)
BuildCheck\Infrastructure\BuildCheckBuildEventHandler.cs (6)
18private Dictionary<Type, Action<BuildEventArgs>> _eventHandlers; 19private readonly Dictionary<Type, Action<BuildEventArgs>> _eventHandlersFull; 20private readonly Dictionary<Type, Action<BuildEventArgs>> _eventHandlersRestore; 55public void HandleBuildEvent(BuildEventArgs e) 57if (_eventHandlers.TryGetValue(e.GetType(), out Action<BuildEventArgs>? handler)) 182private BuildEventContext GetBuildEventContext(BuildEventArgs e) => e.BuildEventContext
BuildCheck\Infrastructure\BuildCheckConnectorLogger.cs (1)
50private void EventSource_AnyEventRaised(object sender, BuildEventArgs e)
BuildCheck\Infrastructure\BuildCheckForwardingLogger.cs (1)
52public void EventSource_AnyEventRaised(object sender, BuildEventArgs buildEvent)
BuildCheck\Infrastructure\BuildCheckManagerProvider.cs (4)
650foreach (BuildEventArgs deferredArgs in list) 660private readonly Dictionary<int, List<BuildEventArgs>> _deferredEvalDiagnostics = new(); 677void IResultReporter.ReportResult(BuildEventArgs eventArgs, ICheckContext checkContext) 792void ReportResult(BuildEventArgs result, ICheckContext checkContext);
BuildCheck\Infrastructure\CheckContext\CheckDispatchingContext.cs (1)
30public void DispatchBuildEvent(BuildEventArgs buildEvent)
BuildCheck\Infrastructure\CheckContext\CheckLoggingContext.cs (1)
25public void DispatchBuildEvent(BuildEventArgs buildEvent)
BuildCheck\Infrastructure\CheckContext\ICheckContext.cs (2)
26/// Dispatch a <see cref="BuildEventArgs"/>. 28void DispatchBuildEvent(BuildEventArgs buildEvent);
BuildCheck\Infrastructure\CheckWrapper.cs (1)
158BuildEventArgs eventArgs = result.ToEventArgs(config.Severity);
Errors\InternalLoggerException.cs (6)
87BuildEventArgs e, 118e = (BuildEventArgs)info.GetValue("e", typeof(BuildEventArgs)); 188public BuildEventArgs BuildEventArgs 251BuildEventArgs e, 266private BuildEventArgs e;
Instance\TaskFactories\TaskHostTask.cs (1)
681BuildEventArgs buildEvent = logMessagePacket.NodeBuildEvent.Value.Value;
Instance\TaskFactoryEngineContext.cs (1)
381internal bool IsEventSerializable(BuildEventArgs e)
Logging\BinaryLogger\BinaryLogger.cs (4)
584private void EventSource_AnyEventRaised(object sender, BuildEventArgs e) 589private void Write(BuildEventArgs e) 611private static bool DoNotWriteToBinlog(BuildEventArgs e) 616private void CollectImports(BuildEventArgs e)
Logging\BinaryLogger\BuildEventArgsReader.cs (41)
60typeof(BuildEventArgs).GetField("threadId", BindingFlags.Instance | BindingFlags.NonPublic); 62typeof(BuildEventArgs).GetField("senderName", BindingFlags.Instance | BindingFlags.NonPublic); 67/// <param name="binaryReader">The <see cref="BinaryReader"/> to read <see cref="BuildEventArgs"/> from.</param> 209/// The next <see cref="BuildEventArgs"/>. 212public BuildEventArgs? Read() 215BuildEventArgs? result = null; 299private BuildEventArgs? ReadBuildEventArgs(BinaryLogRecordKind recordKind) 523private BuildEventArgs ReadProjectImportedEventArgs() 554private BuildEventArgs ReadTargetSkippedEventArgs() 609private BuildEventArgs ReadBuildStartedEventArgs() 622private BuildEventArgs ReadBuildFinishedEventArgs() 636private BuildEventArgs ReadBuildSubmissionStartedEventArgs() 659private BuildEventArgs ReadProjectEvaluationStartedEventArgs() 676private BuildEventArgs ReadProjectEvaluationFinishedEventArgs() 734private BuildEventArgs ReadProjectStartedEventArgs() 778private BuildEventArgs ReadProjectFinishedEventArgs() 794private BuildEventArgs ReadTargetStartedEventArgs() 817private BuildEventArgs ReadTargetFinishedEventArgs() 839private BuildEventArgs ReadTaskStartedEventArgs() 861private BuildEventArgs ReadTaskFinishedEventArgs() 881private BuildEventArgs ReadBuildErrorEventArgs() 886BuildEventArgs e; 933private BuildEventArgs ReadBuildWarningEventArgs() 938BuildEventArgs e; 985private BuildEventArgs ReadBuildMessageEventArgs() 989BuildEventArgs e; 1039private BuildEventArgs ReadTaskCommandLineEventArgs() 1055private BuildEventArgs ReadTaskParameterEventArgs() 1081private BuildEventArgs ReadCriticalBuildMessageEventArgs() 1085BuildEventArgs e; 1131private BuildEventArgs ReadEnvironmentVariableReadEventArgs() 1146BuildEventArgs e = new EnvironmentVariableReadEventArgs( 1157private BuildEventArgs ReadResponseFileUsedEventArgs() 1167private BuildEventArgs ReadPropertyReassignmentEventArgs() 1193private BuildEventArgs ReadUninitializedPropertyReadEventArgs() 1209private BuildEventArgs ReadPropertyInitialValueSetEventArgs() 1258private BuildEventArgs ReadBuildCheckTracingEventArgs() 1271private BuildEventArgs ReadBuildCheckAcquisitionEventArgs() 1282private BuildEventArgs ReadBuildCanceledEventArgs() 1291private BuildEventArgs ReadLoggersRegisteredEventArgs() 1455private void SetCommonFields(BuildEventArgs buildEventArgs, BuildEventArgsFields fields)
Logging\BinaryLogger\BuildEventArgsWriter.cs (5)
144public void Write(BuildEventArgs e) 203private BinaryLogRecordKind WriteCore(BuildEventArgs e) 663private void WriteBuildEventArgsFields(BuildEventArgs e, bool writeMessage = true, bool writeLineAndColumn = false) 675private void WriteBaseFields(BuildEventArgs e, BuildEventArgsFieldFlags flags) 862private static BuildEventArgsFieldFlags GetBuildEventArgsFieldFlags(BuildEventArgs e, bool writeMessage = true)
Logging\BinaryLogger\EventArgsDispatcher.cs (1)
107public void Dispatch(BuildEventArgs buildEvent)
Logging\BinaryLogger\ProjectImportsCollector.cs (1)
173BuildEventArgs args = new BuildMessageEventArgs(
Logging\DistributedLoggers\ConfigurableForwardingLogger.cs (3)
335private void ForwardEvent(object sender, BuildEventArgs e) 370/// <param name="e">The <see cref="BuildEventArgs"/> to forward.</param> 371protected virtual void ForwardToCentralLogger(BuildEventArgs e)
Logging\NullCentralLogger.cs (1)
54public void AnyEventRaisedHandler(object sender, BuildEventArgs e)
Logging\ParallelLogger\ParallelConsoleLogger.cs (12)
439private void ShowErrorWarningSummary(IEnumerable<BuildEventArgs> listToProcess) 442var groupByProjectEntryPoint = new Dictionary<ErrorWarningSummaryDictionaryKey, List<BuildEventArgs>>(); 445foreach (BuildEventArgs errorWarningEventArgs in listToProcess) 473errorWarningEventListByTarget = new List<BuildEventArgs>(); 483foreach (KeyValuePair<ErrorWarningSummaryDictionaryKey, List<BuildEventArgs>> valuePair in groupByProjectEntryPoint) 510foreach (BuildEventArgs errorWarningEvent in valuePair.Value) 749/// <param name="e">A <see cref="BuildEventArgs"/> object containing information about the build event.</param> 751internal void WriteProperties(BuildEventArgs e, IEnumerable properties) 816/// <param name="e">A <see cref="BuildEventArgs"/> object containing information about the build event.</param> 818internal void WriteItems(BuildEventArgs e, IEnumerable items) 1030internal string FindLogOutputProperties(BuildEventArgs e) 1383private bool WriteTargetMessagePrefix(BuildEventArgs e, BuildEventContext context, DateTime timeStamp)
Logging\ProfilerLogger.cs (1)
93private void ProjectEvaluationFinishedRaised(object sender, BuildEventArgs e)
Logging\ReusableLogger.cs (1)
578private void AnyEventRaisedHandler(object sender, BuildEventArgs e) => AnyEventRaised?.Invoke(sender, e);
Logging\TerminalLogger\ForwardingTerminalLogger.cs (1)
84public void ForwardEventUnconditionally(object sender, BuildEventArgs e)
src\msbuild\src\Shared\LogMessagePacketBase.cs (11)
277private BuildEventArgs _buildEvent; 291internal LogMessagePacketBase(KeyValuePair<int, BuildEventArgs>? nodeBuildEvent) 328internal KeyValuePair<int, BuildEventArgs>? NodeBuildEvent 332return new KeyValuePair<int, BuildEventArgs>(_sinkId, _buildEvent); 439/// Every <see cref="BuildEventArgs"/> defines <c>WriteToStream</c> / <c>CreateFromStream</c>, so the 449protected virtual void TranslateAdditionalProperties(ITranslator translator, LoggingEventType eventType, BuildEventArgs buildEvent) 458private BuildEventArgs GetBuildEventArgFromId() 505_ => Assumed.Unreachable<BuildEventArgs>($"Should not get to the default of GetBuildEventArgFromId ID: {_eventType}") 515private LoggingEventType GetLoggingEventId(BuildEventArgs eventArg) 703protected virtual void WriteEventToStream(BuildEventArgs buildEvent, LoggingEventType eventType, ITranslator translator) 841protected virtual BuildEventArgs ReadEventFromStream(LoggingEventType eventType, ITranslator translator)
Microsoft.Build.Framework (4)
IEventRedirector.cs (1)
16void ForwardEvent(BuildEventArgs buildEvent);
IEventSource.cs (1)
83public delegate void AnyEventHandler(object sender, BuildEventArgs e);
Telemetry\IBuildEventArgsTelemetryProvider.cs (2)
8/// <see cref="BuildEventArgs"/> they were processing when they failed - most notably 20/// Gets the simple type name of the <see cref="BuildEventArgs"/> that was being delivered
Microsoft.Build.Tasks.Core (17)
AssemblyDependency\Node\OutOfProcRarClient.cs (1)
76BuildEventArgs buildEvent = logMessagePacket.NodeBuildEvent?.Value!;
AssemblyDependency\Node\RarNodeBuildEngine.cs (5)
46private readonly Channel<BuildEventArgs> _eventChannel; 57_eventChannel = Channel.CreateUnbounded<BuildEventArgs>(new UnboundedChannelOptions 130BuildEventArgs buildEventArgs = await _eventChannel.Reader.ReadAsync(cancellationToken).ConfigureAwait(false); 131_buildEvents.EventQueue.Add(new LogMessagePacketBase(new KeyValuePair<int, BuildEventArgs>(0, buildEventArgs))); 165private void LogEvent(BuildEventArgs e)
src\msbuild\src\Shared\LogMessagePacketBase.cs (11)
277private BuildEventArgs _buildEvent; 291internal LogMessagePacketBase(KeyValuePair<int, BuildEventArgs>? nodeBuildEvent) 328internal KeyValuePair<int, BuildEventArgs>? NodeBuildEvent 332return new KeyValuePair<int, BuildEventArgs>(_sinkId, _buildEvent); 439/// Every <see cref="BuildEventArgs"/> defines <c>WriteToStream</c> / <c>CreateFromStream</c>, so the 449protected virtual void TranslateAdditionalProperties(ITranslator translator, LoggingEventType eventType, BuildEventArgs buildEvent) 458private BuildEventArgs GetBuildEventArgFromId() 505_ => Assumed.Unreachable<BuildEventArgs>($"Should not get to the default of GetBuildEventArgFromId ID: {_eventType}") 515private LoggingEventType GetLoggingEventId(BuildEventArgs eventArg) 703protected virtual void WriteEventToStream(BuildEventArgs buildEvent, LoggingEventType eventType, ITranslator translator) 841protected virtual BuildEventArgs ReadEventFromStream(LoggingEventType eventType, ITranslator translator)
Microsoft.Build.Utilities.Core (1)
MuxLogger.cs (1)
1205private void RaiseAnyEvent(object sender, BuildEventArgs buildEvent)
MSBuild (13)
OutOfProcTaskHostNode.cs (2)
1724private void SendBuildEvent(BuildEventArgs e) 1740LogMessagePacketBase logMessage = new(new KeyValuePair<int, BuildEventArgs>(_currentConfiguration.NodeId, e));
src\msbuild\src\Shared\LogMessagePacketBase.cs (11)
277private BuildEventArgs _buildEvent; 291internal LogMessagePacketBase(KeyValuePair<int, BuildEventArgs>? nodeBuildEvent) 328internal KeyValuePair<int, BuildEventArgs>? NodeBuildEvent 332return new KeyValuePair<int, BuildEventArgs>(_sinkId, _buildEvent); 439/// Every <see cref="BuildEventArgs"/> defines <c>WriteToStream</c> / <c>CreateFromStream</c>, so the 449protected virtual void TranslateAdditionalProperties(ITranslator translator, LoggingEventType eventType, BuildEventArgs buildEvent) 458private BuildEventArgs GetBuildEventArgFromId() 505_ => Assumed.Unreachable<BuildEventArgs>($"Should not get to the default of GetBuildEventArgFromId ID: {_eventType}") 515private LoggingEventType GetLoggingEventId(BuildEventArgs eventArg) 703protected virtual void WriteEventToStream(BuildEventArgs buildEvent, LoggingEventType eventType, ITranslator translator) 841protected virtual BuildEventArgs ReadEventFromStream(LoggingEventType eventType, ITranslator translator)
NuGet.Build.Tasks (3)
ConsoleOutLogMessage.cs (3)
32/// <inheritdoc cref="BuildEventArgs.HelpKeyword" /> 41/// <inheritdoc cref="BuildEventArgs.Message" /> 47/// <inheritdoc cref="BuildEventArgs.SenderName" />