Share via


IServiceHubServiceFactory.CreateAsync Method

Definition

Creates an instance of a ServiceHub service asynchronously.

public:
 System::Threading::Tasks::Task<System::Object ^> ^ CreateAsync(System::IO::Stream ^ stream, IServiceProvider ^ hostProvidedServices, Microsoft::ServiceHub::Framework::ServiceActivationOptions serviceActivationOptions, Microsoft::ServiceHub::Framework::IServiceBroker ^ serviceBroker, Microsoft::ServiceHub::Framework::Services::AuthorizationServiceClient ^ authorizationServiceClient);
public System.Threading.Tasks.Task<object> CreateAsync (System.IO.Stream stream, IServiceProvider hostProvidedServices, Microsoft.ServiceHub.Framework.ServiceActivationOptions serviceActivationOptions, Microsoft.ServiceHub.Framework.IServiceBroker serviceBroker, Microsoft.ServiceHub.Framework.Services.AuthorizationServiceClient authorizationServiceClient);
abstract member CreateAsync : System.IO.Stream * IServiceProvider * Microsoft.ServiceHub.Framework.ServiceActivationOptions * Microsoft.ServiceHub.Framework.IServiceBroker * Microsoft.ServiceHub.Framework.Services.AuthorizationServiceClient -> System.Threading.Tasks.Task<obj>
Public Function CreateAsync (stream As Stream, hostProvidedServices As IServiceProvider, serviceActivationOptions As ServiceActivationOptions, serviceBroker As IServiceBroker, authorizationServiceClient As AuthorizationServiceClient) As Task(Of Object)

Parameters

stream
Stream

The Stream that will be used to communicate with the service.

hostProvidedServices
IServiceProvider

Provides other services to the service.

serviceActivationOptions
ServiceActivationOptions

The activation options used to start the service.

serviceBroker
IServiceBroker

The IServiceBroker that can be used to request additional services.

authorizationServiceClient
AuthorizationServiceClient

The AuthorizationServiceClient retrieved from the IServiceBroker.

Returns

An instance of a ServiceHub service.

Applies to