fiji / SNT

Legacy project superseded by https://github.com/morphonets/SNT
GNU General Public License v3.0
11 stars 29 forks source link

Make key fields public. #23

Closed tferr closed 7 years ago

tferr commented 7 years ago

This fixes a bug reported by Volko Straub (see tferr/hIPNAT#5 and tferr/hIPNAT@c45704a)

imagejan commented 7 years ago

Why not adding setters and getters instead of making these fields public?

tferr commented 7 years ago

I think setters would only be useful if there were public methods to parse .traces files in a modular way. Right now there aren't: all the .traces parsing is done in a monolithic block. Getters would make sense, thought. Do you want me to replace it with getters()?

(Now I see this merge-without-waiting-long-enough-for-feedback was a bit despotic. I just thought nobody would care :) )

imagejan commented 7 years ago

Adding getters and setters would simply be more in line with the ImageJ coding style.

Having private fields and get/set methods allows to change the implementation later on, without having to change the API in a backwards-incompatible way.

But don't worry, I just stumbled upon this and was tempted to ask, while having not much insight into the details of the source code...