Expression.Catch Methode
Definitie
Belangrijk
Bepaalde informatie heeft betrekking op een voorlopige productversie die aanzienlijk kan worden gewijzigd voordat deze wordt uitgebracht. Microsoft biedt geen enkele expliciete of impliciete garanties met betrekking tot de informatie die hier wordt verstrekt.
Hiermee maakt u een CatchBlock weergave van een catch-instructie.
Overloads
| Name | Description |
|---|---|
| Catch(ParameterExpression, Expression) |
Hiermee maakt u een CatchBlock weergave van een catch-instructie met een verwijzing naar het gevangen Exception object voor gebruik in de hoofdtekst van de handler. |
| Catch(Type, Expression) |
Hiermee maakt u een CatchBlock weergave van een catch-instructie. |
| Catch(ParameterExpression, Expression, Expression) |
Hiermee maakt u een CatchBlock catch-instructie met een Exception filter en een verwijzing naar het gevangen Exception object. |
| Catch(Type, Expression, Expression) |
Hiermee maakt u een CatchBlock catch-instructie met een Exception filter, maar geen verwijzing naar het gevangen Exception object. |
Catch(ParameterExpression, Expression)
Hiermee maakt u een CatchBlock weergave van een catch-instructie met een verwijzing naar het gevangen Exception object voor gebruik in de hoofdtekst van de handler.
public:
static System::Linq::Expressions::CatchBlock ^ Catch(System::Linq::Expressions::ParameterExpression ^ variable, System::Linq::Expressions::Expression ^ body);
public static System.Linq.Expressions.CatchBlock Catch(System.Linq.Expressions.ParameterExpression variable, System.Linq.Expressions.Expression body);
static member Catch : System.Linq.Expressions.ParameterExpression * System.Linq.Expressions.Expression -> System.Linq.Expressions.CatchBlock
Public Shared Function Catch (variable As ParameterExpression, body As Expression) As CatchBlock
Parameters
- variable
- ParameterExpression
Een ParameterExpression vertegenwoordiging van een verwijzing naar het Exception object dat door deze handler is gevangen.
- body
- Expression
De hoofdtekst van de catch-instructie.
Retouren
De gemaakte CatchBlock.
Van toepassing op
Catch(Type, Expression)
Hiermee maakt u een CatchBlock weergave van een catch-instructie.
public:
static System::Linq::Expressions::CatchBlock ^ Catch(Type ^ type, System::Linq::Expressions::Expression ^ body);
public static System.Linq.Expressions.CatchBlock Catch(Type type, System.Linq.Expressions.Expression body);
static member Catch : Type * System.Linq.Expressions.Expression -> System.Linq.Expressions.CatchBlock
Public Shared Function Catch (type As Type, body As Expression) As CatchBlock
Parameters
- type
- Type
Exception CatchBlock Dit Type zal afhandelen.
- body
- Expression
De hoofdtekst van de catch-instructie.
Retouren
De gemaakte CatchBlock.
Opmerkingen
Het Type te Exception vangen object kan worden opgegeven, maar er is geen verwijzing naar het Exception object beschikbaar voor gebruik in de CatchBlock.
Van toepassing op
Catch(ParameterExpression, Expression, Expression)
Hiermee maakt u een CatchBlock catch-instructie met een Exception filter en een verwijzing naar het gevangen Exception object.
public:
static System::Linq::Expressions::CatchBlock ^ Catch(System::Linq::Expressions::ParameterExpression ^ variable, System::Linq::Expressions::Expression ^ body, System::Linq::Expressions::Expression ^ filter);
public static System.Linq.Expressions.CatchBlock Catch(System.Linq.Expressions.ParameterExpression variable, System.Linq.Expressions.Expression body, System.Linq.Expressions.Expression filter);
static member Catch : System.Linq.Expressions.ParameterExpression * System.Linq.Expressions.Expression * System.Linq.Expressions.Expression -> System.Linq.Expressions.CatchBlock
Public Shared Function Catch (variable As ParameterExpression, body As Expression, filter As Expression) As CatchBlock
Parameters
- variable
- ParameterExpression
Een ParameterExpression vertegenwoordiging van een verwijzing naar het Exception object dat door deze handler is gevangen.
- body
- Expression
De hoofdtekst van de catch-instructie.
- filter
- Expression
De hoofdtekst van het Exception filter.
Retouren
De gemaakte CatchBlock.
Van toepassing op
Catch(Type, Expression, Expression)
Hiermee maakt u een CatchBlock catch-instructie met een Exception filter, maar geen verwijzing naar het gevangen Exception object.
public:
static System::Linq::Expressions::CatchBlock ^ Catch(Type ^ type, System::Linq::Expressions::Expression ^ body, System::Linq::Expressions::Expression ^ filter);
public static System.Linq.Expressions.CatchBlock Catch(Type type, System.Linq.Expressions.Expression body, System.Linq.Expressions.Expression filter);
static member Catch : Type * System.Linq.Expressions.Expression * System.Linq.Expressions.Expression -> System.Linq.Expressions.CatchBlock
Public Shared Function Catch (type As Type, body As Expression, filter As Expression) As CatchBlock
Parameters
- type
- Type
Exception CatchBlock Dit Type zal afhandelen.
- body
- Expression
De hoofdtekst van de catch-instructie.
- filter
- Expression
De hoofdtekst van het Exception filter.
Retouren
De gemaakte CatchBlock.