PHP Class Aws\S3\S3Client

Inheritance: extends Aws\Common\Client\AbstractClient
Show file Open project: aws/aws-sdk-php Class Usage Examples

Public Methods

Method Description
__construct ( array $args )
_applyApiProvider ( $value, array &$args, Aws\HandlerList $list )
_applyRetryConfig ( $value, $_, Aws\HandlerList $list )
applyDocFilters ( array $api, array $docs )
createPresignedRequest ( Aws\CommandInterface $command, $expires )
encodeKey ( string $key ) : string Raw URL encode a key and allow for '/' characters
getArguments ( )
getObjectUrl ( $bucket, $key )
isBucketDnsCompatible ( string $bucket ) : boolean Determine if a string is a valid name for a DNS compatible Amazon S3 bucket.

Private Methods

Method Description
getEncodingTypeMiddleware ( ) : Closure Provides a middleware that autopopulates the EncodingType parameter on ListObjects commands.
getHeadObjectMiddleware ( ) : Closure Provides a middleware that disables content decoding on HeadObject commands.
getLocationConstraintMiddleware ( ) : Closure Provides a middleware that removes the need to specify LocationConstraint on CreateBucket.
getSaveAsParameter ( ) : Closure Provides a middleware that supports the SaveAs parameter.

Method Details

__construct() public method

In addition to the options available to {@see \Aws\AwsClient::__construct}, S3Client accepts the following options: - bucket_endpoint: (bool) Set to true to send requests to a hardcoded bucket endpoint rather than create an endpoint as a result of injecting the bucket into the URL. This option is useful for interacting with CNAME endpoints. - calculate_md5: (bool) Set to false to disable calculating an MD5 for all Amazon S3 signed uploads. - use_accelerate_endpoint: (bool) Set to true to send requests to an S3 Accelerate endpoint by default. Can be enabled or disabled on individual operations by setting '@use_accelerate_endpoint' to true or false. Note: you must enable S3 Accelerate on a bucket before it can be accessed via an Accelerate endpoint. - use_dual_stack_endpoint: (bool) Set to true to send requests to an S3 Dual Stack endpoint by default, which enables IPv6 Protocol. Can be enabled or disabled on individual operations by setting '@use_dual_stack_endpoint\' to true or false. Note: you cannot use it together with an accelerate endpoint.
public __construct ( array $args )
$args array

_applyApiProvider() public static method

public static _applyApiProvider ( $value, array &$args, Aws\HandlerList $list )
$args array
$list Aws\HandlerList

_applyRetryConfig() public static method

public static _applyRetryConfig ( $value, $_, Aws\HandlerList $list )
$list Aws\HandlerList

applyDocFilters() public static method

public static applyDocFilters ( array $api, array $docs )
$api array
$docs array

createPresignedRequest() public method

public createPresignedRequest ( Aws\CommandInterface $command, $expires )
$command Aws\CommandInterface

encodeKey() public static method

Raw URL encode a key and allow for '/' characters
public static encodeKey ( string $key ) : string
$key string Key to encode
return string Returns the encoded key

getArguments() public static method

public static getArguments ( )

getObjectUrl() public method

public getObjectUrl ( $bucket, $key )

isBucketDnsCompatible() public static method

DNS compatible bucket names can be used as a subdomain in a URL (e.g., ".s3.amazonaws.com").
public static isBucketDnsCompatible ( string $bucket ) : boolean
$bucket string Bucket name to check.
return boolean