ISearchQuery.php 988 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <?php
  2. /**
  3. * SPDX-FileCopyrightText: 2017 Nextcloud GmbH and Nextcloud contributors
  4. * SPDX-License-Identifier: AGPL-3.0-or-later
  5. */
  6. namespace OCP\Files\Search;
  7. use OCP\IUser;
  8. /**
  9. * @since 12.0.0
  10. */
  11. interface ISearchQuery {
  12. /**
  13. * @return ISearchOperator
  14. * @since 12.0.0
  15. */
  16. public function getSearchOperation();
  17. /**
  18. * Get the maximum number of results to return
  19. *
  20. * @return integer
  21. * @since 12.0.0
  22. */
  23. public function getLimit();
  24. /**
  25. * Get the offset for returned results
  26. *
  27. * @return integer
  28. * @since 12.0.0
  29. */
  30. public function getOffset();
  31. /**
  32. * The fields and directions to order by
  33. *
  34. * @return ISearchOrder[]
  35. * @since 12.0.0
  36. */
  37. public function getOrder();
  38. /**
  39. * The user that issued the search
  40. *
  41. * @return ?IUser
  42. * @since 12.0.0
  43. */
  44. public function getUser();
  45. /**
  46. * Whether or not the search should be limited to the users home storage
  47. *
  48. * @return bool
  49. * @since 18.0.0
  50. */
  51. public function limitToHome(): bool;
  52. }