針對由主機所管理的物件定義方法。Defines methods for objects that are managed by the host.
public interface class IHostedService
public interface IHostedService
type IHostedService = interface
Public Interface IHostedService
當應用程式主機準備好啟動服務時觸發。Triggered when the application host is ready to start the service.
當應用程式主機執行順利關機時觸發。Triggered when the application host is performing a graceful shutdown.