对 S3、 v2 API 的请求。
$result = $client->getBucketLifecycleConfiguration(array(
// Bucket is required
'Bucket' => 'string',
));
我得到以下回复
Guzzle\Service\Resource\Model::__set_state(array(
'structure' => NULL,
'data' =>
array (
'Rules' =>
array (
0 =>
array (
'ID' => 'Test',
'Filter' =>
array (
'Prefix' =>
array (
),
),
'Status' => 'Enabled',
'NoncurrentVersionExpiration' =>
array (
'NoncurrentDays' => '250',
),
),
),
'RequestId' => 'E83571AFC306FFFD',
),
))
我想解析这个对象!
试图获取如下数据$result->data
得到NULL
我尝试将其类型转换为数组,但得到了以下数组索引。看来我做错了。
array (
'' . "\0" . '*' . "\0" . 'structure' => NULL,
'' . "\0" . '*' . "\0" . 'data' =>
array (
'Rules' =>
array (
0 =>
array (
'ID' => 'Test',
'Filter' =>
array (
'Prefix' =>
array (
),
),
'Status' => 'Enabled',
'NoncurrentVersionExpiration' =>
array (
'NoncurrentDays' => '250',
),
),
),
'RequestId' => 'E83571AFC306FFFD',
),
)