MicrosoftAzureStorageBlobModelsCopyBlobResult

The result of calling copyBlob API.

Defined (1)

The class is defined in the following location(s).

/lib/Azure/MicrosoftAzureStorage/Blob/Models/CopyBlobResult.php  
  1. class CopyBlobResult 
  2. /** 
  3. * @var string 
  4. */ 
  5. private $_etag; 
  6.  
  7. /** 
  8. * @var \DateTime 
  9. */ 
  10. private $_lastModified; 
  11.  
  12. /** 
  13. * Creates CopyBlobResult object from the response of the copy blob request. 
  14. * @param array $headers The HTTP response headers in array representation. 
  15. * @return CopyBlobResult 
  16. */ 
  17. public static function create($headers) 
  18. $result = new CopyBlobResult(); 
  19. $result->setETag( 
  20. Utilities::tryGetValueInsensitive( 
  21. Resources::ETAG,  
  22. $headers 
  23. ); 
  24. if (Utilities::arrayKeyExistsInsensitive(Resources::LAST_MODIFIED, $headers)) { 
  25. $lastModified = Utilities::tryGetValueInsensitive( 
  26. Resources::LAST_MODIFIED,  
  27. $headers 
  28. ); 
  29. $result->setLastModified(Utilities::rfc1123ToDateTime($lastModified)); 
  30.  
  31. return $result; 
  32.  
  33. /** 
  34. * Gets ETag. 
  35. * @return string 
  36. */ 
  37. public function getETag() 
  38. return $this->_etag; 
  39.  
  40. /** 
  41. * Sets ETag. 
  42. * @param string $etag value. 
  43. * @return none 
  44. */ 
  45. public function setETag($etag) 
  46. $this->_etag = $etag; 
  47.  
  48. /** 
  49. * Gets blob lastModified. 
  50. * @return \DateTime 
  51. */ 
  52. public function getLastModified() 
  53. return $this->_lastModified; 
  54.  
  55. /** 
  56. * Sets blob lastModified. 
  57. * @param \DateTime $lastModified value. 
  58. * @return none 
  59. */ 
  60. public function setLastModified($lastModified) 
  61. $this->_lastModified = $lastModified;