diff --git a/CHANGELOG.md b/CHANGELOG.md index 407b96ce..65d810e1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## Not released yet +### Fixes + +Add more missing vendor classes into stubs + ## 0.21.0 (2024-11-19) ### Features diff --git a/src/ExpressionLanguage.php b/src/ExpressionLanguage.php index cb4a644b..9f086262 100644 --- a/src/ExpressionLanguage.php +++ b/src/ExpressionLanguage.php @@ -5,6 +5,7 @@ use Symfony\Component\ExpressionLanguage\ExpressionFunction; use Symfony\Component\ExpressionLanguage\ExpressionLanguage as SymfonyExpressionLanguage; +/** @internal */ class ExpressionLanguage extends SymfonyExpressionLanguage { public function __construct( diff --git a/src/Helper/Notifier.php b/src/Helper/Notifier.php index de1716dd..ef124b49 100644 --- a/src/Helper/Notifier.php +++ b/src/Helper/Notifier.php @@ -10,6 +10,7 @@ use function Castor\context; +/** @internal */ class Notifier { public function __construct( diff --git a/src/Stub/StubsGenerator.php b/src/Stub/StubsGenerator.php index 2fe6c0d3..4e982bdc 100644 --- a/src/Stub/StubsGenerator.php +++ b/src/Stub/StubsGenerator.php @@ -57,30 +57,61 @@ private function generateCastorStubs(string $dest): void // Add some very frequently used classes $frequentlyUsedClasses = [ + \Psr\Cache\CacheItemInterface::class, + \Psr\Cache\CacheItemPoolInterface::class, + \Psr\Cache\InvalidArgumentException::class, + \Psr\Cache\CacheException::class, + LoggerInterface::class, \Symfony\Component\Console\Application::class, + \Symfony\Component\Console\Command\Command::class, \Symfony\Component\Console\Completion\CompletionInput::class, + \Symfony\Component\Console\Helper\ProgressBar::class, + \Symfony\Component\Console\Helper\TableSeparator::class, + \Symfony\Component\Console\Helper\TableStyle::class, \Symfony\Component\Console\Input\InputArgument::class, \Symfony\Component\Console\Input\InputInterface::class, \Symfony\Component\Console\Input\InputOption::class, \Symfony\Component\Console\Output\OutputInterface::class, + \Symfony\Component\Console\Question\Question::class, \Symfony\Component\Console\Style\SymfonyStyle::class, + \Symfony\Contracts\EventDispatcher\Event::class, + \Symfony\Component\EventDispatcher\EventDispatcherInterface::class, + \Symfony\Component\EventDispatcher\EventSubscriberInterface::class, \Symfony\Component\Filesystem\Exception\ExceptionInterface::class, + \Symfony\Component\Filesystem\Exception\FileNotFoundException::class, + \Symfony\Component\Filesystem\Exception\InvalidArgumentException::class, + \Symfony\Component\Filesystem\Exception\IOException::class, + \Symfony\Component\Filesystem\Exception\RuntimeException::class, \Symfony\Component\Filesystem\Filesystem::class, \Symfony\Component\Filesystem\Path::class, + \Symfony\Component\Finder\Exception\DirectoryNotFoundException::class, Finder::class, \Symfony\Component\Finder\SplFileInfo::class, \Symfony\Component\Process\Exception\ExceptionInterface::class, + \Symfony\Component\Process\Exception\LogicException::class, + \Symfony\Component\Process\Exception\ProcessFailedException::class, + \Symfony\Component\Process\Exception\ProcessSignaledException::class, + \Symfony\Component\Process\Exception\ProcessTimedOutException::class, + \Symfony\Component\Process\Exception\RuntimeException::class, \Symfony\Component\Process\ExecutableFinder::class, \Symfony\Component\Process\Process::class, - \Symfony\Contracts\HttpClient\Exception\ExceptionInterface::class, - \Symfony\Contracts\HttpClient\HttpClientInterface::class, - \Symfony\Contracts\HttpClient\ResponseInterface::class, \Symfony\Component\String\AbstractString::class, \Symfony\Component\String\AbstractUnicodeString::class, \Symfony\Component\String\ByteString::class, \Symfony\Component\String\CodePointString::class, \Symfony\Component\String\Exception\ExceptionInterface::class, \Symfony\Component\String\UnicodeString::class, + \Symfony\Contracts\Cache\CacheInterface::class, + \Symfony\Contracts\Cache\CallbackInterface::class, + \Symfony\Contracts\Cache\ItemInterface::class, + \Symfony\Contracts\HttpClient\Exception\ClientExceptionInterface::class, + \Symfony\Contracts\HttpClient\Exception\ExceptionInterface::class, + \Symfony\Contracts\HttpClient\Exception\RedirectionExceptionInterface::class, + \Symfony\Contracts\HttpClient\Exception\ServerExceptionInterface::class, + \Symfony\Contracts\HttpClient\Exception\TransportExceptionInterface::class, + \Symfony\Contracts\HttpClient\HttpClientInterface::class, + \Symfony\Contracts\HttpClient\ResponseInterface::class, + \Symfony\Contracts\HttpClient\ResponseStreamInterface::class, ]; foreach ($frequentlyUsedClasses as $class) {