1
0

Constants.php 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-FileCopyrightText: 2016 ownCloud, Inc.
  6. * SPDX-License-Identifier: AGPL-3.0-only
  7. */
  8. // This file defines common constants used in Nextcloud
  9. namespace OCP;
  10. /**
  11. * Class Constants
  12. *
  13. * @since 8.0.0
  14. */
  15. class Constants {
  16. /**
  17. * CRUDS permissions.
  18. * @since 8.0.0
  19. */
  20. public const PERMISSION_CREATE = 4;
  21. /**
  22. * @since 8.0.0
  23. */
  24. public const PERMISSION_READ = 1;
  25. /**
  26. * @since 8.0.0
  27. */
  28. public const PERMISSION_UPDATE = 2;
  29. /**
  30. * @since 8.0.0
  31. */
  32. public const PERMISSION_DELETE = 8;
  33. /**
  34. * @since 8.0.0
  35. */
  36. public const PERMISSION_SHARE = 16;
  37. /**
  38. * @since 8.0.0
  39. */
  40. public const PERMISSION_ALL = 31;
  41. /**
  42. * @since 8.0.0 - Updated in 9.0.0 to allow all POSIX chars since we no
  43. * longer support windows as server platform.
  44. */
  45. public const FILENAME_INVALID_CHARS = "\\/";
  46. /**
  47. * @since 21.0.0 – default value for autocomplete/search results limit,
  48. * cf. sharing.maxAutocompleteResults in config.sample.php.
  49. */
  50. public const SHARING_MAX_AUTOCOMPLETE_RESULTS_DEFAULT = 25;
  51. }