共用方式為


RemoteServiceBroker.SetAuthorizationService 方法

定義

多載

SetAuthorizationService(IAuthorizationService, JoinableTaskFactory)
已淘汰.

設定要用來取得未明確提供之所有服務要求之預設值 ClientCredentials 的授權服務。

SetAuthorizationService(IAuthorizationService)

設定要用來取得未明確提供之所有服務要求之預設值 ClientCredentials 的授權服務。

SetAuthorizationService(IAuthorizationService, JoinableTaskFactory)

警告

Use the overload that does not accept a JoinableTaskFactory instead. This overload will be removed in a future release.

設定要用來取得未明確提供之所有服務要求之預設值 ClientCredentials 的授權服務。

public:
 void SetAuthorizationService(Microsoft::ServiceHub::Framework::Services::IAuthorizationService ^ authorizationService, Microsoft::VisualStudio::Threading::JoinableTaskFactory ^ joinableTaskFactory);
[System.Obsolete("Use the overload that does not accept a JoinableTaskFactory instead. This overload will be removed in a future release.", true)]
public void SetAuthorizationService (Microsoft.ServiceHub.Framework.Services.IAuthorizationService? authorizationService, Microsoft.VisualStudio.Threading.JoinableTaskFactory? joinableTaskFactory);
[<System.Obsolete("Use the overload that does not accept a JoinableTaskFactory instead. This overload will be removed in a future release.", true)>]
member this.SetAuthorizationService : Microsoft.ServiceHub.Framework.Services.IAuthorizationService * Microsoft.VisualStudio.Threading.JoinableTaskFactory -> unit
Public Sub SetAuthorizationService (authorizationService As IAuthorizationService, joinableTaskFactory As JoinableTaskFactory)

參數

authorizationService
IAuthorizationService

授權服務。 可能是 null 清除先前設定的值。

joinableTaskFactory
JoinableTaskFactory

如果授權服務需要主線程,則為避免死結的方法。 可能是 Null。

屬性

備註

這個方法是無線程的,但不是安全線程。 它不應該與本身同時呼叫。

適用於

SetAuthorizationService(IAuthorizationService)

設定要用來取得未明確提供之所有服務要求之預設值 ClientCredentials 的授權服務。

public:
 void SetAuthorizationService(Microsoft::ServiceHub::Framework::Services::IAuthorizationService ^ authorizationService);
public void SetAuthorizationService (Microsoft.ServiceHub.Framework.Services.IAuthorizationService? authorizationService);
member this.SetAuthorizationService : Microsoft.ServiceHub.Framework.Services.IAuthorizationService -> unit
Public Sub SetAuthorizationService (authorizationService As IAuthorizationService)

參數

authorizationService
IAuthorizationService

授權服務。 可能是 null 清除先前設定的值。

備註

這個方法是無線程的,但不是安全線程。 它不應該與本身同時呼叫。

適用於