2 declare(strict_types = 1);
38 public function getMimeTypesForFileExtension(
string $fileExtension): array
41 $fileExtension = strtolower($fileExtension);
42 foreach ($this->collection->getMap() as $mimeType => $availableExtensions) {
43 if (in_array($fileExtension, $availableExtensions,
true)) {
44 $mimeTypes[] = $mimeType;
54 public function getFileExtensionsForMimeType(
string $mimeType): array
56 return $this->collection->getMap()[strtolower($mimeType)] ?? [];