You are here

public function RestExport::setMimeType in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/rest/src/Plugin/views/display/RestExport.php \Drupal\rest\Plugin\views\display\RestExport::setMimeType()

Sets the request content type.

Parameters

string $mime_type: The response mime type. E.g. 'application/json'.

1 call to RestExport::setMimeType()
RestExport::initDisplay in core/modules/rest/src/Plugin/views/display/RestExport.php
Initializes the display plugin.

File

core/modules/rest/src/Plugin/views/display/RestExport.php, line 203

Class

RestExport
The plugin that handles Data response callbacks for REST resources.

Namespace

Drupal\rest\Plugin\views\display

Code

public function setMimeType($mime_type) {
  $this->mimeType = $mime_type;
}