Guides

LocalFile
in package
implements File

FinalYes

Represents a local file on the file system.

Table of Contents

Interfaces

File

Properties

$path  : string
Path to the file.

Methods

__construct()  : mixed
getContents()  : string
Returns the content of the file as a string.
md5()  : string
Returns md5 hash of the file.
path()  : string
Returns a relative path to the file.

Properties

$path read-only

Path to the file.

private string $path

Methods

__construct()

public __construct(string $path) : mixed
Parameters
$path : string

getContents()

Returns the content of the file as a string.

public getContents() : string
Attributes
#[Override]
Return values
string

md5()

Returns md5 hash of the file.

public md5() : string
Attributes
#[Override]
Return values
string

path()

Returns a relative path to the file.

public path() : string
Attributes
#[Override]
Return values
string

        
On this page

Search results