class ElementsAdapter implements FilesystemAdapter

Properties

protected Client $client
protected array $cache

File information cache.

protected array $volumePathsCache

Caches the Elements volume paths.

protected array $contentCache

Directory content cache.

Methods

__construct(Client $client)

Constructor

bool
fileExists(string $path)

{@inheritdoc}

bool
directoryExists(string $path)

{@inheritdoc}

void
write(string $path, string $contents, Config $config)

{@inheritdoc}

void
writeStream(string $path, $contents, Config $config)

{@inheritdoc}

string
read(string $path)

{@inheritdoc}

readStream(string $path)

{@inheritdoc}

void
delete(string $path)

{@inheritdoc}

void
deleteDirectory(string $path)

{@inheritdoc}

void
createDirectory(string $path, Config $config)

{@inheritdoc}

void
setVisibility(string $path, string $visibility)

{@inheritdoc}

FileAttributes
visibility(string $path)

{@inheritdoc}

FileAttributes
mimeType(string $path)

{@inheritdoc}

FileAttributes
lastModified(string $path)

{@inheritdoc}

FileAttributes
fileSize(string $path)

{@inheritdoc}

iterable
listContents(string $path, bool $deep)

{@inheritdoc}

void
move(string $source, string $destination, Config $config)

{@inheritdoc}

void
copy(string $source, string $destination, Config $config)

{@inheritdoc}

array|null
getMediaFile(string $path)

Get the media file information.

array
getMediaFiles(string $path)

Get the media file information for all files of a given parent.

Response
getMediaFileDownload(string $path)

Get the content of a media file.

FileAttributes
getFileMetadata(string $path, string $type)

No description

DirectoryAttributes
getMetadata(string $path, string $type)

No description

DirectoryAttributes
parseStorageAttributes(array $attributes)

No description

void
fetchVolumePaths()

No description

array
processFileRoots(array $roots)

No description

Details

at line 55
__construct(Client $client)

Constructor

Parameters

Client $client

at line 66
bool fileExists(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

bool

at line 80
bool directoryExists(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

bool

at line 94
void write(string $path, string $contents, Config $config)

{@inheritdoc}

Parameters

string $path
string $contents
Config $config

Return Value

void

at line 102
void writeStream(string $path, $contents, Config $config)

{@inheritdoc}

Parameters

string $path
$contents
Config $config

Return Value

void

at line 110
string read(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

string

at line 124
readStream(string $path)

{@inheritdoc}

Parameters

string $path

at line 138
void delete(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

void

at line 146
void deleteDirectory(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

void

at line 154
void createDirectory(string $path, Config $config)

{@inheritdoc}

Parameters

string $path
Config $config

Return Value

void

at line 162
void setVisibility(string $path, string $visibility)

{@inheritdoc}

Parameters

string $path
string $visibility

Return Value

void

at line 170
FileAttributes visibility(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

FileAttributes

at line 178
FileAttributes mimeType(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

FileAttributes

at line 186
FileAttributes lastModified(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

FileAttributes

at line 194
FileAttributes fileSize(string $path)

{@inheritdoc}

Parameters

string $path

Return Value

FileAttributes

at line 202
iterable listContents(string $path, bool $deep)

{@inheritdoc}

Parameters

string $path
bool $deep

Return Value

iterable

at line 214
void move(string $source, string $destination, Config $config)

{@inheritdoc}

Parameters

string $source
string $destination
Config $config

Return Value

void

at line 222
void copy(string $source, string $destination, Config $config)

{@inheritdoc}

Parameters

string $source
string $destination
Config $config

Return Value

void

at line 234
protected array|null getMediaFile(string $path)

Get the media file information.

Parameters

string $path

Return Value

array|null

at line 257
protected array getMediaFiles(string $path)

Get the media file information for all files of a given parent.

Parameters

string $path

Path to the parent (directory)

Return Value

array

at line 307
protected Response getMediaFileDownload(string $path)

Get the content of a media file.

Parameters

string $path

Return Value

Response

at line 322
protected FileAttributes getFileMetadata(string $path, string $type)

No description

Parameters

string $path
string $type

Return Value

FileAttributes

at line 333
protected DirectoryAttributes getMetadata(string $path, string $type)

No description

Parameters

string $path
string $type

Return Value

DirectoryAttributes

at line 344
protected DirectoryAttributes parseStorageAttributes(array $attributes)

No description

Parameters

array $attributes

Return Value

DirectoryAttributes

at line 366
protected void fetchVolumePaths()

No description

Return Value

void

at line 375
protected array processFileRoots(array $roots)

No description

Parameters

array $roots

Return Value

array