ObjectVersionInfo.php 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. <?php
  2. namespace OSS\Model;
  3. /**
  4. *
  5. * Class ObjectVersionInfo
  6. *
  7. * The element type of ObjectVersionListInfo, which is the return value type of listObjectVersions
  8. *
  9. * The return value of listObjectVersions includes three arrays
  10. * One is the returned ObjectVersionListInfo, which is similar to a file list in a file system.
  11. * The other is the returned prefix list, which is similar to a folder list in a file system.
  12. *
  13. * @package OSS\Model
  14. */
  15. class ObjectVersionInfo
  16. {
  17. /**
  18. * ObjectVersionInfo constructor.
  19. *
  20. * @param string $key
  21. * @param string $lastModified
  22. * @param string $eTag
  23. * @param string $type
  24. * @param int $size
  25. * @param string $storageClass
  26. * @param string $isLatest
  27. */
  28. public function __construct($key, $versionId, $lastModified, $eTag, $type, $size, $storageClass, $isLatest)
  29. {
  30. $this->key = $key;
  31. $this->versionId = $versionId;
  32. $this->lastModified = $lastModified;
  33. $this->eTag = $eTag;
  34. $this->type = $type;
  35. $this->size = $size;
  36. $this->storageClass = $storageClass;
  37. $this->isLatest = $isLatest;
  38. }
  39. /**
  40. * @return string
  41. */
  42. public function getKey()
  43. {
  44. return $this->key;
  45. }
  46. /**
  47. * @return string
  48. */
  49. public function getVersionId()
  50. {
  51. return $this->versionId;
  52. }
  53. /**
  54. * @return string
  55. */
  56. public function getLastModified()
  57. {
  58. return $this->lastModified;
  59. }
  60. /**
  61. * @return string
  62. */
  63. public function getETag()
  64. {
  65. return $this->eTag;
  66. }
  67. /**
  68. * @return string
  69. */
  70. public function getType()
  71. {
  72. return $this->type;
  73. }
  74. /**
  75. * @return int
  76. */
  77. public function getSize()
  78. {
  79. return $this->size;
  80. }
  81. /**
  82. * @return string
  83. */
  84. public function getStorageClass()
  85. {
  86. return $this->storageClass;
  87. }
  88. /**
  89. * @return string
  90. */
  91. public function getIsLatest()
  92. {
  93. return $this->isLatest;
  94. }
  95. private $key = "";
  96. private $versionId = "";
  97. private $lastModified = "";
  98. private $eTag = "";
  99. private $type = "";
  100. private $size = 0;
  101. private $storageClass = "";
  102. private $isLatest = "";
  103. }