From f36fc533a7454990ea8f588f2eadda9e90174ed4 Mon Sep 17 00:00:00 2001 From: Guy Sartorelli Date: Thu, 11 Jan 2024 14:16:08 +1300 Subject: [PATCH] ENH Add generic types --- src/Extensions/ClientConfigProvider.php | 4 ++++ src/Extensions/DevBuildExtension.php | 4 ++++ src/Extensions/QueryRecorderExtension.php | 2 ++ src/Extensions/TestSessionEnvironmentExtension.php | 4 ++++ 4 files changed, 14 insertions(+) diff --git a/src/Extensions/ClientConfigProvider.php b/src/Extensions/ClientConfigProvider.php index f9a6b061..417e6268 100644 --- a/src/Extensions/ClientConfigProvider.php +++ b/src/Extensions/ClientConfigProvider.php @@ -2,10 +2,14 @@ namespace SilverStripe\GraphQL\Extensions; +use SilverStripe\Admin\LeftAndMain; use SilverStripe\Core\Config\Config; use SilverStripe\Core\Extension; use SilverStripe\GraphQL\Controller; +/** + * @extends Extension + */ class ClientConfigProvider extends Extension { public function updateClientConfig(array &$config): void diff --git a/src/Extensions/DevBuildExtension.php b/src/Extensions/DevBuildExtension.php index 64ce1579..40836ad2 100644 --- a/src/Extensions/DevBuildExtension.php +++ b/src/Extensions/DevBuildExtension.php @@ -8,8 +8,12 @@ use SilverStripe\Core\Injector\Injector; use SilverStripe\GraphQL\Dev\Build; use SilverStripe\GraphQL\Schema\Logger; +use SilverStripe\ORM\DatabaseAdmin; use SilverStripe\ORM\DataExtension; +/** + * @extends DataExtension + */ class DevBuildExtension extends DataExtension { use Configurable; diff --git a/src/Extensions/QueryRecorderExtension.php b/src/Extensions/QueryRecorderExtension.php index 532aade7..d447476c 100644 --- a/src/Extensions/QueryRecorderExtension.php +++ b/src/Extensions/QueryRecorderExtension.php @@ -11,6 +11,8 @@ /** * Attaches itself to {@see DataQuery} and records any classes that are queried within a closure context. * Allows code to measure and detect affected classes within any operation. E.g. for caching. + * + * @extends DataExtension */ class QueryRecorderExtension extends DataExtension { diff --git a/src/Extensions/TestSessionEnvironmentExtension.php b/src/Extensions/TestSessionEnvironmentExtension.php index bad63a85..058a0e7e 100644 --- a/src/Extensions/TestSessionEnvironmentExtension.php +++ b/src/Extensions/TestSessionEnvironmentExtension.php @@ -8,7 +8,11 @@ use SilverStripe\GraphQL\Schema\SchemaBuilder; use SilverStripe\GraphQL\Schema\Exception\EmptySchemaException; use SilverStripe\GraphQL\Dev\Benchmark; +use SilverStripe\TestSession\TestSessionEnvironment; +/** + * @extends Extension + */ class TestSessionEnvironmentExtension extends Extension { /**