WorkflowRuntime.GetAllServices WorkflowRuntime.GetAllServices WorkflowRuntime.GetAllServices WorkflowRuntime.GetAllServices Method

정의

오버로드

GetAllServices(Type) GetAllServices(Type) GetAllServices(Type) GetAllServices(Type)

지정된 Type을 구현하거나 해당 형식에서 파생되었으며 워크플로 런타임 엔진에 추가된 모든 서비스를 검색합니다.Retrieves all the services that are added to the workflow run-time engine that implement or derive from the specified Type.

GetAllServices<T>() GetAllServices<T>() GetAllServices<T>() GetAllServices<T>()

지정된 제네릭 형식을 구현하거나 해당 형식에서 파생되었으며 워크플로 런타임 엔진에 추가된 모든 서비스를 검색합니다.Retrieves all the services that are added to the workflow run-time engine that implement or derive from the specified generic type.

GetAllServices(Type) GetAllServices(Type) GetAllServices(Type) GetAllServices(Type)

지정된 Type을 구현하거나 해당 형식에서 파생되었으며 워크플로 런타임 엔진에 추가된 모든 서비스를 검색합니다.Retrieves all the services that are added to the workflow run-time engine that implement or derive from the specified Type.

public:
 System::Collections::ObjectModel::ReadOnlyCollection<System::Object ^> ^ GetAllServices(Type ^ serviceType);
public System.Collections.ObjectModel.ReadOnlyCollection<object> GetAllServices (Type serviceType);
member this.GetAllServices : Type -> System.Collections.ObjectModel.ReadOnlyCollection<obj>
Public Function GetAllServices (serviceType As Type) As ReadOnlyCollection(Of Object)

매개 변수

serviceType
Type Type Type Type

서비스가 반환되기 위해 구현해야 하는 Type입니다.The Type that services must implement to be returned.

반환

지정된 Type을 구현하거나 해당 형식에서 파생된 서비스입니다.Services that implement or derive from the specified Type.

예외

serviceType이 null 참조(Visual Basic의 경우 Nothing)인 경우serviceType is a null reference (Nothing in Visual Basic).

예제

다음 예제에서는 WorkflowRuntime 개체에서 지정된 유형의 모든 서비스를 검색하는 방법을 보여 줍니다.The following example demonstrates how to retrieve all services of a given type from a WorkflowRuntime object.

// Create a new workflow runtime
WorkflowRuntime workflowRuntime = new WorkflowRuntime();
// Obtain the type of the TrackingService abstract class
Type serviceType = typeof(TrackingService);
// Create a services collection
ReadOnlyCollection<object> services;
// Fetch a collection of all services that match the given type
services = workflowRuntime.GetAllServices(serviceType);
' Create a new workflow runtime
Dim workflowRuntime As New WorkflowRuntime()
' Obtain the type of the TrackingService abstract class
Dim serviceType As Type = GetType(TrackingService)
' Create a services collection
Dim services As ReadOnlyCollection(Of Object)
' Fetch a collection of all services that match the given type
services = workflowRuntime.GetAllServices(serviceType)

설명

ReadOnlyCollection<T>은 지정된 Type을 구현하거나 해당 형식에서 파생된 서비스가 워크플로 런타임 엔진에 추가되지 않았음을 나타냅니다.An empty ReadOnlyCollection<T> indicates that no services that implement or derive from the specified Type have been added to the workflow run-time engine.

GetAllServices<T>() GetAllServices<T>() GetAllServices<T>() GetAllServices<T>()

지정된 제네릭 형식을 구현하거나 해당 형식에서 파생되었으며 워크플로 런타임 엔진에 추가된 모든 서비스를 검색합니다.Retrieves all the services that are added to the workflow run-time engine that implement or derive from the specified generic type.

public:
generic <typename T>
 System::Collections::ObjectModel::ReadOnlyCollection<T> ^ GetAllServices();
public System.Collections.ObjectModel.ReadOnlyCollection<T> GetAllServices<T> ();
member this.GetAllServices : unit -> System.Collections.ObjectModel.ReadOnlyCollection<'T>
Public Function GetAllServices(Of T) () As ReadOnlyCollection(Of T)

형식 매개 변수

T

서비스 형식입니다.The service type.

반환

지정된 제네릭 형식을 구현하거나 해당 형식에서 파생된 서비스입니다.Services that implement or derive from the specified generic type.

예외

예제

다음 예제에서는 WorkflowRuntime 개체에서 지정된 유형의 모든 서비스를 검색하는 방법을 보여 줍니다.The following example demonstrates how to retrieve all services of a given type from a WorkflowRuntime object.

// Create a new workflow runtime
WorkflowRuntime workflowRuntime = new WorkflowRuntime();
// Obtain the type of the TrackingService abstract class
Type serviceType = typeof(TrackingService);
// Create a services collection
ReadOnlyCollection<TrackingService> services;
// Fetch a collection of all services that match the given type
services = workflowRuntime.GetAllServices<TrackingService>();
' Create a new workflow runtime
Dim workflowRuntime As New WorkflowRuntime()
' Obtain the type of the TrackingService abstract class
Dim serviceType As Type = GetType(TrackingService)
' Create a services collection
Dim services As ReadOnlyCollection(Of TrackingService)
' Fetch a collection of all services that match the given type
services = workflowRuntime.GetAllServices(Of TrackingService)()

설명

ReadOnlyCollection<T>은 지정된 제네릭 형식을 구현하거나 해당 형식에서 파생된 서비스가 워크플로 런타임 엔진에 추가되지 않았음을 나타냅니다.An empty ReadOnlyCollection<T> indicates that no services have been added to the workflow run-time engine that implement or derive from the specified generic type.

적용 대상