lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kevin A. Burton" <>
Subject Re: Why is final?
Date Tue, 13 Jul 2004 01:33:04 GMT
Doug Cutting wrote:

> Kevin A. Burton wrote:
>> I was going to create a new IDField class which just calls super( 
>> name, value, false, true, false) but noticed I was prevented because 
>> is final?
> You don't need to subclass to do this, just a static method somewhere.
>> Why is this? I can't see any harm in making it non-final...
> Field and Document are not designed to be extensible. They are 
> persisted in such a way that added methods are not available when the 
> field is restored. In other words, when a field is read, it always 
> constructs an instance of Field, not a subclass.

Thats fine... I think thats acceptable behavior. I don't think anyone 
would assume that inner vars are restored or that the field is serialized.

Not a big deal but it would be nice...


Please reply using PGP.    
    NewsMonster -
Kevin A. Burton, Location - San Francisco, CA, Cell - 415.595.9965
       AIM/YIM - sfburtonator,  Web -
GPG fingerprint: 5FB2 F3E2 760E 70A8 6174 D393 E84D 8D04 99F1 4412
  IRC - #infoanarchy | #p2p-hackers | #newsmonster

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

View raw message