‪TYPO3CMS  ‪main
TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration Class Reference

Public Member Functions

 __construct (FileLocation $fileLocation, string $fileName, bool $fail=false)
 
 buildContent ()
 
 matches (ResponseInterface $response)
 
StatusMessage[] getMismatches (ResponseInterface $response)
 
 withExpectedContentType (string $contentType)
 
 withUnexpectedContentType (string $contentType)
 
 withExpectedContent (string $content)
 
 withUnexpectedContent (string $content)
 
 withHandler (\Closure $handler)
 
 withBuildFlags (int $buildFlags)
 
 getFileLocation ()
 
 getFileName ()
 
 getUrl ()
 
 shallFail ()
 
 getExpectedContentType ()
 
 getUnexpectedContentType ()
 
 getExpectedContent ()
 
 getUnexpectedContent ()
 

Public Attributes

const FLAG_BUILD_HTML = 1
 
const FLAG_BUILD_PHP = 2
 
const FLAG_BUILD_SVG = 4
 
const FLAG_BUILD_HTML_DOCUMENT = 64
 
const FLAG_BUILD_SVG_DOCUMENT = 128
 

Protected Attributes

FileLocation $fileLocation
 
string $fileName
 
bool $fail
 
string null $expectedContentType
 
string null $unexpectedContentType
 
string null $expectedContent
 
string null $unexpectedContent
 
Closure null $handler
 
int $buildFlags = self::FLAG_BUILD_HTML | self::FLAG_BUILD_HTML_DOCUMENT
 

Detailed Description

Declares contents on server response expectations on a static file.

should only be used from within TYPO3 Core

Definition at line 27 of file FileDeclaration.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::__construct ( FileLocation  $fileLocation,
string  $fileName,
bool  $fail = false 
)

Member Function Documentation

◆ buildContent()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::buildContent ( )

Definition at line 78 of file FileDeclaration.php.

◆ getExpectedContent()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getExpectedContent ( )

◆ getExpectedContentType()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getExpectedContentType ( )

◆ getFileLocation()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getFileLocation ( )

◆ getFileName()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getFileName ( )

◆ getMismatches()

StatusMessage [] TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getMismatches ( ResponseInterface  $response)

◆ getUnexpectedContent()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getUnexpectedContent ( )

◆ getUnexpectedContentType()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getUnexpectedContentType ( )

◆ getUrl()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::getUrl ( )

◆ matches()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::matches ( ResponseInterface  $response)

◆ shallFail()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::shallFail ( )

◆ withBuildFlags()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::withBuildFlags ( int  $buildFlags)

◆ withExpectedContent()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::withExpectedContent ( string  $content)

Definition at line 171 of file FileDeclaration.php.

◆ withExpectedContentType()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::withExpectedContentType ( string  $contentType)

Definition at line 157 of file FileDeclaration.php.

◆ withHandler()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::withHandler ( \Closure  $handler)

◆ withUnexpectedContent()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::withUnexpectedContent ( string  $content)

Definition at line 178 of file FileDeclaration.php.

◆ withUnexpectedContentType()

TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::withUnexpectedContentType ( string  $contentType)

Definition at line 164 of file FileDeclaration.php.

Member Data Documentation

◆ $buildFlags

int TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$buildFlags = self::FLAG_BUILD_HTML | self::FLAG_BUILD_HTML_DOCUMENT
protected

◆ $expectedContent

string null TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$expectedContent
protected

◆ $expectedContentType

string null TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$expectedContentType
protected

◆ $fail

bool TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$fail
protected

◆ $fileLocation

FileLocation TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$fileLocation
protected

◆ $fileName

◆ $handler

Closure null TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$handler
protected

◆ $unexpectedContent

string null TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$unexpectedContent
protected

◆ $unexpectedContentType

string null TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::$unexpectedContentType
protected

◆ FLAG_BUILD_HTML

const TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::FLAG_BUILD_HTML = 1

Definition at line 29 of file FileDeclaration.php.

◆ FLAG_BUILD_HTML_DOCUMENT

const TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::FLAG_BUILD_HTML_DOCUMENT = 64

◆ FLAG_BUILD_PHP

const TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::FLAG_BUILD_PHP = 2

◆ FLAG_BUILD_SVG

const TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::FLAG_BUILD_SVG = 4

◆ FLAG_BUILD_SVG_DOCUMENT

const TYPO3\CMS\Install\SystemEnvironment\ServerResponse\FileDeclaration::FLAG_BUILD_SVG_DOCUMENT = 128