Affordance
works.iterative.workflow.Affordance
final case class Affordance(command: String, available: Boolean, description: GuardDescription, reason: Option[UserMessage])
One command offered (or withheld) in the entity's current state.
Value parameters
- available
-
whether the gated
requiresguard passes for the caller's context - command
-
the transition's
CommandMatchlabel — the same trigger keydecidematches on - description
-
the transition's unstripped
requires.describetree — always the full declared guard, regardless of the auth policy the availability was computed under - reason
-
for an unavailable affordance, the DFS-first data-guard message of the failure — the same message
decidewould return asRejection.Invalid;Nonewhen available, andNoneunderAuthEnforcement.Enforcewhen the failure is pure-auth (no data message to show)
Attributes
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any
Members list
In this article