Class SourceGenTypeShape<T>
- Namespace
- PolyType.SourceGenModel
- Assembly
- PolyType.dll
Source generator model for type shapes.
public abstract class SourceGenTypeShape<T> : ITypeShape<T>, ITypeShape
Type Parameters
TThe type that the shape describes.
- Inheritance
-
SourceGenTypeShape<T>
- Implements
-
ITypeShape<T>
- Derived
- Inherited Members
Properties
AttributeFactory
Gets the factory method for creating the custom attribute provider of the type.
public Func<SourceGenAttributeInfo[]>? AttributeFactory { get; init; }
Property Value
EventsFactory
Gets the factory method for creating event shapes.
public Func<IEnumerable<IEventShape>>? EventsFactory { get; init; }
Property Value
GetAssociatedTypeShape
Gets the function that looks up associated type shapes by type.
public Func<Type, ITypeShape?>? GetAssociatedTypeShape { get; init; }
Property Value
Kind
Gets determines the TypeShapeKind that the current shape supports.
public abstract TypeShapeKind Kind { get; }
Property Value
MethodsFactory
Gets the factory method for creating method shapes.
public Func<IEnumerable<IMethodShape>>? MethodsFactory { get; init; }
Property Value
Provider
Gets the provider used to generate this instance.
public required ITypeShapeProvider Provider { get; init; }
Property Value
Methods
Accept(TypeShapeVisitor, object?)
Accepts a TypeShapeVisitor for type graph traversal.
public abstract object? Accept(TypeShapeVisitor visitor, object? state = null)
Parameters
visitorTypeShapeVisitorThe visitor to accept.
stateobjectThe state parameter to pass to the underlying visitor.