StorageClass.php 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. <?php
  2. # Generated by the protocol buffer compiler. DO NOT EDIT!
  3. # source: protos/ydb_export.proto
  4. namespace Ydb\Export\ExportToS3Settings;
  5. use UnexpectedValueException;
  6. /**
  7. * Protobuf type <code>Ydb.Export.ExportToS3Settings.StorageClass</code>
  8. */
  9. class StorageClass
  10. {
  11. /**
  12. * Generated from protobuf enum <code>STORAGE_CLASS_UNSPECIFIED = 0;</code>
  13. */
  14. const STORAGE_CLASS_UNSPECIFIED = 0;
  15. /**
  16. * Generated from protobuf enum <code>STANDARD = 1;</code>
  17. */
  18. const STANDARD = 1;
  19. /**
  20. * Generated from protobuf enum <code>REDUCED_REDUNDANCY = 2;</code>
  21. */
  22. const REDUCED_REDUNDANCY = 2;
  23. /**
  24. * Generated from protobuf enum <code>STANDARD_IA = 3;</code>
  25. */
  26. const STANDARD_IA = 3;
  27. /**
  28. * Generated from protobuf enum <code>ONEZONE_IA = 4;</code>
  29. */
  30. const ONEZONE_IA = 4;
  31. /**
  32. * Generated from protobuf enum <code>INTELLIGENT_TIERING = 5;</code>
  33. */
  34. const INTELLIGENT_TIERING = 5;
  35. /**
  36. * Generated from protobuf enum <code>GLACIER = 6;</code>
  37. */
  38. const GLACIER = 6;
  39. /**
  40. * Generated from protobuf enum <code>DEEP_ARCHIVE = 7;</code>
  41. */
  42. const DEEP_ARCHIVE = 7;
  43. /**
  44. * Generated from protobuf enum <code>OUTPOSTS = 8;</code>
  45. */
  46. const OUTPOSTS = 8;
  47. private static $valueToName = [
  48. self::STORAGE_CLASS_UNSPECIFIED => 'STORAGE_CLASS_UNSPECIFIED',
  49. self::STANDARD => 'STANDARD',
  50. self::REDUCED_REDUNDANCY => 'REDUCED_REDUNDANCY',
  51. self::STANDARD_IA => 'STANDARD_IA',
  52. self::ONEZONE_IA => 'ONEZONE_IA',
  53. self::INTELLIGENT_TIERING => 'INTELLIGENT_TIERING',
  54. self::GLACIER => 'GLACIER',
  55. self::DEEP_ARCHIVE => 'DEEP_ARCHIVE',
  56. self::OUTPOSTS => 'OUTPOSTS',
  57. ];
  58. public static function name($value)
  59. {
  60. if (!isset(self::$valueToName[$value])) {
  61. throw new UnexpectedValueException(sprintf(
  62. 'Enum %s has no name defined for value %s', __CLASS__, $value));
  63. }
  64. return self::$valueToName[$value];
  65. }
  66. public static function value($name)
  67. {
  68. $const = __CLASS__ . '::' . strtoupper($name);
  69. if (!defined($const)) {
  70. throw new UnexpectedValueException(sprintf(
  71. 'Enum %s has no value defined for name %s', __CLASS__, $name));
  72. }
  73. return constant($const);
  74. }
  75. }
  76. // Adding a class alias for backwards compatibility with the previous class name.
  77. class_alias(StorageClass::class, \Ydb\Export\ExportToS3Settings_StorageClass::class);