Share via


SPServiceApplicationProxyGroup.ContainsType method

Determines whether a service application proxy of the specified type exists in the group.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Function ContainsType ( _
    serviceApplicationProxyType As Type _
) As Boolean
'Usage
Dim instance As SPServiceApplicationProxyGroup
Dim serviceApplicationProxyType As Type
Dim returnValue As Boolean

returnValue = instance.ContainsType(serviceApplicationProxyType)
public bool ContainsType(
    Type serviceApplicationProxyType
)

Parameters

  • serviceApplicationProxyType
    Type: System.Type

    The proxy type of the service application.

Return value

Type: System.Boolean
true if the service application proxy type exists in the application proxy group; otherwise, false.

Exceptions

Exception Condition
ArgumentNullException

The serviceApplicationProxyType parameter is a null reference (Nothing in Visual Basic).

Remarks

The following example determines whether a service application proxy of the specified type exists in the default service application proxy group.

    SPServiceApplicationProxyGroup defaultProxyGroup =
        SPServiceApplicationProxyGroup.Default;
    return defaultProxyGroup.ContainsType(typeof(MyServiceApplicationProxy));

See also

Reference

SPServiceApplicationProxyGroup class

SPServiceApplicationProxyGroup members

Microsoft.SharePoint.Administration namespace