diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-08-16 13:59:28 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-08-16 13:59:28 +0900 |
| commit | b4ab3df2ec85fbe477d7721344a8cd3630b437a1 (patch) | |
| tree | eb618cbbdfa46cf829031f9c427dc09ef7584831 /crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs | |
| parent | baf9aff3134ac5a10260d3be421a2c17a0180d64 (diff) | |
| download | php-shirabe-b4ab3df2ec85fbe477d7721344a8cd3630b437a1.tar.gz php-shirabe-b4ab3df2ec85fbe477d7721344a8cd3630b437a1.tar.zst php-shirabe-b4ab3df2ec85fbe477d7721344a8cd3630b437a1.zip | |
feat(plugin): guard Rust-owned classes the worker has no proxy for
The worker's autoloader fell through to the real Composer source for every
Rust-owned FQCN without a proxy stub, so plugin code doing `new Filesystem()`
or subclassing `LibraryInstaller` silently ran on a second instance the Rust
side never sees. An unimplemented part of the plugin API has to fail with an
explicit error naming it, not quietly work on a disconnected copy.
The stub generator now emits a guard class for each of those FQCNs: the real
declaration, hierarchy and constants, with every constructor and method
raising an explicit error. References satisfied by the declaration alone
(`instanceof`, `X::class`, `Link::TYPE_REQUIRE`) keep working. Two FQCNs stay
resolvable to the real class, each listed with the worker-side mechanism that
makes a natively constructed instance correct.
The error had nowhere to go: `Installer::run` dropped the `Result` of both
`dispatch_script` calls, so an exception from a listener ended in exit 0.
Both propagate now, the way the exception does upstream.
Three real-plugin E2E comparisons stop at a guard and are ignored, each
naming the class it needs.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Diffstat (limited to 'crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs')
9 files changed, 1137 insertions, 0 deletions
diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/ForgejoDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/ForgejoDriver.php new file mode 100644 index 00000000..0e812dfe --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/ForgejoDriver.php @@ -0,0 +1,122 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\ForgejoDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; +use Composer\Util\Http\Response; + +class ForgejoDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + protected function setupGitDriver(string $url): void + { + \ShirabeUnsupportedClass::fail(self::class, 'setupGitDriver'); + } + + protected function getNextPage(Response $response): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getNextPage'); + } + + protected function getContents(string $url, bool $fetchingRepoData = false): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + protected function attemptCloneFallback(): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'attemptCloneFallback'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/FossilDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/FossilDriver.php new file mode 100644 index 00000000..0bf55416 --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/FossilDriver.php @@ -0,0 +1,116 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\FossilDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; + +class FossilDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + protected function checkFossil(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'checkFossil'); + } + + protected function updateLocalRepo(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'updateLocalRepo'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + protected function getContents(string $url): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitBitbucketDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitBitbucketDriver.php new file mode 100644 index 00000000..1249b6a9 --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitBitbucketDriver.php @@ -0,0 +1,137 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\GitBitbucketDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; +use Composer\Util\Http\Response; + +class GitBitbucketDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + protected function getRepoData(): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'getRepoData'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + protected function fetchWithOAuthCredentials(string $url, bool $fetchingRepoData = false): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'fetchWithOAuthCredentials'); + } + + protected function generateSshUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'generateSshUrl'); + } + + protected function attemptCloneFallback(): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'attemptCloneFallback'); + } + + protected function setupFallbackDriver(string $url): void + { + \ShirabeUnsupportedClass::fail(self::class, 'setupFallbackDriver'); + } + + protected function parseCloneUrls(array $cloneLinks): void + { + \ShirabeUnsupportedClass::fail(self::class, 'parseCloneUrls'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + protected function getContents(string $url): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitDriver.php new file mode 100644 index 00000000..ae4ed49b --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitDriver.php @@ -0,0 +1,106 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\GitDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\IO\IOInterface; +use Composer\Config; + +class GitDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + protected function getContents(string $url): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitHubDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitHubDriver.php new file mode 100644 index 00000000..32b3551d --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitHubDriver.php @@ -0,0 +1,147 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\GitHubDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; +use Composer\Util\Http\Response; + +class GitHubDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function getRepositoryUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRepositoryUrl'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + protected function getApiUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getApiUrl'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + public function getRepoData(): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getRepoData'); + } + + protected function generateSshUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'generateSshUrl'); + } + + protected function getContents(string $url, bool $fetchingRepoData = false): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + protected function fetchRootIdentifier(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'fetchRootIdentifier'); + } + + protected function attemptCloneFallback(?\Throwable $e = null): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'attemptCloneFallback'); + } + + protected function setupGitDriver(string $url): void + { + \ShirabeUnsupportedClass::fail(self::class, 'setupGitDriver'); + } + + protected function getNextPage(Response $response): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getNextPage'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitLabDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitLabDriver.php new file mode 100644 index 00000000..b1d0c34d --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/GitLabDriver.php @@ -0,0 +1,165 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\GitLabDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; +use Composer\Util\HttpDownloader; +use Composer\Util\Http\Response; + +class GitLabDriver extends VcsDriver +{ + public const URL_REGEX = '#^(?:(?P<scheme>https?)://(?P<domain>.+?)(?::(?P<port>[0-9]+))?/|git@(?P<domain2>[^:]+):)(?P<parts>.+)/(?P<repo>[^/]+?)(?:\.git|/)?$#'; + + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function setHttpDownloader(HttpDownloader $httpDownloader): void + { + \ShirabeUnsupportedClass::fail(self::class, 'setHttpDownloader'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getRepositoryUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRepositoryUrl'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getApiUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getApiUrl'); + } + + protected function getReferences(string $type): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getReferences'); + } + + protected function fetchProject(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'fetchProject'); + } + + protected function attemptCloneFallback(): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'attemptCloneFallback'); + } + + protected function generateSshUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'generateSshUrl'); + } + + protected function generatePublicUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'generatePublicUrl'); + } + + protected function setupGitDriver(string $url): void + { + \ShirabeUnsupportedClass::fail(self::class, 'setupGitDriver'); + } + + protected function getContents(string $url, bool $fetchingRepoData = false): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + public function getRepoData(): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getRepoData'); + } + + protected function getNextPage(Response $response): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getNextPage'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/HgDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/HgDriver.php new file mode 100644 index 00000000..18cf388d --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/HgDriver.php @@ -0,0 +1,106 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\HgDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; + +class HgDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + protected function getContents(string $url): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/PerforceDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/PerforceDriver.php new file mode 100644 index 00000000..fbff0a56 --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/PerforceDriver.php @@ -0,0 +1,117 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\PerforceDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; +use Composer\Util\Http\Response; + +class PerforceDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + public function getContents(string $url): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } + + public function getDepot(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getDepot'); + } + + public function getBranch(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranch'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } +} diff --git a/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/SvnDriver.php b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/SvnDriver.php new file mode 100644 index 00000000..3f9b1569 --- /dev/null +++ b/crates/shirabe-php-rpc/php/guards/Composer/Repository/Vcs/SvnDriver.php @@ -0,0 +1,121 @@ +<?php + +// Generated by scripts/plugin-stub-generator; do not edit by hand. +// Guard for Composer\Repository\Vcs\SvnDriver. +// The Rust side owns this class and the worker has no proxy for it, so this +// declaration shadows the real one: the constants and the hierarchy stay, while +// constructing it or calling anything on it raises an explicit error. +// Composer\Repository\Vcs\VcsDriver::__construct() is final, so it keeps running the real implementation here. + +namespace Composer\Repository\Vcs; + +use Composer\Config; +use Composer\IO\IOInterface; + +class SvnDriver extends VcsDriver +{ + public function __construct() + { + \ShirabeUnsupportedClass::fail(self::class, '__construct'); + } + + public function initialize(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'initialize'); + } + + public function getRootIdentifier(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getRootIdentifier'); + } + + public function getUrl(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getUrl'); + } + + public function getSource(string $identifier): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getSource'); + } + + public function getDist(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getDist'); + } + + protected function shouldCache(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'shouldCache'); + } + + public function getComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getComposerInformation'); + } + + public function getFileContent(string $file, string $identifier): ?string + { + \ShirabeUnsupportedClass::fail(self::class, 'getFileContent'); + } + + public function getChangeDate(string $identifier): ?\DateTimeImmutable + { + \ShirabeUnsupportedClass::fail(self::class, 'getChangeDate'); + } + + public function getTags(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getTags'); + } + + public function getBranches(): array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBranches'); + } + + public static function supports(IOInterface $io, Config $config, string $url, bool $deep = false): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'supports'); + } + + protected static function normalizeUrl(string $url): string + { + \ShirabeUnsupportedClass::fail(self::class, 'normalizeUrl'); + } + + protected function execute(array $command, string $url): string + { + \ShirabeUnsupportedClass::fail(self::class, 'execute'); + } + + protected function buildIdentifier(string $baseDir, int $revision): string + { + \ShirabeUnsupportedClass::fail(self::class, 'buildIdentifier'); + } + + protected function getBaseComposerInformation(string $identifier): ?array + { + \ShirabeUnsupportedClass::fail(self::class, 'getBaseComposerInformation'); + } + + public function hasComposerFile(string $identifier): bool + { + \ShirabeUnsupportedClass::fail(self::class, 'hasComposerFile'); + } + + protected function getScheme(): string + { + \ShirabeUnsupportedClass::fail(self::class, 'getScheme'); + } + + protected function getContents(string $url): Response + { + \ShirabeUnsupportedClass::fail(self::class, 'getContents'); + } + + public function cleanup(): void + { + \ShirabeUnsupportedClass::fail(self::class, 'cleanup'); + } +} |
