[ https://issues.apache.org/jira/browse/LUCENE-743?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12521243 ]
Hoss Man commented on LUCENE-743: --------------------------------- > I'm not sure if the code would become cleaner if we did that. Sometimes a > SegmentReader would then have to > return a MultiSegmentReader instance and vice versa. So we'd probably have to > duplicate some of the code in > these two classes. i don't hink there would be anything wrong with SegmentReader.reopen returning a MultiSegmentReader in some cases (or vice versa) but it definitely seems wrong to me for a parent class to be explicitly casing "this" to one of two know subclasses ... making reopen abstract in the base class (or throw UnsupportOp if for API back compatibility) seems like the only safe way to ensure any future IndexReader subclasses work properly. > IndexReader.reopen() > -------------------- > > Key: LUCENE-743 > URL: https://issues.apache.org/jira/browse/LUCENE-743 > Project: Lucene - Java > Issue Type: Improvement > Components: Index > Reporter: Otis Gospodnetic > Assignee: Michael Busch > Priority: Minor > Fix For: 2.3 > > Attachments: IndexReaderUtils.java, lucene-743.patch, > lucene-743.patch, lucene-743.patch, MyMultiReader.java, MySegmentReader.java > > > This is Robert Engels' implementation of IndexReader.reopen() functionality, > as a set of 3 new classes (this was easier for him to implement, but should > probably be folded into the core, if this looks good). -- 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]