can method

Future<bool> can(
  1. Object? user,
  2. String action,
  3. DVPageDocument document
)

Whether user holds action on document, asked of the same policies the workflow checks.

For showing an action as unavailable before it is tried. It is never the check: the workflow asks again at the transition, so a role removed after Studio asked is still refused.

Implementation

Future<bool> can(Object? user, String action, DVPageDocument document) =>
    _authorization.can<Object?, DVPageDocument>(user, action, document);