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

Michael McCandless commented on LUCENE-1616:
--------------------------------------------

bq. And force everyone who has slightly different use-case to jump through the 
hoops.

"Simple things should be simple and complex things should be possible" is a 
strong guide when I'm thinking about APIs, configuration, etc.

My feeling here is for the vast majority of the cases, people set start & end 
offset together, so we should shift to the API that makes that easy.  This is 
the "simple" case.

For the remaining minority (your interesting use case), you can still do what 
you need but yes there are some hoops to go through.  This is the "complex" 
case.

bq. Span*Query api is a perfect example.

Can you describe the limitations here in more detail?

> add one setter for start and end offset to OffsetAttribute
> ----------------------------------------------------------
>
>                 Key: LUCENE-1616
>                 URL: https://issues.apache.org/jira/browse/LUCENE-1616
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: Analysis
>            Reporter: Eks Dev
>            Priority: Trivial
>             Fix For: 2.9
>
>         Attachments: LUCENE-1616.patch
>
>
> add OffsetAttribute. setOffset(startOffset, endOffset);
> trivial change, no JUnit needed
> Changed CharTokenizer to use it

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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

Reply via email to