A text file's content.

For text files we can store the whole file in a string.

package Default
inherited_from \FeaturePhp\File\FileContent

 Methods

Creates a text file's content.

__construct(string $content) 

Parameters

$content

string

Adds the text file's content to a ZIP archive.

addToZip(\ZipArchive $zip, string $target) 

This is expected to be called only be a \FeaturePhp\Exporter\ZipExporter.

inherited_from \FeaturePhp\File\FileContent::addToZip()

Parameters

$zip

\ZipArchive

$target

string

the file target in the ZIP archive

Adds the file's content to a ZIP archive.

addToZip(\ZipArchive $zip, string $target) 
Inherited

This is expected to be called only be a \FeaturePhp\Exporter\ZipExporter.

Parameters

$zip

\ZipArchive

$target

string

the file target in the ZIP archive

Copies the text file's content to the local filesystem.

copy(string $target) 

This is expected to be called only be a \FeaturePhp\Exporter\LocalExporter.

inherited_from \FeaturePhp\File\FileContent::copy()

Parameters

$target

string

the file target in the filesystem

Copies file's content to the local filesystem.

copy(string $target) 
Inherited

This is expected to be called only be a \FeaturePhp\Exporter\LocalExporter.

Parameters

$target

string

the file target in the filesystem

Returns the entire content as a summary.

getSummary() : string

This returns the whole text file.

inherited_from \FeaturePhp\File\FileContent::getSummary()

Returns

string

Returns a summary of the file's content.

getSummary() : string
Inherited

The summary should be suitable for an overview of generated files, but does not necessarily contain the complete file content.

Returns

string

 Properties

 

the entire content as a string (usually UTF-8)

$content : string

Default