Skip to content
Docs Try Aspire

AtsCapabilityInfo Properties

Class Properties 15 members
Represents a discovered [AspireExport] capability.
CapabilityId Section titled CapabilityId string
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; }
Description Section titled Description nullable string?
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; }
For flat codegen (Go, C): use this to put methods on each concrete builder. For inheritance codegen (TypeScript, Java): use AtsCapabilityInfo.TargetTypeId instead.
MethodName Section titled MethodName string
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; }
OwningTypeName Section titled OwningTypeName nullable string?
Gets or sets the owning type name for property/method capabilities.
public string? OwningTypeName { get; init; }
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; }
QualifiedMethodName Section titled QualifiedMethodName string
Gets the qualified method name combining OwningTypeName and MethodName.
public string QualifiedMethodName { get; }
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; }
RunSyncOnBackgroundThread Section titled RunSyncOnBackgroundThread bool
Gets or sets whether synchronous invocations of this capability should run on a background thread.
public bool RunSyncOnBackgroundThread { get; init; }
SourceLocation Section titled SourceLocation nullable string?
Gets or sets the source location where this capability is defined.
public string? SourceLocation { get; init; }
Format: "TypeName.MethodName" or "TypeName.PropertyName" for diagnostics.
TargetParameterName Section titled TargetParameterName nullable string?
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; }
TargetTypeId Section titled TargetTypeId nullable string?
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; }