Bitwarden-app-android-iphon.../src/Core/Abstractions/ISearchService.cs

24 lines
964 B
C#
Raw Normal View History

2019-04-24 20:52:26 +02:00
using System;
using System.Collections.Generic;
2019-05-07 04:35:42 +02:00
using System.Threading;
2019-04-24 20:52:26 +02:00
using System.Threading.Tasks;
using Bit.Core.Models.View;
namespace Bit.Core.Abstractions
{
public interface ISearchService
{
void ClearIndex();
Task IndexCiphersAsync();
bool IsSearchable(string query);
Task<List<CipherView>> SearchCiphersAsync(string query, Func<CipherView, bool> filter = null,
List<CipherView> ciphers = null, CancellationToken ct = default);
2019-05-07 04:35:42 +02:00
List<CipherView> SearchCiphersBasic(List<CipherView> ciphers, string query,
CancellationToken ct = default, bool deleted = false);
Task<List<SendView>> SearchSendsAsync(string query, Func<SendView, bool> filter = null,
List<SendView> sends = null, CancellationToken ct = default);
List<SendView> SearchSendsBasic(List<SendView> sends, string query,
CancellationToken ct = default, bool deleted = false);
2019-04-24 20:52:26 +02:00
}
}