2015-02-27 04:09:23 -06:00
|
|
|
<?php
|
2016-05-20 05:41:23 -05:00
|
|
|
/**
|
|
|
|
* SearchInterface.php
|
|
|
|
* Copyright (C) 2016 thegrumpydictator@gmail.com
|
|
|
|
*
|
2016-10-04 23:52:15 -05:00
|
|
|
* This software may be modified and distributed under the terms of the
|
|
|
|
* Creative Commons Attribution-ShareAlike 4.0 International License.
|
|
|
|
*
|
|
|
|
* See the LICENSE file for details.
|
2016-05-20 05:41:23 -05:00
|
|
|
*/
|
|
|
|
|
2017-04-09 00:44:22 -05:00
|
|
|
declare(strict_types=1);
|
2015-02-27 04:09:23 -06:00
|
|
|
|
|
|
|
namespace FireflyIII\Support\Search;
|
|
|
|
|
2017-02-05 09:16:15 -06:00
|
|
|
use FireflyIII\User;
|
2015-02-27 04:09:23 -06:00
|
|
|
use Illuminate\Support\Collection;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Interface SearchInterface
|
|
|
|
*
|
|
|
|
* @package FireflyIII\Support\Search
|
|
|
|
*/
|
2015-03-29 14:27:51 -05:00
|
|
|
interface SearchInterface
|
|
|
|
{
|
2015-02-27 04:09:23 -06:00
|
|
|
/**
|
2017-02-18 13:10:03 -06:00
|
|
|
* @return string
|
|
|
|
*/
|
|
|
|
public function getWordsAsString(): string;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @return bool
|
|
|
|
*/
|
|
|
|
public function hasModifiers(): bool;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @param string $query
|
|
|
|
*/
|
|
|
|
public function parseQuery(string $query);
|
|
|
|
|
2015-02-27 04:09:23 -06:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @return Collection
|
|
|
|
*/
|
2017-02-18 13:10:03 -06:00
|
|
|
public function searchTransactions(): Collection;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @param int $limit
|
|
|
|
*/
|
|
|
|
public function setLimit(int $limit);
|
2017-02-16 23:42:36 -06:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @param User $user
|
|
|
|
*/
|
|
|
|
public function setUser(User $user);
|
2015-03-29 01:14:32 -05:00
|
|
|
}
|