@@ -33,15 +33,27 @@ namespace FastRoute {
3333
3434 function simpleDispatcher (
3535 (function (RouteCollector ): void ) $routeDefinitionCallback ,
36- array <string , string > $options = []): Dispatcher ;
36+ shape(
37+ ' routeParser' => ?classname <RouteParser >,
38+ ' dataGenerator' => ?classname <DataGenerator >,
39+ ' dispatcher' => ?classname <Dispatcher >,
40+ ' routeCollector' => ?classname <RouteCollector >,
41+ ) $options = shape ()): Dispatcher ;
3742
3843 function cachedDispatcher (
3944 (function (RouteCollector ): void ) $routeDefinitionCallback ,
40- array <string , string > $options = []): Dispatcher ;
45+ shape(
46+ ' routeParser' => ?classname <RouteParser >,
47+ ' dataGenerator' => ?classname <DataGenerator >,
48+ ' dispatcher' => ?classname <Dispatcher >,
49+ ' routeCollector' => ?classname <RouteCollector >,
50+ ' cacheDisabled' => ?bool ,
51+ ' cacheFile' => ?string ,
52+ ) $options = shape ()): Dispatcher ;
4153}
4254
4355namespace FastRoute\DataGenerator {
44- abstract class RegexBasedAbstract implements DataGenerator {
56+ abstract class RegexBasedAbstract implements \ FastRoute \ DataGenerator {
4557 protected abstract function getApproxChunkSize ();
4658 protected abstract function processChunk ($regexToRoutesMap );
4759
@@ -71,7 +83,7 @@ namespace FastRoute\DataGenerator {
7183}
7284
7385namespace FastRoute\Dispatcher {
74- abstract class RegexBasedAbstract implements Dispatcher {
86+ abstract class RegexBasedAbstract implements \ FastRoute \ Dispatcher {
7587 protected abstract function dispatchVariableRoute (array <array > $routeData , string $uri ): array ;
7688
7789 public function dispatch (string $httpMethod , string $uri ): array ;
@@ -99,7 +111,7 @@ namespace FastRoute\Dispatcher {
99111}
100112
101113namespace FastRoute\RouteParser {
102- class Std implements RouteParser {
114+ class Std implements \ FastRoute \ RouteParser {
103115 const string VARIABLE_REGEX = <<<'REGEX '
104116\{
105117 \s* ([a-zA-Z][a-zA-Z0-9_]*) \s*
0 commit comments