lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <>
Subject Custom "multi term" SpanQuery subclass issue
Date Wed, 14 Sep 2005 19:50:43 GMT
I'm implementing a custom SpanQuery subclass that expands into  
multiple terms (sort of like WildcardQuery).  I've subclassed  
SpanQuery and overridden the rewrite method to rewrite itself into a  
SpanOrQuery.  This works fine by itself as a standalone query.

However, when my custom SpanQuery subclass is nested within a  
SpanNearQuery it is not rewritten (as SpanQuery and all the built-in  
subclasses) defer to Query.rewrite.

What are my options in this regard?

Should the Span*Query's that aggregate other SpanQuery's  
(SpanOrQuery, SpanNearQuery) do something like BooleanQuery.rewrite 
()?  It seems like it should just to be on the safe side and allow  
rewriting SpanQuery's.



To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message