lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Martijn van Groningen (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LUCENE-3778) Create a grouping convenience class
Date Tue, 13 Mar 2012 09:07:38 GMT

    [ https://issues.apache.org/jira/browse/LUCENE-3778?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13228283#comment-13228283
] 

Martijn van Groningen commented on LUCENE-3778:
-----------------------------------------------

bq. +1, as long as GroupSearch covers all cases package.html now describes I guess?
I think the GroupSearch class covers all local cases, so that should be fine.

{quote}
methods like disableCaching(), includeScores(boolean includeScores) are a little confusing
because the verb 'set' is missing?
In general I think getXXX and setXXX are useful, because otherwise its hard to consume the
API since you don't
know if the method will have some unintended side effects. As an extreme example, imagine
if instead of isClosed() if you 
used closed(), which is very different from close() but confusable.
{quote}
Kinda makes sense, lets make the method names more descriptives to avoid any confusion (although
we have jdocs). 

{quote}
methods like enableCaching(double maxCacheRAMMB, boolean cacheScores) and enableCaching(int
maxDocsToCache, boolean cacheScores)
are confusing because the signature is overloaded by different primitive types... can we give
those unique names?
{quote}
Sure, we can do that. What would be good names? setCacheSizeInMb(Double,boolean) and setCacheSizeInDocs(Integer,boolean)?
Setting null would disable the cache?
                
> Create a grouping convenience class
> -----------------------------------
>
>                 Key: LUCENE-3778
>                 URL: https://issues.apache.org/jira/browse/LUCENE-3778
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: modules/grouping
>            Reporter: Martijn van Groningen
>         Attachments: LUCENE-3778.patch, LUCENE-3778.patch
>
>
> Currently the grouping module has many collector classes with a lot of different options
per class. I think it would be a good idea to have a GroupUtil (Or another name?) convenience
class. I think this could be a builder, because of the many options (sort,sortWithinGroup,groupOffset,groupCount
and more) and implementations (term/dv/function) grouping has.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Mime
View raw message