Symfony2 API
Class

Symfony\Component\Config\Resource\FileResource

class FileResource implements ResourceInterface, Serializable

FileResource represents a resource stored on the filesystem.

The resource can be a file or a directory.

Methods

__construct(string $resource)

Constructor.

string __toString()

Returns a string representation of the Resource.

mixed getResource()

Returns the resource tied to this Resource.

Boolean isFresh(integer $timestamp)

Returns true if the resource has not been updated since the given timestamp.

serialize()

unserialize($serialized)

Details

at line 30
public __construct(string $resource)

Constructor.

Parameters

string $resource The file path to the resource

at line 40
public string __toString()

Returns a string representation of the Resource.

Return Value

string A string representation of the Resource

at line 50
public mixed getResource()

Returns the resource tied to this Resource.

Return Value

mixed The resource

at line 62
public Boolean isFresh(integer $timestamp)

Returns true if the resource has not been updated since the given timestamp.

Parameters

integer $timestamp The last time the resource was loaded

Return Value

Boolean true if the resource has not been updated, false otherwise

at line 71
public serialize()

at line 76
public unserialize($serialized)

Parameters

$serialized