AspireTerminal
namespace Aspire.Hosting.ApplicationModel;
public sealed class AspireTerminal : System.IAsyncDisposable{ // ...}Remarks
Section titled Remarks Obtain a handle from Terminal or Terminal. Handles cannot be constructed or extended by callers; Aspire manages their registration and connection to the underlying terminal implementation.
What disposal means depends on Aspire. For Terminal the AppHost owns the workload, so disposing stops it and removes the terminal from the dashboard; whoever creates such a terminal owns it and must dispose it, and showing one in an interaction does not transfer that ownership, so the terminal survives the dialog it was displayed in. For Terminal the workload belongs to the resource, so disposing only releases Aspire's handle and leaves the workload running.
When an AppHost-owned workload ends, its terminal remains in the dashboard until disposed, but no longer accepts input or automation. Reopening an ended terminal displays its ended state rather than replaying output.
Properties4
Section titled PropertiesMethods7
Section titled MethodsValueTask stringTaskTaskTasktext appears on the terminal screen.