Property | Type | Description | |
---|---|---|---|
$content | Content variable is lazy. It will not be read from filesystem until it's requested first time. | ||
$filesystem | |||
$key | |||
$metadata | metadata in associative array. Only for adapters that support metadata | ||
$mtime | File date modified. | ||
$name | Human readable filename (usually the end of the key). | ||
$size | File size in bytes. |
Method | Description | |
---|---|---|
__construct ( string $key, gaufrette\Filesystem $filesystem ) | ||
createStream ( ) : gaufrette\Stream | Creates a new file stream instance of the file. | |
delete ( array $metadata = [] ) : boolean | Deletes the file from the filesystem. | |
exists ( ) : boolean | Indicates whether the file exists in the filesystem. | |
getContent ( array $metadata = [] ) : string | Returns the content. | |
getKey ( ) : string | Returns the key. | |
getMtime ( ) : integer | Returns the file modified time. | |
getName ( ) : string | ||
getSize ( ) : integer | ||
setContent ( string $content, array $metadata = [] ) : integer | Sets the content. | |
setName ( string $name ) | ||
setSize ( integer $size ) |
Method | Description | |
---|---|---|
setMetadata ( array $metadata ) : boolean | Sets the metadata array to be stored in adapters that can support it. |
Method | Description | |
---|---|---|
supportsMetadata ( ) : boolean |
public __construct ( string $key, gaufrette\Filesystem $filesystem ) | ||
$key | string | |
$filesystem | gaufrette\Filesystem |
public createStream ( ) : gaufrette\Stream | ||
return | gaufrette\Stream |
public getContent ( array $metadata = [] ) : string | ||
$metadata | array | optional metadata which should be set when read |
return | string |
protected setMetadata ( array $metadata ) : boolean | ||
$metadata | array | |
return | boolean |
protected $content |
protected $metadata |