\S3ContentReader
Read content from haylix cdn
- Author: marcus@symbiote.com.au
- License: BSD License http://silverstripe.org/bsd-license/
Synopsis
class S3ContentReader
extends ContentReader
{
- // members
- public string $bucket = 'bucket';
- public S3Client $s3Service;
- private Model $s3Info;
- public string $baseUrl = 'https://s3.amazonaws.com';
- protected $listedItems = NULL;
- // methods
- public Model getInfo()
- public void setS3Info()
- public void isReadable()
- public boolean isListable()
- protected void listId()
- public S3ContentReader getList()
- public void getBaseUrl()
- public string getURL()
- public void getBaseHost()
- public void getSecureURL()
- public string read()
- public boolean exists()
- public void providerOfUrl()
Hierarchy
Extends
- ContentReader
Members
private
- $s3Info — Guzzle\Service\Resource\Model
protected
- $listedItems
public
- $baseUrl
—
string
The base URL to use with the s3 managed asset. Allows the use of CloudFront base urls instead. - $bucket
- $s3Service — S3Client
Methods
protected
public
- exists() — Check that the object exists remotely
- getBaseHost()
- getBaseUrl()
- getInfo()
- getList() — Returns a list of content readers for a given s3 folder
- getSecureURL() — Get a secure URL set to expire in $expires seconds time
- getURL() — Get a url to this piece of content
- isListable() — An S3 object is listable if its content type is a directory
- isReadable()
- providerOfUrl()
- read() — Read this content as a string
- setS3Info() — Set the S3 information about this item directly if available