\Drupal\strata\Plugin\views\field SeverityField

Renders a severity ordinal as its name.

The one column of the four holding an integer rather than a string, because the ledger stores the ordinal so a filter can ask for "at least a warning" with a numeric comparison.

Summary

Methods
Properties
Constants
options
buildOptionsForm
render
No public properties found
No public constants found
labelled
defineOptions
No protected properties found
No protected constants found
No private methods found
No private properties found
No private constants found

Methods

options()

options() : array<string|int,string>

Every label this column can render, keyed by the value the column stores.

Returns

array

Stored value keyed to label.

buildOptionsForm()

buildOptionsForm(array  $form, \Drupal\Core\Form\FormStateInterface  $form_state) : void

{@inheritdoc}

Parameters

array $form

The form.

\Drupal\Core\Form\FormStateInterface $form_state

The form state.

Returns

void —

render()

render(\Drupal\views\ResultRow  $values) : string

{@inheritdoc}

Parameters

\Drupal\views\ResultRow $values

The row.

Returns

string —

The rendered value.

labelled()

labelled(list<\Drupal\strata\Journal\Realm|\Drupal\strata\Journal\Verb|\Drupal\strata\Capture\Classifier\Classification>  $cases) : array<string,string>

The labels of an enum whose cases carry one.

Parameters

list<\Drupal\strata\Journal\Realm|\Drupal\strata\Journal\Verb|\Drupal\strata\Capture\Classifier\Classification> $cases

The enum's cases.

Returns

array

Case value keyed to label.

defineOptions()

defineOptions() : array<string,mixed>

{@inheritdoc}

Returns

array

The option definitions.