Const.h 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. /*
  2. * Copyright 2009-2017 Alibaba Cloud All rights reserved.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. #pragma once
  17. #include <cstdint>
  18. namespace AlibabaCloud
  19. {
  20. namespace OSS
  21. {
  22. const int64_t MaxFileSize = 5LL * 1024LL * 1024LL * 1024LL;
  23. const int32_t MaxPrefixStringSize = 1024;
  24. const int32_t MaxMarkerStringSize = 1024;
  25. const int32_t MaxDelimiterStringSize = 1024;
  26. const int32_t MaxReturnedKeys = 1000;
  27. const int32_t MaxUploads = 1000;
  28. const int32_t DeleteObjectsUpperLimit = 1000;
  29. const int32_t BucketCorsRuleLimit = 10;
  30. const int32_t LifecycleRuleLimit = 1000;
  31. const int32_t ObjectNameLengthLimit = 1023;
  32. const int32_t PartNumberUpperLimit = 10000;
  33. const int32_t DefaultPartSize = 8 * 1024 * 1024;
  34. const int32_t PartSizeLowerLimit = 100 * 1024;
  35. const int32_t MaxPathLength = 124;
  36. const int32_t MinPathLength = 4;
  37. const int32_t DefaultResumableThreadNum = 3;
  38. const uint32_t MaxLiveChannelNameLength = 1023;
  39. const uint32_t MaxLiveChannelDescriptionLength = 128;
  40. const uint32_t MinLiveChannelFragCount = 1;
  41. const uint32_t MaxLiveChannelFragCount = 100;
  42. const uint32_t MinLiveChannelFragDuration = 1;
  43. const uint32_t MaxLiveChannelFragDuration = 100;
  44. const uint32_t MinLiveChannelPlayListLength = 6;
  45. const uint32_t MaxLiveChannelPlayListLength = 128;
  46. const uint32_t MinLiveChannelInterval = 1;
  47. const uint32_t MaxLiveChannelInterval = 100;
  48. const uint64_t SecondsOfDay = 24*60*60;
  49. const uint32_t MaxListLiveChannelKeys = 1000;
  50. const uint32_t TagKeyLengthLimit = 128;
  51. const uint32_t TagValueLengthLimit = 256;
  52. const uint32_t MaxTagSize = 10;
  53. #ifdef _WIN32
  54. const char PATH_DELIMITER = '\\';
  55. const wchar_t WPATH_DELIMITER = L'\\';
  56. #else
  57. const char PATH_DELIMITER = '/';
  58. const wchar_t WPATH_DELIMITER = L'/';
  59. #endif
  60. }
  61. }