PostSharp 6.9 / / Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Diagnostics.​Transactions Namespace / Transaction­Requirement Structure / Transaction­Requirement Methods / Transaction­Requirement.​With­Requires­Transaction Method

TransactionRequirement.WithRequiresTransaction Method

Returns a copy of the current TransactionRequirement but with a different value of RequiresTransaction. Specifically, this method preserves the IsSampled property if the value parameter is true.

Namespace:  PostSharp.Patterns.Diagnostics.Transactions
Assembly:  PostSharp.Patterns.Common (in PostSharp.Patterns.Common.dll) Version: 6.9.11.0 (6.9.11.0)
Syntax
C#
public TransactionRequirement WithRequiresTransaction(
	bool value
)

Parameters

value
Type: System.Boolean

Return Value

Type: TransactionRequirement
See Also