tango-controls / JTango

TANGO kernel Java implementation. JTango moved to https://gitlab.com/tango-controls/JTango
http://tango-controls.org
8 stars 14 forks source link

[refactoring] Add types to Vectors in dao and consider migrating to List #94

Closed altavir closed 3 years ago

altavir commented 4 years ago

Many classes in JTango core utilize Java 1.2 Vector class without generic type. In order to provide better type safety and refactoring possibilities, we need to add explicit types wherever possible. Also, Vector itself is obsolete and should be replaced by List in all cases, where thread safety is not an issue (and it does not seem to be the case in JTango core). ArrayList is better optimized for performance.

KrystianKedron commented 3 years ago

Dear Team, I do my best to refactor the JTango code and get rid of using the Vector. Also, I try to provide unit tests for the code that I change. The common package was fully refactored in the context of the removal of Vector. In dao (TangoORB) package I refactor only the fr.esrf.TangoApi package, because in fr.esrf.TangoDs all classes that used the Vector collection are deprecated and not use in the different JTango packages (correct me if I'm wrong). After merging the #119 I think we can close this issue.

gwen-soleil commented 3 years ago

Yes!