PHP Class Gaufrette\Adapter\AwsS3

Author: Michael Dowling ([email protected])
Inheritance: implements Gaufrette\Adapter, implements Gaufrette\Adapter\MetadataSupporter, implements Gaufrette\Adapter\ListKeysAware, implements Gaufrette\Adapter\SizeCalculator
Afficher le fichier Open project: knplabs/gaufrette Class Usage Examples

Protected Properties

Свойство Type Description
$bucket
$bucketExists
$detectContentType
$metadata
$options
$service

Méthodes publiques

Méthode Description
__construct ( S3Client $service, $bucket, array $options = [], $detectContentType = false )
delete ( $key )
exists ( $key )
getMetadata ( $key )
getUrl ( string $key, array $options = [] ) : string Gets the publicly accessible URL of an Amazon S3 object.
isDirectory ( $key )
keys ( )
listKeys ( $prefix = '' )
mtime ( $key )
read ( $key )
rename ( $sourceKey, $targetKey )
setMetadata ( $key, $metadata )
size ( $key )
write ( $key, $content )

Méthodes protégées

Méthode Description
computeKey ( string $path ) Computes the key from the specified path.
computePath ( $key )
ensureBucketExists ( ) Ensures the specified bucket exists. If the bucket does not exists and the create option is set to true, it will try to create the bucket. The bucket is created using the same region as the supplied client object.
getOptions ( $key, array $options = [] )

Method Details

__construct() public méthode

public __construct ( S3Client $service, $bucket, array $options = [], $detectContentType = false )
$service Aws\S3\S3Client
$options array

computeKey() protected méthode

Computes the key from the specified path.
protected computeKey ( string $path )
$path string return string

computePath() protected méthode

protected computePath ( $key )

delete() public méthode

public delete ( $key )

ensureBucketExists() protected méthode

Ensures the specified bucket exists. If the bucket does not exists and the create option is set to true, it will try to create the bucket. The bucket is created using the same region as the supplied client object.
protected ensureBucketExists ( )

exists() public méthode

public exists ( $key )

getMetadata() public méthode

public getMetadata ( $key )

getOptions() protected méthode

protected getOptions ( $key, array $options = [] )
$options array

getUrl() public méthode

Gets the publicly accessible URL of an Amazon S3 object.
public getUrl ( string $key, array $options = [] ) : string
$key string Object key
$options array Associative array of options used to buld the URL - expires: The time at which the URL should expire represented as a UNIX timestamp - Any options available in the Amazon S3 GetObject operation may be specified.
Résultat string

isDirectory() public méthode

public isDirectory ( $key )

keys() public méthode

public keys ( )

listKeys() public méthode

public listKeys ( $prefix = '' )

mtime() public méthode

public mtime ( $key )

read() public méthode

public read ( $key )

rename() public méthode

public rename ( $sourceKey, $targetKey )

setMetadata() public méthode

public setMetadata ( $key, $metadata )

size() public méthode

public size ( $key )

write() public méthode

public write ( $key, $content )

Property Details

$bucket protected_oe property

protected $bucket

$bucketExists protected_oe property

protected $bucketExists

$detectContentType protected_oe property

protected $detectContentType

$metadata protected_oe property

protected $metadata

$options protected_oe property

protected $options

$service protected_oe property

protected $service