You are here

protected function MediaDevelGenerate::generateElements in Media entity 8

File

src/Plugin/DevelGenerate/MediaDevelGenerate.php, line 227

Class

MediaDevelGenerate
Provides a MediaDevelGenerate plugin.

Namespace

Drupal\media_entity\Plugin\DevelGenerate

Code

protected function generateElements(array $values) {
  if ($values['num'] <= 50) {
    $this
      ->generateMedia($values);
  }
  else {
    $this
      ->generateBatchMedia($values);
  }
}