uima-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thilo Goetz <twgo...@gmx.de>
Subject Re: generics cleanup - avoiding modifying public APIs?
Date Fri, 24 Jul 2009 06:41:02 GMT
Jörn Kottmann wrote:
> Marshall Schor wrote:
>> When adding generic type info to UIMA core, if there is a method which
>> is declared to return a List, and we change it to return a
>> List<ofSomeType>, and the method is part of the UIMA public API - does
>> that "break" the public API?  Or will code that is already written to
>> use it continue to work?  I think the code would continue to work in
>> terms of the runtime (because of the "erasure" approach), but the
>> compiling may generate some new warnings for our users?
>>   
> If a user wrote List<SomeOtherType> sample = ....  then its likely
> that he will get a compile error when our code return List<ofSomeType>
> (but not a runtime error I think).
> Same is true for things which are passed to UIMA API methods, if a user
> already
> declared generic types its possible that it will break the code.
> 
>> Is this OK or should we refrain from any changes which are the public
>> UIMA api's?
>>   
> I think it is ok, because its unlikely that we break something.

Yes, let's keep going.  It's a bit late to have second thoughts
about this, as Joern has already made quite a few changes to
public APIs.

> 
> In the whole UIMA repo was only one case which broke existing code
> and that was the additionalParams map which was in one case passed
> as a Properties object which is Map<Object, Object> and not Map<String,
> Object>.
> Though for that reason it was not changed and is still a raw Map.
> 
> Jörn


Mime
View raw message