Table of Contents

Struct MethodDataModel

Namespace
PolyType.Roslyn
Assembly
PolyType.Roslyn.dll

A method data model wrapping an IMethodSymbol.

public readonly struct MethodDataModel
Inherited Members

Properties

IsAmbiguous

Whether the method is ambiguous due to diamond inheritance.

public required bool IsAmbiguous { get; init; }

Property Value

bool

Method

The method symbol that this model represents.

public required IMethodSymbol Method { get; init; }

Property Value

IMethodSymbol

Name

The name used to identify the method in the generated code.

public required string Name { get; init; }

Property Value

string

Parameters

The parameters of the method.

public required ImmutableArray<ParameterDataModel> Parameters { get; init; }

Property Value

ImmutableArray<ParameterDataModel>

ReturnTypeKind

The kind of return type for the method, indicating whether it returns void, a task, or a value task.

public required MethodReturnTypeKind ReturnTypeKind { get; init; }

Property Value

MethodReturnTypeKind

ReturnedValueType

The type of the value returned by the method, or null if returning void, ValueTask, or Task.

public required ITypeSymbol? ReturnedValueType { get; init; }

Property Value

ITypeSymbol