3 namespace Drupal\workflows;
6 * A transition value object that describes the transition between two states.
9 * The TransitionInterface should only be used by Workflows and Content
12 * @todo Revisit the need for this in https://www.drupal.org/node/2902309.
14 interface TransitionInterface {
17 * The key of the transition plugin form.
19 const PLUGIN_FORM_KEY = 'transition';
22 * The transition direction from.
24 const DIRECTION_FROM = 'from';
27 * The transition direction to.
29 const DIRECTION_TO = 'to';
32 * Gets the transition's ID.
35 * The transition's ID.
40 * Gets the transition's label.
43 * The transition's label.
45 public function label();
48 * Gets the transition's from states.
50 * @return \Drupal\workflows\StateInterface[]
51 * The transition's from states.
53 public function from();
56 * Gets the transition's to state.
58 * @return \Drupal\workflows\StateInterface
59 * The transition's to state.
64 * Gets the transition's weight.
67 * The transition's weight.
69 public function weight();