You are here

public function StateItem::getLabel in State Machine 8

Gets the label of the current state.

Return value

string The label of the current state.

Overrides StateItemInterface::getLabel

File

src/Plugin/Field/FieldType/StateItem.php, line 273

Class

StateItem
Plugin implementation of the 'state' field type.

Namespace

Drupal\state_machine\Plugin\Field\FieldType

Code

public function getLabel() {
  return $this
    ->getStateLabel($this->value);
}