Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.3.x will end 7 October 2024 (12 months).
  • Bug fixes for security issues in 4.3.x will end 21 April 2025 (18 months).
  • PHP version: minimum PHP 8.0.0 Note: minimum PHP version has increased since Moodle 4.1. PHP 8.2.x is supported too.

(no description)

File Size: 159 lines (5 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

MultipartStream:: (8 methods):
  __construct()
  getBoundary()
  isWritable()
  getHeaders()
  createStream()
  addElement()
  createElement()
  getHeader()


Class: MultipartStream  - X-Ref

Stream that when read returns bytes for a streaming multipart or
multipart/form-data stream.

__construct(array $elements = [], string $boundary = null)   X-Ref

param: array  $elements Array of associative arrays, each containing a
param: string $boundary You can optionally provide a specific boundary

getBoundary()   X-Ref
No description

isWritable()   X-Ref
No description

getHeaders(array $headers)   X-Ref
Get the headers needed before transferring the content of a POST file

param: array<string, string> $headers

createStream(array $elements = [])   X-Ref
Create the aggregate stream that will be used to upload the POST data


addElement(AppendStream $stream, array $element)   X-Ref
No description

createElement(string $name, StreamInterface $stream, ?string $filename, array $headers)   X-Ref
No description

getHeader(array $headers, string $key)   X-Ref
No description