Constants.php 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. <?php
  2. /**
  3. * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
  4. * SPDX-FileCopyrightText: 2016 ownCloud, Inc.
  5. * SPDX-License-Identifier: AGPL-3.0-only
  6. */
  7. namespace OC\Share;
  8. use OCP\Share\IShare;
  9. class Constants {
  10. /**
  11. * @deprecated 17.0.0 - use IShare::TYPE_USER instead
  12. */
  13. public const SHARE_TYPE_USER = 0;
  14. /**
  15. * @deprecated 17.0.0 - use IShare::TYPE_GROUP instead
  16. */
  17. public const SHARE_TYPE_GROUP = 1;
  18. // const SHARE_TYPE_USERGROUP = 2; // Internal type used by DefaultShareProvider
  19. /**
  20. * @deprecated 17.0.0 - use IShare::TYPE_LINK instead
  21. */
  22. public const SHARE_TYPE_LINK = 3;
  23. /**
  24. * @deprecated 17.0.0 - use IShare::TYPE_EMAIL instead
  25. */
  26. public const SHARE_TYPE_EMAIL = 4;
  27. public const SHARE_TYPE_CONTACT = 5; // ToDo Check if it is still in use otherwise remove it
  28. /**
  29. * @deprecated 17.0.0 - use IShare::TYPE_REMOTE instead
  30. */
  31. public const SHARE_TYPE_REMOTE = 6;
  32. /**
  33. * @deprecated 17.0.0 - use IShare::TYPE_CIRCLE instead
  34. */
  35. public const SHARE_TYPE_CIRCLE = 7;
  36. /**
  37. * @deprecated 17.0.0 - use IShare::TYPE_GUEST instead
  38. */
  39. public const SHARE_TYPE_GUEST = 8;
  40. /**
  41. * @deprecated 17.0.0 - use IShare::REMOTE_GROUP instead
  42. */
  43. public const SHARE_TYPE_REMOTE_GROUP = 9;
  44. /**
  45. * @deprecated 17.0.0 - use IShare::TYPE_ROOM instead
  46. */
  47. public const SHARE_TYPE_ROOM = 10;
  48. // const SHARE_TYPE_USERROOM = 11; // Internal type used by RoomShareProvider
  49. /**
  50. * @deprecated 21.0.0 - use IShare::TYPE_DECK instead
  51. */
  52. public const SHARE_TYPE_DECK = 12;
  53. // const SHARE_TYPE_DECK_USER = 13; // Internal type used by DeckShareProvider
  54. // Note to developers: Do not add new share types here
  55. public const FORMAT_NONE = -1;
  56. public const FORMAT_STATUSES = -2;
  57. public const FORMAT_SOURCES = -3; // ToDo Check if it is still in use otherwise remove it
  58. public const RESPONSE_FORMAT = 'json'; // default response format for ocs calls
  59. public const TOKEN_LENGTH = 15; // old (oc7) length is 32, keep token length in db at least that for compatibility
  60. protected static $shareTypeUserAndGroups = -1;
  61. protected static $shareTypeGroupUserUnique = 2;
  62. protected static $backends = [];
  63. protected static $backendTypes = [];
  64. protected static $isResharingAllowed;
  65. }