Click or drag to resize

AuditExtensionsIf Method

Conditionally Applies a section of the fluent syntax to the audit.

Namespace:  SanteDB.Core.Security.Audit
Assembly:  SanteDB.Core.Api (in SanteDB.Core.Api.dll) Version: 3.0.481-alpha
Syntax
public static IAuditBuilder If(
	this IAuditBuilder builder,
	bool condition,
	Func<IAuditBuilder, IAuditBuilder> then,
	Func<IAuditBuilder, IAuditBuilder> otherwise = null
)

Parameters

builder
Type: SanteDB.Core.Security.AuditIAuditBuilder
condition
Type: SystemBoolean
Condition that evaluates to true/false.
then
Type: SystemFuncIAuditBuilder, IAuditBuilder
A function/lambda that is executed when the condition is true.
otherwise (Optional)
Type: SystemFuncIAuditBuilder, IAuditBuilder
An optional function/lambda that is executed when the condition is false.

Return Value

Type: IAuditBuilder
The IAuditBuilder in the current chain.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IAuditBuilder. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also