共用方式為


GeneratorExtensions.GetGeneratorType(ISourceGenerator) 方法

定義

傳回指定產生器的基礎型別

public static Type GetGeneratorType (this Microsoft.CodeAnalysis.ISourceGenerator generator);
static member GetGeneratorType : Microsoft.CodeAnalysis.ISourceGenerator -> Type
<Extension()>
Public Function GetGeneratorType (generator As ISourceGenerator) As Type

參數

generator
ISourceGenerator

要取得 型別的產生器

傳回

基礎產生器類型

備註

針對 IIncrementalGenerator ,會建立同時實作 的 ISourceGenerator 包裝函式。 此方法會在這些情況下解除包裝並傳回基礎類型。

適用於