‪TYPO3CMS  10.4
TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream Class Reference
Inheritance diagram for TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream:
TYPO3\CMS\Core\Http\SelfEmittableStreamInterface

Public Member Functions

 __construct (string $identifier, DriverInterface $driver, int $size)
 
 emit ()
 
int getSize ()
 
bool isWritable ()
 
 write ($string)
 

Protected Member Functions

StreamInterface createStream ()
 

Protected Attributes

string $identifier
 
DriverInterface $driver
 
int $size
 

Detailed Description

A lazy stream, that wraps the FAL dumpFileContents() method to send file contents using emit(), as defined in SelfEmittableStreamInterface. This call will fall back to the FAL getFileContents() method if the fastpath possibility using SelfEmittableStreamInterface is not used.

Definition at line 32 of file FalDumpFileContentsDecoratorStream.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::__construct ( string  $identifier,
DriverInterface  $driver,
int  $size 
)

Member Function Documentation

◆ createStream()

StreamInterface TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::createStream ( )
protected

Creates a stream (on demand). This method is consumed by the guzzle StreamDecoratorTrait and is used when this stream is used without the emit() fastpath.

Returns
‪StreamInterface

Definition at line 75 of file FalDumpFileContentsDecoratorStream.php.

◆ emit()

TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::emit ( )

Emit the response to stdout, as specified in SelfEmittableStreamInterface. Offload to the driver method dumpFileContents.

Implements TYPO3\CMS\Core\Http\SelfEmittableStreamInterface.

Definition at line 64 of file FalDumpFileContentsDecoratorStream.php.

◆ getSize()

int TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::getSize ( )

◆ isWritable()

bool TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::isWritable ( )
Returns
‪bool

Definition at line 93 of file FalDumpFileContentsDecoratorStream.php.

◆ write()

TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::write (   $string)
Parameters
string$string
Exceptions

Definition at line 102 of file FalDumpFileContentsDecoratorStream.php.

Member Data Documentation

◆ $driver

DriverInterface TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::$driver
protected

◆ $identifier

string TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::$identifier
protected

◆ $size

int TYPO3\CMS\Core\Http\FalDumpFileContentsDecoratorStream::$size
protected