2017-02-02 12:19:16 -05:00
|
|
|
<?php
|
2025-06-30 09:04:05 -04:00
|
|
|
|
2017-02-02 12:19:16 -05:00
|
|
|
/**
|
2024-05-23 03:26:56 -04:00
|
|
|
* SPDX-FileCopyrightText: 2017 Nextcloud GmbH and Nextcloud contributors
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
2017-02-02 12:19:16 -05:00
|
|
|
*/
|
|
|
|
|
namespace OCP\Files\Search;
|
|
|
|
|
|
2017-03-08 09:17:39 -05:00
|
|
|
use OCP\IUser;
|
|
|
|
|
|
2017-02-02 12:19:16 -05:00
|
|
|
/**
|
|
|
|
|
* @since 12.0.0
|
|
|
|
|
*/
|
|
|
|
|
interface ISearchQuery {
|
|
|
|
|
/**
|
|
|
|
|
* @return ISearchOperator
|
|
|
|
|
* @since 12.0.0
|
|
|
|
|
*/
|
|
|
|
|
public function getSearchOperation();
|
2017-02-02 12:20:08 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Get the maximum number of results to return
|
|
|
|
|
*
|
|
|
|
|
* @return integer
|
|
|
|
|
* @since 12.0.0
|
|
|
|
|
*/
|
|
|
|
|
public function getLimit();
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Get the offset for returned results
|
|
|
|
|
*
|
|
|
|
|
* @return integer
|
|
|
|
|
* @since 12.0.0
|
|
|
|
|
*/
|
|
|
|
|
public function getOffset();
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* The fields and directions to order by
|
|
|
|
|
*
|
|
|
|
|
* @return ISearchOrder[]
|
|
|
|
|
* @since 12.0.0
|
|
|
|
|
*/
|
|
|
|
|
public function getOrder();
|
2017-03-08 09:17:39 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* The user that issued the search
|
|
|
|
|
*
|
2021-03-18 12:16:28 -04:00
|
|
|
* @return ?IUser
|
2017-03-08 09:17:39 -05:00
|
|
|
* @since 12.0.0
|
|
|
|
|
*/
|
|
|
|
|
public function getUser();
|
2019-11-08 09:05:21 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Whether or not the search should be limited to the users home storage
|
|
|
|
|
*
|
|
|
|
|
* @return bool
|
2019-12-03 09:21:35 -05:00
|
|
|
* @since 18.0.0
|
2019-11-08 09:05:21 -05:00
|
|
|
*/
|
|
|
|
|
public function limitToHome(): bool;
|
2017-02-02 12:19:16 -05:00
|
|
|
}
|