AtsCapabilityInfo
Class sealed net8.0
Represents a discovered [AspireExport] capability.
namespace Aspire.TypeSystem;
public sealed class AtsCapabilityInfo{ // ...} 16 members
Remarks
Section titled RemarksThis model is shared between code generation (using RoMethod/RoType metadata reflection) and the runtime CapabilityDispatcher (using System.Reflection).
The capability represents a single exportable method that can be invoked via invokeCapability(capabilityId, args) from polyglot clients.
Constructors1
Section titled ConstructorsProperties15
Section titled PropertiesCapabilityIdget; initstring Gets or sets the capability ID (e.g., "Aspire.Hosting/addRedis").
CapabilityKindget; init Gets or sets the kind of capability (Method, PropertyGetter, PropertySetter, InstanceMethod).
Descriptionget; initstring? Gets or sets the description of what this capability does.
ExpandedTargetTypesget; set 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.
MethodNameget; setstring 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.
OwningTypeNameget; initstring? Gets or sets the owning type name for property/method capabilities.
Parametersget; init Gets or sets the parameters for this capability.
QualifiedMethodNamegetstring Gets the qualified method name combining OwningTypeName and MethodName.
ReturnsBuilderget; initbool Gets or sets whether the return type is a builder type.
ReturnTypeget; init Gets or sets the return type reference with full type metadata. Use
AtsConstants.Void TypeId for void return types. RunSyncOnBackgroundThreadget; initbool Gets or sets whether synchronous invocations of this capability should run on a background thread.
SourceLocationget; initstring? Gets or sets the source location where this capability is defined.
TargetParameterNameget; initstring? 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.
TargetTypeget; init Gets or sets the target type reference with full type metadata.
TargetTypeIdget; initstring? Gets or sets the original (declared) ATS type ID that this capability targets. May be an interface type (e.g., "Aspire.Hosting/IResourceWithEnvironment").