12 instantiations of BlobContentId
Microsoft.CodeAnalysis (1)
NativePdbWriter\PdbWriter.cs (1)
576contentId = new BlobContentId(guid, stamp);
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (1)
CodeGen\CodeGenFunctionPointersTests.cs (1)
12600private static readonly BlobContentId s_contentId = new BlobContentId(s_guid, 0x04030201);
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (2)
PDB\PortablePdbTests.cs (2)
194pdbId = new BlobContentId(mdReader.DebugMetadataHeader.Id); 255pdbId = new BlobContentId(mdReader.DebugMetadataHeader.Id);
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (2)
PDB\PortablePdbTests.vb (2)
101pdbId = New BlobContentId(mdReader.DebugMetadataHeader.Id) 155pdbId = New BlobContentId(mdReader.DebugMetadataHeader.Id)
Roslyn.Test.PdbUtilities (2)
Reader\PdbValidation.cs (2)
643var expectedId = new BlobContentId(guidInDebugDirectory, stampInDebugDirectory); 644var actualId = new BlobContentId(pdbReader.DebugMetadataHeader.Id);
System.Reflection.Metadata (4)
System\Reflection\Metadata\BlobContentId.cs (2)
114return new BlobContentId(guid, stamp); 123return content => new BlobContentId(Guid.NewGuid(), timestamp);
System\Reflection\PortableExecutable\PEReader.cs (2)
787var id = new BlobContentId(data.Guid, codeViewEntry.Stamp); 837if (new BlobContentId(candidate.GetMetadataReader().DebugMetadataHeader!.Id) != id)
50 references to BlobContentId
Microsoft.CodeAnalysis (13)
NativePdbWriter\PdbWriter.cs (3)
560public BlobContentId GetContentId() 562BlobContentId contentId; 568contentId = BlobContentId.FromHash(CryptographicHashProvider.ComputeHash(_hashAlgorithmNameOpt, _symWriter.GetUnderlyingData()));
PEWriter\ExtendedPEBuilder.cs (3)
43Func<IEnumerable<Blob>, BlobContentId>? deterministicIdProvider, 83internal BlobContentId Serialize(BlobBuilder peBlob, out Blob mvidSectionFixup) 85var result = base.Serialize(peBlob);
PEWriter\MetadataWriter.cs (1)
1865public PortablePdbBuilder GetPortablePdbBuilder(ImmutableArray<int> typeSystemRowCounts, MethodDefinitionHandle debugEntryPoint, Func<IEnumerable<Blob>, BlobContentId> deterministicIdProviderOpt)
PEWriter\PeWriter.cs (6)
162BlobContentId pdbContentId = nativePdbWriterOpt?.GetContentId() ?? default; 192new Func<IEnumerable<Blob>, BlobContentId>(content => BlobContentId.FromHash(CryptographicHashProvider.ComputeSourceHash(content))) : 207new Func<IEnumerable<Blob>, BlobContentId>(content => BlobContentId.FromHash(portablePdbContentHash = CryptographicHashProvider.ComputeHash(context.Module.PdbChecksumAlgorithm, content))) : 293var peContentId = peBuilder.Serialize(emitBuilders.PortableExecutableBlobBuilder, out Blob mvidSectionFixup);
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (2)
CodeGen\CodeGenFunctionPointersTests.cs (2)
12600private static readonly BlobContentId s_contentId = new BlobContentId(s_guid, 0x04030201); 12758var contentId = peBuilder.Serialize(peBlob);
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (2)
PDB\PortablePdbTests.cs (2)
188BlobContentId pdbId; 249BlobContentId pdbId;
Microsoft.CodeAnalysis.Features.Test.Utilities (1)
EditAndContinue\Extensions.cs (1)
83return BlobContentId.FromHash(Encoding.UTF8.GetBytes(projectName.PadRight(20, '\0'))).Guid;
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (2)
PDB\PortablePdbTests.vb (2)
97Dim pdbId As BlobContentId 151Dim pdbId As BlobContentId
Roslyn.Test.PdbUtilities (2)
Reader\PdbValidation.cs (2)
643var expectedId = new BlobContentId(guidInDebugDirectory, stampInDebugDirectory); 644var actualId = new BlobContentId(pdbReader.DebugMetadataHeader.Id);
SemanticSearch.BuildTask (1)
GenerateFilteredReferenceAssembliesTask.cs (1)
488return BlobContentId.FromHash(sha.ComputeHash(stream)).Guid;
System.Reflection.Metadata (27)
System\Reflection\Metadata\BlobContentId.cs (11)
11public readonly struct BlobContentId : IEquatable<BlobContentId> 64public static BlobContentId FromHash(ImmutableArray<byte> hashCode) 74public static BlobContentId FromHash(byte[] hashCode) 84private static BlobContentId FromHash(ReadOnlySpan<byte> hashCode) 117public static Func<IEnumerable<Blob>, BlobContentId> GetTimeBasedProvider() 126public bool Equals(BlobContentId other) => Guid == other.Guid && Stamp == other.Stamp; 127public override bool Equals([NotNullWhen(true)] object? obj) => obj is BlobContentId bcid && Equals(bcid); 129public static bool operator ==(BlobContentId left, BlobContentId right) => left.Equals(right); 130public static bool operator !=(BlobContentId left, BlobContentId right) => !left.Equals(right);
System\Reflection\Metadata\Ecma335\PortablePdbBuilder.cs (6)
23public Func<IEnumerable<Blob>, BlobContentId> IdProvider { get; } 43/// (<see cref="BlobContentId.GetTimeBasedProvider()"/>). 51Func<IEnumerable<Blob>, BlobContentId>? idProvider = null) 66IdProvider = idProvider ?? BlobContentId.GetTimeBasedProvider(); 125public BlobContentId Serialize(BlobBuilder builder) 144var contentId = IdProvider(builder.GetBlobs());
System\Reflection\PortableExecutable\DebugDirectory\DebugDirectoryBuilder.cs (2)
83BlobContentId pdbContentId, 102BlobContentId pdbContentId,
System\Reflection\PortableExecutable\ManagedPEBuilder.cs (1)
48Func<IEnumerable<Blob>, BlobContentId>? deterministicIdProvider = null)
System\Reflection\PortableExecutable\PEBuilder.cs (5)
15public Func<IEnumerable<Blob>, BlobContentId> IdProvider { get; } 61protected PEBuilder(PEHeaderBuilder header, Func<IEnumerable<Blob>, BlobContentId>? deterministicIdProvider) 68IdProvider = deterministicIdProvider ?? BlobContentId.GetTimeBasedProvider(); 91public BlobContentId Serialize(BlobBuilder builder) 113var contentId = IdProvider(builder.GetBlobs());
System\Reflection\PortableExecutable\PEReader.cs (2)
787var id = new BlobContentId(data.Guid, codeViewEntry.Stamp); 805private static bool TryOpenPortablePdbFile(string path, BlobContentId id, Func<string, Stream?> pdbFileStreamProvider, out MetadataReaderProvider? provider, ref Exception? errorToReport)