139 references to BinaryLogRecordKind
Microsoft.Build (129)
Logging\BinaryLogger\BinaryLogger.cs (3)
328streamToEmbed => eventArgsWriter.WriteBlob(BinaryLogRecordKind.ProjectImportArchive, streamToEmbed), 342stream.WriteByte((byte)BinaryLogRecordKind.EndOfFile); 349private void RawEvents_LogDataSliceReceived(BinaryLogRecordKind recordKind, Stream stream)
Logging\BinaryLogger\BinaryLogReplayEventSource.cs (4)
26event Action<BinaryLogRecordKind, Stream>? RawLogRecordReceived; 279instance.RecordKind != BinaryLogRecordKind.EndOfFile) 335private Action<BinaryLogRecordKind, Stream>? _rawLogRecordReceived; 337event Action<BinaryLogRecordKind, Stream>? IBinaryLogReplaySource.RawLogRecordReceived
Logging\BinaryLogger\BuildEventArgsReader.cs (55)
157internal readonly record struct RawRecord(BinaryLogRecordKind RecordKind, Stream Stream); 179BinaryLogRecordKind recordKind = PreprocessRecordsTillNextEvent(IsTextualDataRecord); 181if (recordKind == BinaryLogRecordKind.EndOfFile) 218BinaryLogRecordKind recordKind = PreprocessRecordsTillNextEvent(IsAuxiliaryRecord); 220if (recordKind == BinaryLogRecordKind.EndOfFile) 260BinaryLogRecordKind localRecordKind = recordKind; 285void HandleError(FormatErrorMessage msgFactory, bool noThrow, ReaderErrorType readerErrorType, BinaryLogRecordKind recordKind, Exception? innerException = null) 299private BuildEventArgs? ReadBuildEventArgs(BinaryLogRecordKind recordKind) 302BinaryLogRecordKind.BuildStarted => ReadBuildStartedEventArgs(), 303BinaryLogRecordKind.BuildFinished => ReadBuildFinishedEventArgs(), 304BinaryLogRecordKind.BuildSubmissionStarted => ReadBuildSubmissionStartedEventArgs(), 305BinaryLogRecordKind.ProjectStarted => ReadProjectStartedEventArgs(), 306BinaryLogRecordKind.ProjectFinished => ReadProjectFinishedEventArgs(), 307BinaryLogRecordKind.TargetStarted => ReadTargetStartedEventArgs(), 308BinaryLogRecordKind.TargetFinished => ReadTargetFinishedEventArgs(), 309BinaryLogRecordKind.TaskStarted => ReadTaskStartedEventArgs(), 310BinaryLogRecordKind.TaskFinished => ReadTaskFinishedEventArgs(), 311BinaryLogRecordKind.Error => ReadBuildErrorEventArgs(), 312BinaryLogRecordKind.Warning => ReadBuildWarningEventArgs(), 313BinaryLogRecordKind.Message => ReadBuildMessageEventArgs(), 314BinaryLogRecordKind.CriticalBuildMessage => ReadCriticalBuildMessageEventArgs(), 315BinaryLogRecordKind.TaskCommandLine => ReadTaskCommandLineEventArgs(), 316BinaryLogRecordKind.TaskParameter => ReadTaskParameterEventArgs(), 317BinaryLogRecordKind.ProjectEvaluationStarted => ReadProjectEvaluationStartedEventArgs(), 318BinaryLogRecordKind.ProjectEvaluationFinished => ReadProjectEvaluationFinishedEventArgs(), 319BinaryLogRecordKind.ProjectImported => ReadProjectImportedEventArgs(), 320BinaryLogRecordKind.TargetSkipped => ReadTargetSkippedEventArgs(), 321BinaryLogRecordKind.EnvironmentVariableRead => ReadEnvironmentVariableReadEventArgs(), 322BinaryLogRecordKind.ResponseFileUsed => ReadResponseFileUsedEventArgs(), 323BinaryLogRecordKind.PropertyReassignment => ReadPropertyReassignmentEventArgs(), 324BinaryLogRecordKind.UninitializedPropertyRead => ReadUninitializedPropertyReadEventArgs(), 325BinaryLogRecordKind.PropertyInitialValueSet => ReadPropertyInitialValueSetEventArgs(), 326BinaryLogRecordKind.AssemblyLoad => ReadAssemblyLoadEventArgs(), 327BinaryLogRecordKind.BuildCheckMessage => ReadBuildMessageEventArgs(), 328BinaryLogRecordKind.BuildCheckWarning => ReadBuildWarningEventArgs(), 329BinaryLogRecordKind.BuildCheckError => ReadBuildErrorEventArgs(), 330BinaryLogRecordKind.BuildCheckTracing => ReadBuildCheckTracingEventArgs(), 331BinaryLogRecordKind.BuildCheckAcquisition => ReadBuildCheckAcquisitionEventArgs(), 332BinaryLogRecordKind.BuildCanceled => ReadBuildCanceledEventArgs(), 341private BinaryLogRecordKind PreprocessRecordsTillNextEvent(Func<BinaryLogRecordKind, bool> isPreprocessRecord) 345BinaryLogRecordKind recordKind = (BinaryLogRecordKind)ReadInt32(); 352if (recordKind == BinaryLogRecordKind.String) 356else if (recordKind == BinaryLogRecordKind.NameValueList) 361else if (recordKind == BinaryLogRecordKind.ProjectImportArchive) 368recordKind = (BinaryLogRecordKind)ReadInt32(); 374private static bool IsAuxiliaryRecord(BinaryLogRecordKind recordKind) 376return recordKind == BinaryLogRecordKind.String 377|| recordKind == BinaryLogRecordKind.NameValueList 378|| recordKind == BinaryLogRecordKind.ProjectImportArchive; 381private static bool IsTextualDataRecord(BinaryLogRecordKind recordKind) 383return recordKind == BinaryLogRecordKind.String 384|| recordKind == BinaryLogRecordKind.ProjectImportArchive; 387private void ReadEmbeddedContent(BinaryLogRecordKind recordKind)
Logging\BinaryLogger\BuildEventArgsWriter.cs (63)
148BinaryLogRecordKind eventKind = WriteCore(e); 153private void FlushRecordToFinalStream(BinaryLogRecordKind recordKind, MemoryStream recordStream) 203private BinaryLogRecordKind WriteCore(BuildEventArgs e) 257public void WriteBlob(BinaryLogRecordKind kind, Stream stream) 289private BinaryLogRecordKind Write(BuildStartedEventArgs e) 301return BinaryLogRecordKind.BuildStarted; 304private BinaryLogRecordKind Write(BuildFinishedEventArgs e) 309return BinaryLogRecordKind.BuildFinished; 312private BinaryLogRecordKind Write(BuildCanceledEventArgs e) 316return BinaryLogRecordKind.BuildCanceled; 319private BinaryLogRecordKind Write(ProjectEvaluationStartedEventArgs e) 323return BinaryLogRecordKind.ProjectEvaluationStarted; 326private BinaryLogRecordKind Write(BuildCheckTracingEventArgs e) 335return BinaryLogRecordKind.BuildCheckTracing; 338private BinaryLogRecordKind Write(BuildCheckAcquisitionEventArgs e) 344return BinaryLogRecordKind.BuildCheckAcquisition; 347private BinaryLogRecordKind Write(ProjectEvaluationFinishedEventArgs e) 371return BinaryLogRecordKind.ProjectEvaluationFinished; 374private BinaryLogRecordKind Write(BuildSubmissionStartedEventArgs e) 383return BinaryLogRecordKind.BuildSubmissionStarted; 386private BinaryLogRecordKind Write(ProjectStartedEventArgs e) 412return BinaryLogRecordKind.ProjectStarted; 415private BinaryLogRecordKind Write(ProjectFinishedEventArgs e) 421return BinaryLogRecordKind.ProjectFinished; 424private BinaryLogRecordKind Write(TargetStartedEventArgs e) 433return BinaryLogRecordKind.TargetStarted; 436private BinaryLogRecordKind Write(TargetFinishedEventArgs e) 445return BinaryLogRecordKind.TargetFinished; 448private BinaryLogRecordKind Write(TaskStartedEventArgs e) 458return BinaryLogRecordKind.TaskStarted; 461private BinaryLogRecordKind Write(TaskFinishedEventArgs e) 469return BinaryLogRecordKind.TaskFinished; 472private BinaryLogRecordKind Write(BuildErrorEventArgs e) 485return BinaryLogRecordKind.Error; 488private BinaryLogRecordKind Write(BuildWarningEventArgs e) 501return BinaryLogRecordKind.Warning; 504private BinaryLogRecordKind Write(BuildMessageEventArgs e) 522return BinaryLogRecordKind.Message; 526private BinaryLogRecordKind Write(ProjectImportedEventArgs e) 532return BinaryLogRecordKind.ProjectImported; 535private BinaryLogRecordKind Write(TargetSkippedEventArgs e) 547return BinaryLogRecordKind.TargetSkipped; 550private BinaryLogRecordKind Write(AssemblyLoadBuildEventArgs e) 559return BinaryLogRecordKind.AssemblyLoad; 562private BinaryLogRecordKind Write(CriticalBuildMessageEventArgs e) 565return BinaryLogRecordKind.CriticalBuildMessage; 568private BinaryLogRecordKind Write(PropertyReassignmentEventArgs e) 575return BinaryLogRecordKind.PropertyReassignment; 578private BinaryLogRecordKind Write(UninitializedPropertyReadEventArgs e) 582return BinaryLogRecordKind.UninitializedPropertyRead; 585private BinaryLogRecordKind Write(PropertyInitialValueSetEventArgs e) 591return BinaryLogRecordKind.PropertyInitialValueSet; 594private BinaryLogRecordKind Write(EnvironmentVariableReadEventArgs e) 602return BinaryLogRecordKind.EnvironmentVariableRead; 605private BinaryLogRecordKind Write(ResponseFileUsedEventArgs e) 609return BinaryLogRecordKind.ResponseFileUsed; 612private BinaryLogRecordKind Write(TaskCommandLineEventArgs e) 617return BinaryLogRecordKind.TaskCommandLine; 620private BinaryLogRecordKind Write(TaskParameterEventArgs e) 633return BinaryLogRecordKind.TaskParameter; 1158FlushRecordToFinalStream(BinaryLogRecordKind.NameValueList, nameValueListStream); 1187private void Write(BinaryLogRecordKind kind) 1273Write(BinaryLogRecordKind.String);
Logging\BinaryLogger\Postprocessing\BinaryLogReaderErrorEventArgs.cs (2)
24BinaryLogRecordKind recordKind, 40public BinaryLogRecordKind RecordKind { get; }
Logging\BinaryLogger\Postprocessing\EmbeddedContentEventArgs.cs (2)
11public EmbeddedContentEventArgs(BinaryLogRecordKind contentKind, Stream contentStream) 17public BinaryLogRecordKind ContentKind { get; }
Microsoft.Build.Engine.UnitTests (10)
BuildEventArgsSerialization_Tests.cs (10)
44writer.WriteBlob(BinaryLogRecordKind.ProjectImportArchive, inputStream); 49Assert.Equal(BinaryLogRecordKind.ProjectImportArchive, (BinaryLogRecordKind)binaryReader.Read7BitEncodedInt()); 1015readerErrors[0].RecordKind.ShouldBe(BinaryLogRecordKind.Error); 1051BinaryLogRecordKind unknownType = (BinaryLogRecordKind)Enum.GetValues(typeof(BinaryLogRecordKind)).Cast<BinaryLogRecordKind>().Select(e => (int)e).Max() + 2; 1126readerErrors[0].RecordKind.ShouldBe(BinaryLogRecordKind.Error); 1182readerErrors[0].RecordKind.ShouldBe(BinaryLogRecordKind.Error);