BlackSwanLtd/AndroidFever — pull request #1 by anikiki (2014-09-12 10:25:43+00:00)
Title: Technical Task

Hello,

I committed the code for the technical task. From the provided ideas I chose to display a list of questions retrieved from stackoverflow. I used the stackexchange API v2.1 in order to achieve this. As the API offered paginated results, I chose to retrieve 40 results at a time.

The results are displayed in a list where each element contains the question in bold, the author of the question, the reputation of the author, if the question was answered or not and the score. Scrolling to the bottom of the list will initiate a new request for the next batch of questions. As the task allowed me to use 3rd party libraries I added one for having a nicer list when scrolling.

Every time the questions are loaded a toast message is displayed to inform the user. The message is "40 questions loaded", where the number "40" comes from a constant in the code and the rest of the message from the strings resource file in order to be easily internationalized. When an error occurs and the questions are not loaded the user can see again a toast message, this time containing the message "Error loading questions. You might have reached the maximum number of requests for today.". This comes also from the strings resource file. In case the maximum quota of requests from the same IP to stackexchange server is reached nothing can be done, as I read on the site you have to wait around 12 hours to get access again.

Looking forward to get a feedback,
Ana