consoleui icon indicating copy to clipboard operation
consoleui copied to clipboard

Cleanup API

Open mainrs opened this issue 9 years ago • 4 comments

I would follow the Java naming convention on interfaces and classes. Some examples are the PromtResultItemIF interface. The IF at the end is really disturbing in my opinion. If you code using the API, you normally do not care if you are using an interface or a class. So there is no need to mark them with IF, Changing PromptIF to Prompt would make the API easier to read and use. This will break the API for backward compatibility and therefore should start with a new version number.

mainrs avatar May 11 '16 12:05 mainrs

Yes, I agree. The "IF" suffix is a habit due to the (very old) coding conventions of the company where I work. So I didn't really thought about this topic. There are not many interfaces at the moment, but - as you already wrote - it would break the compatibility. But I don't think we have a lot of users at the moment - therefore the best time to change it is now. Let me think about this issue. Maybe I will change this in the near future. BTW.. are you using this library or did you start documenting it?

awegmann avatar May 11 '16 19:05 awegmann

I started to document it. One question: Can I remove the User and Date from the Javadoc of all those files? Adding a license to the top of each file (for example an Apache 2 License or even an open source software license) would do the same without disturbing the Javadoc.

mainrs avatar May 11 '16 19:05 mainrs

You can add a javadoc comment for the classes and transform the original comment with my name and date to a non-javadoc comment. would this be ok?

awegmann avatar May 11 '16 19:05 awegmann

Sure

mainrs avatar May 11 '16 19:05 mainrs