ServiceEndpoint.Behaviors Property

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Gets the behaviors for the service endpoint.

Namespace:  System.ServiceModel.Description
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

Syntax

'Declaration
Public ReadOnly Property Behaviors As KeyedByTypeCollection(Of IEndpointBehavior)
public KeyedByTypeCollection<IEndpointBehavior> Behaviors { get; }

Property Value

Type: System.Collections.Generic.KeyedByTypeCollection<IEndpointBehavior>
The KeyedByTypeCollection<TItem> of type IEndpointBehavior that contains the behaviors specified for the service endpoint.

Remarks

The type of behavior that is accessible from the description hierarchy is scoped to the specific level. From the ServiceEndpoint the IEndpointBehavior is accessible.

If you want access to the IContractBehavior associated with an endpoint, you can obtain the contact for the endpoint using the Contract property. Then call the Behaviors property to obtain the KeyedByTypeCollection<TItem> of the IContractBehavior objects associated with the endpoint.

Version Information

Silverlight

Supported in: 5, 4

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.