Details
-
Type:
Sub-task
-
Status: Closed
-
Priority:
Should
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: Platform 1.11.0
-
Component/s: Concept Dictionary
-
Labels:None
-
Complexity:Medium
-
Sprint:Soldevelo Sprint 1
Description
We need to replace query terms like concept.retired:false or voided:false with TermsFilter.
It should be possible to call:
LuceneQuery.newQuery("name: HIV", sessionFactory.getCurrentSession(), ConceptName.class).filter("concept.retired", false).filter("voided", false).list();
The filter(String, Object...) method should use TermsFilter. See the skipSame method for an example of usage. Instead of instantiating a new terms filter each time as in skipSame, use a global filter as explained in http://docs.jboss.org/hibernate/search/3.2/reference/en/html/search-query.html#query-filter which can be cached.
Use filters in HibernateConceptDAO.getConcepts for the following fields: concept.retired, concept.conceptClass.conceptClassId, concept.datatype.conceptDatatypeId, voided.