Skip to content

Add @method declarations to Interfaces #2998

@donatj

Description

@donatj

Describe the feature

Currently @method declarations 's only exist on the implementations but not the interface -

Compare

S3Client

* @method \Aws\Result abortMultipartUpload(array $args = [])
* @method \GuzzleHttp\Promise\Promise abortMultipartUploadAsync(array $args = [])
* @method \Aws\Result completeMultipartUpload(array $args = [])
* @method \GuzzleHttp\Promise\Promise completeMultipartUploadAsync(array $args = [])
* @method \Aws\Result copyObject(array $args = [])
* @method \GuzzleHttp\Promise\Promise copyObjectAsync(array $args = [])
* @method \Aws\Result createBucket(array $args = [])
* @method \GuzzleHttp\Promise\Promise createBucketAsync(array $args = [])
* @method \Aws\Result createMultipartUpload(array $args = [])
* @method \GuzzleHttp\Promise\Promise createMultipartUploadAsync(array $args = [])
* @method \Aws\Result createSession(array $args = [])
* @method \GuzzleHttp\Promise\Promise createSessionAsync(array $args = [])
* @method \Aws\Result deleteBucket(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketAsync(array $args = [])
* @method \Aws\Result deleteBucketAnalyticsConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketAnalyticsConfigurationAsync(array $args = [])
* @method \Aws\Result deleteBucketCors(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketCorsAsync(array $args = [])
* @method \Aws\Result deleteBucketEncryption(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketEncryptionAsync(array $args = [])
* @method \Aws\Result deleteBucketIntelligentTieringConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketIntelligentTieringConfigurationAsync(array $args = [])
* @method \Aws\Result deleteBucketInventoryConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketInventoryConfigurationAsync(array $args = [])
* @method \Aws\Result deleteBucketLifecycle(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketLifecycleAsync(array $args = [])
* @method \Aws\Result deleteBucketMetricsConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketMetricsConfigurationAsync(array $args = [])
* @method \Aws\Result deleteBucketOwnershipControls(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketOwnershipControlsAsync(array $args = [])
* @method \Aws\Result deleteBucketPolicy(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketPolicyAsync(array $args = [])
* @method \Aws\Result deleteBucketReplication(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketReplicationAsync(array $args = [])
* @method \Aws\Result deleteBucketTagging(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketTaggingAsync(array $args = [])
* @method \Aws\Result deleteBucketWebsite(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteBucketWebsiteAsync(array $args = [])
* @method \Aws\Result deleteObject(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteObjectAsync(array $args = [])
* @method \Aws\Result deleteObjectTagging(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteObjectTaggingAsync(array $args = [])
* @method \Aws\Result deleteObjects(array $args = [])
* @method \GuzzleHttp\Promise\Promise deleteObjectsAsync(array $args = [])
* @method \Aws\Result deletePublicAccessBlock(array $args = [])
* @method \GuzzleHttp\Promise\Promise deletePublicAccessBlockAsync(array $args = [])
* @method \Aws\Result getBucketAccelerateConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketAccelerateConfigurationAsync(array $args = [])
* @method \Aws\Result getBucketAcl(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketAclAsync(array $args = [])
* @method \Aws\Result getBucketAnalyticsConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketAnalyticsConfigurationAsync(array $args = [])
* @method \Aws\Result getBucketCors(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketCorsAsync(array $args = [])
* @method \Aws\Result getBucketEncryption(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketEncryptionAsync(array $args = [])
* @method \Aws\Result getBucketIntelligentTieringConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketIntelligentTieringConfigurationAsync(array $args = [])
* @method \Aws\Result getBucketInventoryConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketInventoryConfigurationAsync(array $args = [])
* @method \Aws\Result getBucketLifecycle(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketLifecycleAsync(array $args = [])
* @method \Aws\Result getBucketLifecycleConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketLifecycleConfigurationAsync(array $args = [])
* @method \Aws\Result getBucketLocation(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketLocationAsync(array $args = [])
* @method \Aws\Result getBucketLogging(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketLoggingAsync(array $args = [])
* @method \Aws\Result getBucketMetricsConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketMetricsConfigurationAsync(array $args = [])
* @method \Aws\Result getBucketNotification(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketNotificationAsync(array $args = [])
* @method \Aws\Result getBucketNotificationConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketNotificationConfigurationAsync(array $args = [])
* @method \Aws\Result getBucketOwnershipControls(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketOwnershipControlsAsync(array $args = [])
* @method \Aws\Result getBucketPolicy(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketPolicyAsync(array $args = [])
* @method \Aws\Result getBucketPolicyStatus(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketPolicyStatusAsync(array $args = [])
* @method \Aws\Result getBucketReplication(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketReplicationAsync(array $args = [])
* @method \Aws\Result getBucketRequestPayment(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketRequestPaymentAsync(array $args = [])
* @method \Aws\Result getBucketTagging(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketTaggingAsync(array $args = [])
* @method \Aws\Result getBucketVersioning(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketVersioningAsync(array $args = [])
* @method \Aws\Result getBucketWebsite(array $args = [])
* @method \GuzzleHttp\Promise\Promise getBucketWebsiteAsync(array $args = [])
* @method \Aws\Result getObject(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectAsync(array $args = [])
* @method \Aws\Result getObjectAcl(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectAclAsync(array $args = [])
* @method \Aws\Result getObjectAttributes(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectAttributesAsync(array $args = [])
* @method \Aws\Result getObjectLegalHold(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectLegalHoldAsync(array $args = [])
* @method \Aws\Result getObjectLockConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectLockConfigurationAsync(array $args = [])
* @method \Aws\Result getObjectRetention(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectRetentionAsync(array $args = [])
* @method \Aws\Result getObjectTagging(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectTaggingAsync(array $args = [])
* @method \Aws\Result getObjectTorrent(array $args = [])
* @method \GuzzleHttp\Promise\Promise getObjectTorrentAsync(array $args = [])
* @method \Aws\Result getPublicAccessBlock(array $args = [])
* @method \GuzzleHttp\Promise\Promise getPublicAccessBlockAsync(array $args = [])
* @method \Aws\Result headBucket(array $args = [])
* @method \GuzzleHttp\Promise\Promise headBucketAsync(array $args = [])
* @method \Aws\Result headObject(array $args = [])
* @method \GuzzleHttp\Promise\Promise headObjectAsync(array $args = [])
* @method \Aws\Result listBucketAnalyticsConfigurations(array $args = [])
* @method \GuzzleHttp\Promise\Promise listBucketAnalyticsConfigurationsAsync(array $args = [])
* @method \Aws\Result listBucketIntelligentTieringConfigurations(array $args = [])
* @method \GuzzleHttp\Promise\Promise listBucketIntelligentTieringConfigurationsAsync(array $args = [])
* @method \Aws\Result listBucketInventoryConfigurations(array $args = [])
* @method \GuzzleHttp\Promise\Promise listBucketInventoryConfigurationsAsync(array $args = [])
* @method \Aws\Result listBucketMetricsConfigurations(array $args = [])
* @method \GuzzleHttp\Promise\Promise listBucketMetricsConfigurationsAsync(array $args = [])
* @method \Aws\Result listBuckets(array $args = [])
* @method \GuzzleHttp\Promise\Promise listBucketsAsync(array $args = [])
* @method \Aws\Result listDirectoryBuckets(array $args = [])
* @method \GuzzleHttp\Promise\Promise listDirectoryBucketsAsync(array $args = [])
* @method \Aws\Result listMultipartUploads(array $args = [])
* @method \GuzzleHttp\Promise\Promise listMultipartUploadsAsync(array $args = [])
* @method \Aws\Result listObjectVersions(array $args = [])
* @method \GuzzleHttp\Promise\Promise listObjectVersionsAsync(array $args = [])
* @method \Aws\Result listObjects(array $args = [])
* @method \GuzzleHttp\Promise\Promise listObjectsAsync(array $args = [])
* @method \Aws\Result listObjectsV2(array $args = [])
* @method \GuzzleHttp\Promise\Promise listObjectsV2Async(array $args = [])
* @method \Aws\Result listParts(array $args = [])
* @method \GuzzleHttp\Promise\Promise listPartsAsync(array $args = [])
* @method \Aws\Result putBucketAccelerateConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketAccelerateConfigurationAsync(array $args = [])
* @method \Aws\Result putBucketAcl(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketAclAsync(array $args = [])
* @method \Aws\Result putBucketAnalyticsConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketAnalyticsConfigurationAsync(array $args = [])
* @method \Aws\Result putBucketCors(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketCorsAsync(array $args = [])
* @method \Aws\Result putBucketEncryption(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketEncryptionAsync(array $args = [])
* @method \Aws\Result putBucketIntelligentTieringConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketIntelligentTieringConfigurationAsync(array $args = [])
* @method \Aws\Result putBucketInventoryConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketInventoryConfigurationAsync(array $args = [])
* @method \Aws\Result putBucketLifecycle(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketLifecycleAsync(array $args = [])
* @method \Aws\Result putBucketLifecycleConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketLifecycleConfigurationAsync(array $args = [])
* @method \Aws\Result putBucketLogging(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketLoggingAsync(array $args = [])
* @method \Aws\Result putBucketMetricsConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketMetricsConfigurationAsync(array $args = [])
* @method \Aws\Result putBucketNotification(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketNotificationAsync(array $args = [])
* @method \Aws\Result putBucketNotificationConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketNotificationConfigurationAsync(array $args = [])
* @method \Aws\Result putBucketOwnershipControls(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketOwnershipControlsAsync(array $args = [])
* @method \Aws\Result putBucketPolicy(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketPolicyAsync(array $args = [])
* @method \Aws\Result putBucketReplication(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketReplicationAsync(array $args = [])
* @method \Aws\Result putBucketRequestPayment(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketRequestPaymentAsync(array $args = [])
* @method \Aws\Result putBucketTagging(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketTaggingAsync(array $args = [])
* @method \Aws\Result putBucketVersioning(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketVersioningAsync(array $args = [])
* @method \Aws\Result putBucketWebsite(array $args = [])
* @method \GuzzleHttp\Promise\Promise putBucketWebsiteAsync(array $args = [])
* @method \Aws\Result putObject(array $args = [])
* @method \GuzzleHttp\Promise\Promise putObjectAsync(array $args = [])
* @method \Aws\Result putObjectAcl(array $args = [])
* @method \GuzzleHttp\Promise\Promise putObjectAclAsync(array $args = [])
* @method \Aws\Result putObjectLegalHold(array $args = [])
* @method \GuzzleHttp\Promise\Promise putObjectLegalHoldAsync(array $args = [])
* @method \Aws\Result putObjectLockConfiguration(array $args = [])
* @method \GuzzleHttp\Promise\Promise putObjectLockConfigurationAsync(array $args = [])
* @method \Aws\Result putObjectRetention(array $args = [])
* @method \GuzzleHttp\Promise\Promise putObjectRetentionAsync(array $args = [])
* @method \Aws\Result putObjectTagging(array $args = [])
* @method \GuzzleHttp\Promise\Promise putObjectTaggingAsync(array $args = [])
* @method \Aws\Result putPublicAccessBlock(array $args = [])
* @method \GuzzleHttp\Promise\Promise putPublicAccessBlockAsync(array $args = [])
* @method \Aws\Result restoreObject(array $args = [])
* @method \GuzzleHttp\Promise\Promise restoreObjectAsync(array $args = [])
* @method \Aws\Result selectObjectContent(array $args = [])
* @method \GuzzleHttp\Promise\Promise selectObjectContentAsync(array $args = [])
* @method \Aws\Result uploadPart(array $args = [])
* @method \GuzzleHttp\Promise\Promise uploadPartAsync(array $args = [])
* @method \Aws\Result uploadPartCopy(array $args = [])
* @method \GuzzleHttp\Promise\Promise uploadPartCopyAsync(array $args = [])
* @method \Aws\Result writeGetObjectResponse(array $args = [])
* @method \GuzzleHttp\Promise\Promise writeGetObjectResponseAsync(array $args = [])
*/
class S3Client extends AwsClient implements S3ClientInterface

S3ClientInterface

namespace Aws\S3;
use Aws\AwsClientInterface;
use Aws\CommandInterface;
use Aws\ResultInterface;
use Aws\S3\Exception\S3Exception;
use GuzzleHttp\Promise\PromiseInterface;
use Psr\Http\Message\RequestInterface;
interface S3ClientInterface extends AwsClientInterface

Use Case

It would be very helpful for IDEs and static analysis and other such tools if the @methods were also on the interfaces.

Compare current autocompletion for interface vs instance

image image

Proposed Solution

I presume these are generated but I am unsure - it would be nice if whatever generated these could also append them to the interfaces.

If they are not generated, I'd be more than happy to open a PR copying them over myself.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

SDK version used

3.321.13

Environment details (Version of PHP (php -v)? OS name and version, etc.)

PHP 8.3.11 - doesn't matter

Metadata

Metadata

Labels

feature-requestA feature should be added or improved.p3This is a minor priority issuepr/needs-reviewThis PR needs a review from a Member.queuedThis issues is on the AWS team's backlog

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions