Package org.cyclos.impl.search
Interface SearchHandler
-
- All Superinterfaces:
ApplicationInitializationListener,CustomBean
- All Known Implementing Classes:
DbSearchHandlerImpl,ElasticsearchSearchHandlerImpl,PostgresqlSearchHandlerImpl
public interface SearchHandler extends CustomBean, ApplicationInitializationListener
Handler used to perform [full-text / geo-distance] searches, as well as eventually handling indexing on entities. The entities that can be searched are: users, contacts, advertisements and records.
-
-
Field Summary
-
Fields inherited from interface org.cyclos.impl.ApplicationInitializationListener
MAX_PRIORITY, MIN_PRIORITY, NORMAL_PRIORITY
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description AdSearchHandlerad()Returns the handler for searching advertisementsContactSearchHandlercontact()Returns the handler for searching contactsInstallmentSearchHandlerinstallment()Returns the handler for searching installmentsbooleanisPhraseSearchSupported()Returns whether phrase searches are supported within full-text queriesbooleanisTranslationSupported()Returns whether translated values are supportedList<String>performIndex(String index, List<Long> ids)Updates the given index for the entity with the given identifiers.RecordSearchHandlerrecord()Returns the handler for searching recordsvoidreindex()Reindexes all data.<S extends SearchHandler>
Sself()Returns the own implementationTransactionSearchHandlertransaction()Returns the handler for searching transactionsTransferSearchHandlertransfer()Returns the handler for searching transfersUserSearchHandleruser()Returns the handler for searching users-
Methods inherited from interface org.cyclos.impl.ApplicationInitializationListener
applicationInitializationPriority, getInitializationId, onApplicationInitialization
-
-
-
-
Method Detail
-
ad
AdSearchHandler ad()
Returns the handler for searching advertisements
-
contact
ContactSearchHandler contact()
Returns the handler for searching contacts
-
installment
InstallmentSearchHandler installment()
Returns the handler for searching installments
-
isPhraseSearchSupported
boolean isPhraseSearchSupported()
Returns whether phrase searches are supported within full-text queries
-
isTranslationSupported
boolean isTranslationSupported()
Returns whether translated values are supported
-
performIndex
List<String> performIndex(String index, List<Long> ids)
Updates the given index for the entity with the given identifiers.- Returns:
- Either null, indicating a no-op, or a list with the same size as the input ids, containing the error message for each id, or null if it succeeded.
-
record
RecordSearchHandler record()
Returns the handler for searching records
-
reindex
void reindex()
Reindexes all data. This is only called by scripts, in case the admin needs to reindex the data
-
self
<S extends SearchHandler> S self()
Returns the own implementation
-
transaction
TransactionSearchHandler transaction()
Returns the handler for searching transactions
-
transfer
TransferSearchHandler transfer()
Returns the handler for searching transfers
-
user
UserSearchHandler user()
Returns the handler for searching users
-
-