Popular Movies Stage One Udacity Android Nanodegree Project One Experience

After wasting almost two years reading various books and courses I started feeling lack of discipline and plan in my work. When I sat down to write app from scratch I had no idea how to begin what to implement first. How to plan and execute the plan. It’s quite easy to make apps with only single screen doing a minor task. It gets to another level when you have multiple screens interacting with each other. Sending data from server to one screen to another.

That’s where I began to do Udacity’s Android Nanodegree course. It’s exactly what I needed. Android Nanodegree revolves around writing code. There’s seven projects that one must do in order to graduate from the program. These projects come with course material to help one get familiar with material, there’s implementation guide giving you nitty gritty details about project where you might get struck, there’s rubric to keep students focused, there’s webcasts to talk about specific things and then there’s discussion forums to get involved with other students and ask questions from coaches. Overall it’s a great learning environment.

I really wish India’s open universities would adopt similar structure or better collaborate with one of these MOOCs to improve India’s education by many folds.

I begin coding for project one early on. Initially I didn’t feel it very time consuming or hard. I was quickly able to implement RecyclerView. RecyclerView unlike ListView is a decentralized component. So it done one thing for you to show a list. You have to handle click events, animation, etc. yourself. There’s classes to help you with that. I enjoyed learning about Adapter. I am still getting my head around the ViewHolder Pattern.

Next interesting part was JSON parsing. I have been hearing all these text format names for a long time. JSON, YAML, XML, etc. As scary as they sound it was really fun parsing JSON. I felt like how Neo felt in Matrix when I suddenly knew Kung Fu. I felt like I know JSON. It’s really just walking through  objects and array.

Networking boilerplate was the worst of all. I think I should get used to boilerplate. ContentProvider is coming in next project. I was able to hack through most of the project simply by reading blog posts. Nop not networking boilerplate. I had to go back and work through Sunshine app. In the end networking boilerplate is a bunch of classes that I need to keep bookmarked somewhere and use it over and over. I understood when I read about it but I keep forgetting about it.

At this point I had the main activity of Popular movies ready which looked like the image below.

Popular Movies Titles Screen

During all this living close to family means you will be traveling a lot. I did. I registered for the Nanodegree on 1st of February. It is March 19th. Almost a month and a half. That’s too long for a project like this. But what can you do. Better late than never.

After I had implemented the main screen I had to implement Parcelable to send Movie object to the detailed screen. I found a nice plugin to do that for me. Along with Setters and Getters it also generated Parcelable code for me. Nice. Then there wasn’t really a lot to do except to hookup onClick code to trigger start of details screen.

Orientation changes killing activity is a interesting problem. I am using two activities and two fragments in this project. I have to be cautious about how fragments are moving through activities and I am not starting or ending things prematurely. I have read Activity and Fragment lifecycle way too many times and they make no sense to me in real app.

I am also skeptical about my work in details screen. I wasn’t able to implement much material design in the details screen. The thing is that there isn’t enough time. Most of the things that I wanted to implement would require me days to work on. I suppose that’s how first versions are. So here it is.

Popular Movies Details Screen

Writing Android app is like being a thief at least at the beginning stage. You may also call it working with lego if you don’t like the word thief. I spend a huge amounts of time just gettings things working with each other.

It’s a lot of hard work to end with a short note.