title: How to parse S3 response Guzzle\Service\Resource\Model object?
body: <p>Request to S3, <strong>v2</strong> API.</p>
  
  <pre><code>$result = $client-&gt;getBucketLifecycleConfiguration(array(
      // Bucket is required
      'Bucket' =&gt; 'string',
  ));
  </code></pre>
  
  <p>I get the following response </p>
  
  <pre><code>Guzzle\Service\Resource\Model::__set_state(array(
     'structure' =&gt; NULL,
     'data' =&gt; 
    array (
      'Rules' =&gt; 
      array (
        0 =&gt; 
        array (
          'ID' =&gt; 'Test',
          'Filter' =&gt; 
          array (
            'Prefix' =&gt; 
            array (
            ),
          ),
          'Status' =&gt; 'Enabled',
          'NoncurrentVersionExpiration' =&gt; 
          array (
            'NoncurrentDays' =&gt; '250',
          ),
        ),
      ),
      'RequestId' =&gt; 'E83571AFC306FFFD',
    ),
  ))
  </code></pre>
  
  <p>I want to parse this object! </p>
  
  <p>Tried to get data like following <code>$result-&gt;data</code> got <strong>NULL</strong></p>
  
  <p>I tried to typecast it to <strong>array</strong> but got the following array index. it seems I am doing it wrong.</p>
  
  <pre><code>array (
    '' . "\0" . '*' . "\0" . 'structure' =&gt; NULL,
    '' . "\0" . '*' . "\0" . 'data' =&gt; 
    array (
      'Rules' =&gt; 
      array (
        0 =&gt; 
        array (
          'ID' =&gt; 'Test',
          'Filter' =&gt; 
          array (
            'Prefix' =&gt; 
            array (
            ),
          ),
          'Status' =&gt; 'Enabled',
          'NoncurrentVersionExpiration' =&gt; 
          array (
            'NoncurrentDays' =&gt; '250',
          ),
        ),
      ),
      'RequestId' =&gt; 'E83571AFC306FFFD',
    ),
  )
  </code></pre>