Compartir a través de


Expression.SwitchCase Method (Expression, array<Expression[])

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

Creates a SwitchCase for use in a SwitchExpression.

Namespace:  System.Linq.Expressions
Assembly:  System.Core (in System.Core.dll)

Syntax

'Declaration
Public Shared Function SwitchCase ( _
    body As Expression, _
    ParamArray testValues As Expression() _
) As SwitchCase
public static SwitchCase SwitchCase(
    Expression body,
    params Expression[] testValues
)

Parameters

Return Value

Type: System.Linq.Expressions.SwitchCase
The created SwitchCase.

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.