[This is preliminary documentation and subject to change.]
Executes the action identified by its Id.
The "execution" of the action means that the authorization rules associated with the action are evaluated according to the CurrentPrincipal role membership and, if the action is allowed, the CurrentState of the AuthorizationPolicy instance is set to the TargetState property value of the chosen ActionRule.
CAUTION If you pass-in an actionId that doesn't identify an action contained in the Actions collection, the policy treats it as an attempt to execute a denied action (that is, it throws the PermissionDeniedException).
Exception Type | Condition |
---|---|
PermissionDeniedException | The CurrentPrincipal is not allowed to execute the action. |
AuthorizationPolicy Class | LaMarvin.Constable Namespace | AuthorizationPolicy.ExecuteAction Overload List