Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. FileBag.php

function FileBag::set

Overrides ParameterBag::set

1 call to FileBag::set()
FileBag::add in vendor/symfony/http-foundation/FileBag.php
Adds parameters.

File

vendor/symfony/http-foundation/FileBag.php, line 40

Class

FileBag
FileBag is a container for uploaded files.

Namespace

Symfony\Component\HttpFoundation

Code

public function set(string $key, mixed $value) : void {
    if (!\is_array($value) && !$value instanceof UploadedFile) {
        throw new \InvalidArgumentException('An uploaded file must be an array or an instance of UploadedFile.');
    }
    parent::set($key, $this->convertFileInformation($value));
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal