uima-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörn Kottmann <kottm...@gmail.com>
Subject Re: generics cleanup - avoiding modifying public APIs?
Date Fri, 24 Jul 2009 14:53:02 GMT
Marshall Schor wrote:
> 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.
>> 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>.
> Does this mean you've already changed everything except for that?  When
> I started doing things in the uimaj-core I saw a lot that needed
> changing and started changing it. (and I was up to date, too).
First I went through the interfaces and changed these,
because thats the place where it must be right. To make
sure the changes are ok I attached a patch to the jira issue
and ask for review on the mailing list and got a +1 from Thilo,
no one else commented. I assumed that it was accepted because
no one complained.

To further test if the changes are really ok I changed the test classes
and later the cas.impl package. That lead to a number of corrections
in the interfaces. Yeah there are still around 2000 warnings in the 

Should we start a new review of the interface changes ?


View raw message