interface ResourceResponseInterface

Same name in other branches
  1. 9 core/modules/rest/src/ResourceResponseInterface.php \Drupal\rest\ResourceResponseInterface
  2. 10 core/modules/rest/src/ResourceResponseInterface.php \Drupal\rest\ResourceResponseInterface
  3. 11.x core/modules/rest/src/ResourceResponseInterface.php \Drupal\rest\ResourceResponseInterface

Defines a common interface for resource responses.

Hierarchy

Expanded class hierarchy of ResourceResponseInterface

All classes that implement ResourceResponseInterface

3 files declare their use of ResourceResponseInterface
EntityResourceTestBase.php in core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php
ResourceResponseSubscriber.php in core/modules/rest/src/EventSubscriber/ResourceResponseSubscriber.php
ResourceResponseSubscriberTest.php in core/modules/rest/tests/src/Unit/EventSubscriber/ResourceResponseSubscriberTest.php

File

core/modules/rest/src/ResourceResponseInterface.php, line 8

Namespace

Drupal\rest
View source
interface ResourceResponseInterface {
    
    /**
     * Returns response data that should be serialized.
     *
     * @return mixed
     *   Response data that should be serialized.
     */
    public function getResponseData();

}

Members

Title Sort descending Modifiers Object type Summary
ResourceResponseInterface::getResponseData public function Returns response data that should be serialized.

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