src/Resolver/ProtocolBasedReaderResolver.php 1 location
|
@@ 55-57 (lines=3) @@
|
| 52 |
|
*/ |
| 53 |
|
public function resolveReader(ResourceUri $resource) |
| 54 |
|
{ |
| 55 |
|
if (! array_key_exists($resource->getProtocol(), $this->protocolFactoryIndexes)) { |
| 56 |
|
throw new \RuntimeException('Unsupported protocol: ' . $resource->getProtocol() . '( ' . $resource . ')'); |
| 57 |
|
} |
| 58 |
|
|
| 59 |
|
/** @var int $factoryIndex */ |
| 60 |
|
$factoryIndex = $this->protocolFactoryIndexes[$resource->getProtocol()]; |
src/Resolver/ProtocolBasedWriterResolver.php 1 location
|
@@ 54-56 (lines=3) @@
|
| 51 |
|
*/ |
| 52 |
|
public function resolveWriter(ResourceUri $resource) |
| 53 |
|
{ |
| 54 |
|
if (! array_key_exists($resource->getProtocol(), $this->protocolWriterIndexes)) { |
| 55 |
|
throw new \RuntimeException('Unsupported protocol: ' . $resource->getProtocol() . '( ' . $resource . ')'); |
| 56 |
|
} |
| 57 |
|
|
| 58 |
|
/** @var int $index */ |
| 59 |
|
$index = $this->protocolWriterIndexes[$resource->getProtocol()]; |