Open sandboxFocus

Method ExecuteWithAdvices

ExecuteWithAdvices<TResult, TAction>(ObjectAccessLevel, ref TAction)

Executes an action wrapped by all custom advices added to the current object.

Declaration
protected TResult ExecuteWithAdvices<TResult, TAction>(ObjectAccessLevel objectAccessLevel, ref TAction action) where TAction : struct, IAction<TResult>
Parameters
Type Name Description
ObjectAccessLevel objectAccessLevel

The required access level when executing action.

TAction action

The action to be executed.

Returns
Type Description
TResult

The return value of action.

Type Parameters
Name Description
TResult

The type of the return value.

TAction

The type of the action.