getObjectUrl() public method

Returns the URL to an object identified by its bucket and key. If an expiration time is provided, the URL will be signed and set to expire at the provided time.
public getObjectUrl ( string $bucket, string $key, mixed $expires = null, array $args = [] ) : string
$bucket string The name of the bucket where the object is located
$key string The key of the object
$expires mixed The time at which the URL should expire
$args array Arguments to the GetObject command. Additionally you can specify a "Scheme" if you would like the URL to use a different scheme than what the client is configured to use
return string The URL to the object
Ejemplo n.º 1
0
 /**
  * Returns the URL to an object identified by its bucket and key. If an expiration time is provided, the URL will
  * be signed and set to expire at the provided time.
  *
  * @param string $bucket  The name of the bucket where the object is located
  * @param string $key     The key of the object
  * @param mixed  $expires The time at which the URL should expire
  * @param array  $args    Arguments to the GetObject command. Additionally you can specify a "Scheme" if you would
  *                        like the URL to use a different scheme than what the client is configured to use
  *
  * @return string The URL to the object
  */
 public function getObjectUrl($bucket, $key, $expires = null, array $args = [])
 {
     return $this->instance->getObjectUrl($bucket, $key, $expires, $args);
 }