同步停止所有的托管活动进程的服务。
命名空间: Microsoft.TeamFoundation.Framework.Server
程序集: Microsoft.TeamFoundation.Framework.Server(在 Microsoft.TeamFoundation.Framework.Server.dll 中)
语法
声明
Public Function StopHost ( _
requestContext As TeamFoundationRequestContext, _
hostId As Guid, _
reason As String, _
timeout As TimeSpan _
) As Boolean
public bool StopHost(
TeamFoundationRequestContext requestContext,
Guid hostId,
string reason,
TimeSpan timeout
)
参数
- requestContext
类型:Microsoft.TeamFoundation.Framework.Server.TeamFoundationRequestContext
请求上下文。
- hostId
类型:System.Guid
停止的托管的 ID。
- reason
类型:System.String
一个可选原因托管停止。
- timeout
类型:System.TimeSpan
时间等待成功完成。TimeSpan.MaxValue 将无限超时。
返回值
类型:System.Boolean
如果托管在超时时段,停止则为 true。
实现
ITeamFoundationHostManagementService.StopHost(TeamFoundationRequestContext, Guid, String, TimeSpan)
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关详细信息,请参阅通过部分受信任的代码使用库。