Constants.php 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * @copyright Copyright (c) 2016, ownCloud, Inc.
  5. *
  6. * @author Arthur Schiwon <blizzz@arthur-schiwon.de>
  7. * @author Christoph Wurst <christoph@winzerhof-wurst.at>
  8. * @author Joas Schilling <coding@schilljs.com>
  9. * @author Morris Jobke <hey@morrisjobke.de>
  10. * @author Roeland Jago Douma <roeland@famdouma.nl>
  11. * @author Thomas Tanghus <thomas@tanghus.net>
  12. *
  13. * @license AGPL-3.0
  14. *
  15. * This code is free software: you can redistribute it and/or modify
  16. * it under the terms of the GNU Affero General Public License, version 3,
  17. * as published by the Free Software Foundation.
  18. *
  19. * This program is distributed in the hope that it will be useful,
  20. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  21. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  22. * GNU Affero General Public License for more details.
  23. *
  24. * You should have received a copy of the GNU Affero General Public License, version 3,
  25. * along with this program. If not, see <http://www.gnu.org/licenses/>
  26. *
  27. */
  28. // This file defines common constants used in ownCloud
  29. namespace OCP;
  30. /**
  31. * Class Constants
  32. *
  33. * @since 8.0.0
  34. */
  35. class Constants {
  36. /**
  37. * CRUDS permissions.
  38. * @since 8.0.0
  39. */
  40. public const PERMISSION_CREATE = 4;
  41. public const PERMISSION_READ = 1;
  42. public const PERMISSION_UPDATE = 2;
  43. public const PERMISSION_DELETE = 8;
  44. public const PERMISSION_SHARE = 16;
  45. public const PERMISSION_ALL = 31;
  46. /**
  47. * @since 8.0.0 - Updated in 9.0.0 to allow all POSIX chars since we no
  48. * longer support windows as server platform.
  49. */
  50. public const FILENAME_INVALID_CHARS = "\\/";
  51. /**
  52. * @since 21.0.0 – default value for autocomplete/search results limit,
  53. * cf. sharing.maxAutocompleteResults in config.sample.php.
  54. */
  55. public const SHARING_MAX_AUTOCOMPLETE_RESULTS_DEFAULT = 25;
  56. }