lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yonik Seeley" <>
Subject Re: Fieldable breaks backward compatibility
Date Wed, 21 Jun 2006 18:42:27 GMT
Looking at the changes a little more, it looks like the following
Document methods should be reverted:

   public final Fieldable[] getFields(String name)
  public final Fieldable getField(String name)

That should preserve compatibility with older applications.
The only danger is that a cast to Field might fail if it's another
type of Fieldable.  That should only be possible if you are using the
new FieldSelector method to cause some other kind of Fieldable to be
instantiated though.

I'll open a bug for this.


On 6/21/06, Yonik Seeley <> wrote:
> LUCENE-545 that was recently committed breaks backward compatibility with
> Document.getField(),  a non-expert level API that is *very* widely used.
> Something simple like
>   Field x = mydoc.getField("x");
> no longer compiles (and neither do other methods with Field in the signature).
> Is this intentional?
> If not, uses of "Field" in unit tests should not have been changed to Fieldable.
> -Yonik
> Solr, the open-source Lucene search server

-Yonik Solr, the open-source Lucene search server

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

View raw message