28 $contents = $this->filesystem->listContents($directory, $recursive);
31 if ($object[
'type'] ===
'file') {
32 $missingKeys = array_diff(
$keys, array_keys($object));
33 $contents[
$index] = array_reduce($missingKeys, [$this,
'getMetadataByName'], $object);
50 $method =
'get' . ucfirst(
$key);
52 if ( ! method_exists($this->filesystem, $method)) {
53 throw new \InvalidArgumentException(
'Could not get meta-data for key: ' .
$key);
56 $object[
$key] = $this->filesystem->{$method}($object[
'path']);
getMethod()
Get the method name.
handle(array $keys=[], $directory='', $recursive=false)
List contents with metadata.
getMetadataByName(array $object, $key)
Get a meta-data value by key name.
Create styles array
The data for the language used.