Edit

Share via


MixedRealityServiceRegistry.AddService<T> Method

Definition

Adds an IMixedRealityService instance to the registry.

public:
generic <typename T>
 where T : Microsoft::MixedReality::Toolkit::IMixedRealityService static bool AddService(T serviceInstance, Microsoft::MixedReality::Toolkit::IMixedRealityServiceRegistrar ^ registrar);
public static bool AddService<T> (T serviceInstance, Microsoft.MixedReality.Toolkit.IMixedRealityServiceRegistrar registrar) where T : Microsoft.MixedReality.Toolkit.IMixedRealityService;
static member AddService : 'T * Microsoft.MixedReality.Toolkit.IMixedRealityServiceRegistrar -> bool (requires 'T :> Microsoft.MixedReality.Toolkit.IMixedRealityService)
Public Shared Function AddService(Of T As IMixedRealityService) (serviceInstance As T, registrar As IMixedRealityServiceRegistrar) As Boolean

Type Parameters

T

The interface type of the service being added.

Parameters

serviceInstance
T

Instance of the service to add.

registrar
IMixedRealityServiceRegistrar

Instance of the registrar manages the service.

Returns

True if the service was successfully added, false otherwise.

Applies to