\Drupal\strata\Event CommitEvent

A flush sealed a window into a commit.

Dispatched only when a flush actually wrote something. A flush that found nothing pending is not an event; a site that fired one every fifteen seconds on an idle site would teach its operators to ignore the channel.

Summary

Methods
Properties
Constants
__construct
name
jsonSerialize
result
site
No public constants found
body
No protected properties found
No protected constants found
No private methods found
No private properties found
No private constants found

Properties

$result

$result : \Drupal\strata\Flush\FlushResult

Type

FlushResult

$site

$site : string

Type

string

Methods

__construct()

__construct(\Drupal\strata\Flush\FlushResult  $result, string  $site = '') : mixed

Constructs an event.

Parameters

\Drupal\strata\Flush\FlushResult $result

What the flush did.

string $site

The site whose history it was appended to.

Returns

mixed —

name()

name() : string

The name this event is dispatched under.

Returns

string —

One of the constants on StrataEvents.

jsonSerialize()

jsonSerialize() : array<string,mixed>

The payload a webhook sends and a log line records.

Returns

array

The event name, the site, the moment, and the body.

body()

body() : array<string,mixed>

What happened, as data.

Returns

array

The body, without the envelope.