PostSharp 6.10 / / Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Diagnostics.​Transactions Namespace / ITransaction­Policy Interface / ITransaction­Policy Methods / ITransaction­Policy.​Evaluate­Extended­Open­Expression(T) Method

ITransactionPolicy.EvaluateExtendedOpenExpression<T> Method

Evaluates an expression defined as an extended property (typically an XML attribute) where the argument of the expression in an OpenTransactionExpressionModel.

Namespace:  PostSharp.Patterns.Diagnostics.Transactions
Assembly:  PostSharp.Patterns.Diagnostics (in PostSharp.Patterns.Diagnostics.dll) Version: 6.10.10.0 (6.10.10.0)
Syntax
C#
T EvaluateExtendedOpenExpression<T>(
	string propertyName,
	 in TransactionProperties transactionProperties,
	T defaultValue = null,
	ExtendedTransactionExpressionOptions options = ExtendedTransactionExpressionOptions.None
)

Parameters

propertyName
Type: System.String
Name of the property (or XML attribute) that defines the expression. Case sensitive.
transactionProperties
Type: PostSharp.Patterns.Diagnostics.Transactions.TransactionPropertiesInAttribute
The input TransactionProperties.
defaultValue (Optional)
Type: T
Value returned if the expression is not defined or has an error.
options (Optional)
Type: PostSharp.Patterns.Diagnostics.Transactions.ExtendedTransactionExpressionOptions
Determines whether exceptions should be thrown or swallowed or whether the expression is allowed to use sampling functions.

Type Parameters

T
Return type of the expression.

Return Value

Type: T
The result of the expression, or defaultValue.
See Also