AtsCapabilityInfo Properties
Class Properties 15 members
Represents a discovered [AspireExport] capability.
Gets or sets the capability ID (e.g., "Aspire.Hosting/addRedis").
public string CapabilityId { get; init; } Gets or sets the kind of capability (Method, PropertyGetter, PropertySetter, InstanceMethod).
public AtsCapabilityKind CapabilityKind { get; init; } Gets or sets the description of what this capability does.
public string? Description { get; init; } Gets or sets the expanded list of concrete types this capability applies to. Pre-computed during scanning by resolving interface targets to all implementing types.
public IReadOnlyList<AtsTypeRef> ExpandedTargetTypes { get; set; }Remarks
For flat codegen (Go, C): use this to put methods on each concrete builder. For inheritance codegen (TypeScript, Java): use
AtsCapabilityInfo.TargetTypeId instead. Gets or sets the simple method name for generated SDKs (e.g., "addRedis", "isRunMode"). For context type capabilities, this is just the property/method name without the type prefix.
public string MethodName { get; set; } Gets or sets the owning type name for property/method capabilities.
public string? OwningTypeName { get; init; }Remarks
For PropertyGetter, PropertySetter, and InstanceMethod capabilities, this is the type name that owns the property/method (e.g., "ExecutionContext"). For regular Method capabilities, this is null.
Gets or sets the parameters for this capability.
public IReadOnlyList<AtsParameterInfo> Parameters { get; init; } Gets the qualified method name combining OwningTypeName and MethodName.
public string QualifiedMethodName { get; }Remarks
Returns "ExecutionContext.isRunMode" for property capabilities, or just "addRedis" for regular method capabilities.
Gets or sets whether the return type is a builder type.
public bool ReturnsBuilder { get; init; } Gets or sets the return type reference with full type metadata. Use
AtsConstants.Void TypeId for void return types. public AtsTypeRef ReturnType { get; init; } Gets or sets whether synchronous invocations of this capability should run on a background thread.
public bool RunSyncOnBackgroundThread { get; init; } Gets or sets the source location where this capability is defined.
public string? SourceLocation { get; init; }Remarks
Format: "TypeName.MethodName" or "TypeName.PropertyName" for diagnostics.
Gets or sets the name of the target parameter (e.g., "builder", "resource"). This is the first parameter of the method that represents the target/receiver.
public string? TargetParameterName { get; init; } Gets or sets the target type reference with full type metadata.
public AtsTypeRef? TargetType { get; init; } Gets or sets the original (declared) ATS type ID that this capability targets. May be an interface type (e.g., "Aspire.Hosting/IResourceWithEnvironment").
public string? TargetTypeId { get; init; }