1 | <?php |
||
15 | class Acl |
||
16 | { |
||
17 | // https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#canned-acl |
||
18 | private $possibleOptions = [ |
||
19 | "authenticated-read", |
||
20 | "aws-exec-read", |
||
21 | "bucket-owner-full-control", |
||
22 | "bucket-owner-read", |
||
23 | "log-delivery-write", |
||
24 | "private", |
||
25 | "public-read", |
||
26 | "public-read-write", |
||
27 | ]; |
||
28 | |||
29 | /** |
||
30 | * @var string |
||
31 | */ |
||
32 | private $name; |
||
33 | |||
34 | public function __construct(string $acl) |
||
38 | |||
39 | /** |
||
40 | * @return string the aws acl policy name. |
||
41 | */ |
||
42 | public function __toString() |
||
46 | |||
47 | /** |
||
48 | * @param string $acl the aws acl policy name. |
||
49 | * |
||
50 | * @throws InvalidAclException |
||
51 | */ |
||
52 | public function setName(string $acl): void |
||
60 | |||
61 | /** |
||
62 | * @return string the aws acl policy name. |
||
63 | */ |
||
64 | public function getName(): string |
||
68 | } |
||
69 |