[ http://issues.apache.org/jira/browse/LUCENE-609?page=comments#action_12417188 ]
Chuck Williams commented on LUCENE-609: --------------------------------------- I'm late to the discussion and have only read the patch file, but it seems invalid to me. Won't getField() get a class cast exception when it encounters a Fieldable that is not a Field? The semantics of getField() would have to be something like, "only get this field if it is a Field rather than some other kind of Fieldable", which means it would have to do type testing on the members of fields. I think it is much better to remove this patch and leave Fieldable as is. Searchable was the same kind of thing. IndexReader is an abstract super class for the different types of readers. When I did ParallelWriter, I had the same problem and had to introduce Writable since IndexWriter is not an abstract class and ParallelWriter is a different implementation. I think it is best to introduce all the abstract classes now for fundamental types that have multiple implementations. Chuck > Lazy field loading breaks backward compat > ----------------------------------------- > > Key: LUCENE-609 > URL: http://issues.apache.org/jira/browse/LUCENE-609 > Project: Lucene - Java > Type: Bug > Components: Other > Versions: 2.0.1 > Reporter: Yonik Seeley > Assignee: Yonik Seeley > Fix For: 2.0.1 > Attachments: fieldable_patch.diff > > Document.getField() and Document.getFields() have changed in a non backward > compatible manner. > Simple code like the following no longer compiles: > Field x = mydoc.getField("x"); -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]