Explain what considerations do you need when writing a UITableViewController which shows images downloaded from a remote server?
Submitted by: MuhammadThis is a very common task in iOS and a good answer here can cover a whole host of knowledge. The important piece of information in the question is that the images are hosted remotely and they may take time to download, therefore when it asks for “considerations”, you should be talking about:
☛ Only download the image when the cell is scrolled into view, i.e. when cellForRowAtIndexPath is called.
☛ Downloading the image asynchronously on a background thread so as not to block the UI so the user can keep scrolling.
☛ When the image has downloaded for a cell we need to check if that cell is still in the view or whether it has been re-used by another piece of data. If it's been re-used then we should discard the image, otherwise we need to switch back to the main thread to change the image on the cell.
Other good answers will go on to talk about offline caching of the images, using placeholder images while the images are being downloaded.
Submitted by: Muhammad
☛ Only download the image when the cell is scrolled into view, i.e. when cellForRowAtIndexPath is called.
☛ Downloading the image asynchronously on a background thread so as not to block the UI so the user can keep scrolling.
☛ When the image has downloaded for a cell we need to check if that cell is still in the view or whether it has been re-used by another piece of data. If it's been re-used then we should discard the image, otherwise we need to switch back to the main thread to change the image on the cell.
Other good answers will go on to talk about offline caching of the images, using placeholder images while the images are being downloaded.
Submitted by: Muhammad
Read Online UX Designer Job Interview Questions And Answers
Top UX Designer Questions
☺ | Tell Us What Do You Do When There’s Not Enough Time To Do Research? |
☺ | Tell us what are cards in mobile design? Why are they good and when is the best time to use them? |
☺ | Tell me what is the best search pattern for mobile phones? |
☺ | Explain me how can designers leverage audio to enhance user experience? |
☺ | Tell us what is onboarding and why is it so important for mobile design? |
Top Designing Categories
☺ | Web Designing Interview Questions. |
☺ | 3D Maya Interview Questions. |
☺ | Textile Dyeing Specialist Interview Questions. |
☺ | Fashion Designer Interview Questions. |
☺ | Physical Product Designer Interview Questions. |