Skip to content

Commit a34d109

Browse files
committed
Add generics to ContainerInterface
1 parent 7079847 commit a34d109

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/ContainerInterface.php

+4-2
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,14 @@ interface ContainerInterface
1212
/**
1313
* Finds an entry of the container by its identifier and returns it.
1414
*
15-
* @param string $id Identifier of the entry to look for.
15+
* @template T of mixed
16+
*
17+
* @param T|string $id Identifier of the entry to look for.
1618
*
1719
* @throws NotFoundExceptionInterface No entry was found for **this** identifier.
1820
* @throws ContainerExceptionInterface Error while retrieving the entry.
1921
*
20-
* @return mixed Entry.
22+
* @return T|mixed Entry.
2123
*/
2224
public function get(string $id);
2325

0 commit comments

Comments
 (0)