function MetaEventSubscriber::getSubscribedEvents

File

core/modules/jsonapi/tests/modules/jsonapi_test_meta_events/src/EventSubscriber/MetaEventSubscriber.php, line 22

Class

MetaEventSubscriber
Event subscriber which tests adding metadata to ResourceObjects and relationships.

Namespace

Drupal\jsonapi_test_meta_events\EventSubscriber

Code

public static function getSubscribedEvents() : array {
    return [
        CollectResourceObjectMetaEvent::class => 'addResourceObjectMeta',
        CollectRelationshipMetaEvent::class => 'addRelationshipMeta',
    ];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.