Data.Cloud.AmazonAPI.TAmazonStorageService.GetBucketPolicy
Delphi
function GetBucketPolicy(const BucketName: string;
ResponseInfo: TCloudResponseInfo = nil;
const BucketRegion: TAmazonRegion = amzrNotSpecified): TJSONObject;
C++
System::Json::TJSONObject* __fastcall GetBucketPolicy(const System::UnicodeString BucketName, Data::Cloud::Cloudapi::TCloudResponseInfo* ResponseInfo = (Data::Cloud::Cloudapi::TCloudResponseInfo*)(0x0), const TAmazonRegion BucketRegion = System::UnicodeString());
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
function | public | Data.Cloud.AmazonAPI.pas Data.Cloud.AmazonAPI.hpp |
Data.Cloud.AmazonAPI | TAmazonStorageService |
Description
Returns the given bucket's policies.
GetBucketPolicy returns the bucket's policies, in JSON string representation, as a System.JSON.TJSONObject object.
GetBucketPolicy returns a string that, if the request is successful, is a JSON representation of the policies. See the Amazon S3 documentation for more information on the format.
If no policy exists for the given bucket, then the response is in XML format: an error message explaining that the bucket policy does not exist. The response code is 404.
The following table shows the significance of the parameters:
Parameter | Description |
---|---|
|
The name of the bucket to get the policies for. |
|
The optional class for storing response info into. |