Highlighting is missing.
sojoner opened this issue · 2 comments
sojoner commented
Is it possible that the the Highlighting functionality is missing ? Here is something we had in mind.
class Highlighting(BaseQuery):
"""
The most simple Solr query: hl
.
"""
def __init__(self, fields, fragsize=100, pre='<em>', post='</em>'):
"""
Initialize the query value.
"""
self.__fields = fields
self.__pre = pre
self.__post = post
self.__fragsize = fragsize
def get_params(self):
"""
Return the list of query params.
"""
result_list = list()
result_list.append(('hl', 'true'))
result_list.append(('hl.fl', ",".join(self.__fields)))
result_list.append(('hl.simple.pre', self.__pre))
result_list.append(('hl.simple.post', self.__post))
result_list.append(('hl.fragsize', self.__fragsize))
return result_list
truemped commented
Could you make a pull request out of it? I mean, the code is already there...
truemped commented
Could you?