Hi all,
tomorrow I will attend a 24 hours coding hackaton here in Germany, and I will like to refactor and improve there some code I wrote. (When someone is around here and would like to come you are invited, the transport from Cologne to Karsruhe is paid...and the event is for free) anyway...here is the case:
Here are the requirements for the open source code, I would like to write:
As it is a module, which connects with social networks, it needs to get feeded from a source of that social network. In this particular case, I need the number of likes/comments/shares for every post published in the social network. The social network, with which I am working is Diaspora.
What the module does?
It retrieves the data from the source, and depending of the number of likes/comments/shares it has, every post receives a punctuation. And then, the one with the most of the points wins, showing a message in console, with the name of the winner post ,and that´s it!
Basically, this is the code I wrote till now. My idea is refactor it, totally as I think it is needed, in order to learn and have the best possible code, using TDD and integration tests (
Jenkins).
I coded this code, some days ago. Using TDD, but it got a little bit messy, so I will not post the tests here. I know this code is very improvable, and I would like to start from a proper design. Also the code here, is not the complete app.
BioPic Class I have not included the getters and setter, in order to improve the quality of the post. I have also used Spring MVC and
Maven.
List_BioPics Class
TidyUp_BioPics_By_Attribute Class
This is just a pretty basic approach, like a Mock I wrote. Now I would like to clarify a good design before refactor it.
Any idea, please?
Regards, Isaac