Saturday, February 20, 2016

Game of Life

About eight years over due, I've finally programmed an implementation of Conway's Game of Life.

Here's my code.

Of course I had started and given up on this before. After watching the video below by Computerphile I decided to revisit it.

Saturday, November 7, 2015

REST API WEEK! App a Day 22: Reddit Images

I'm not sure if this one is really accessing an API, technically. Though it does request subreddits in JSON in order to display thumbnails of images which doesn't require any authentication.

REST API WEEK! App a Day 21: Goodreads Authors

Classes Used: Service, AbstractThreadedSyncAdapter, XmlPullParser, ContentProvider, ContentResolver SQLiteOpenHelper, Handler, ContentObserver.

I've always wanted to play with the Goodreads API. So here's my first attempt. Responses are in XML only, unfortunately. This makes a request for the books (reviews) in my favorites shelf and lists the authors. Very simple in theory. I was going to do more but I ran out of time.

I finally made some templates files for a SQLite Database, but without any of the provider's URI constants. Just copy the gist code below into a file template.

Friday, November 6, 2015

REST API WEEK! App a Day 20: Facebook Likes

Uses Classes: FacebookSdk, LoginButton, FacebookCallback, AsyncTask, Thread, BaseAdapter, GraphRequest, JSONObject, JSONArray.

This uses the Facebook Graph API and SDK to display the first page of the user's likes.

Wednesday, November 4, 2015

REST API WEEK! App a Day 19: Weather Map

Classes Used: ContentProvider, ContentResolver, Service, AbstractThreadedSyncAdapter, GoogleMap, Handler

I think I need to learn a lot in regards to what is possible using data that is already out there. So I'm going to make this REST API week. I'll use different API's in all of my dailies.
This one uses Using it's cities in cycle feature it grabs current temperatures for 10 cities near your current GPS location and displays the markers on the map.

Friday, October 23, 2015

App a Day 18: Todo with DatePicker

Classes Used: DatePicker, Preference, PreferenceActivity, CheckBoxPreference, SharedPreferences, Preference Manager, OnPreferenceChangeListener, OnPreferenceClickListener

I fought with this one for a good while. I'll say if you're starting a new project it's probably a good idea to store dates as string. If you are storing them as integer's just remember that SQLite assumes your time is in the format epoch time in SECONDs. Not milliseconds, even though an integer in SQLite is 64 bits, same as java's long. Okay just remember that.

Saturday, October 17, 2015

App a Day 16: Coursera Android Concurrency Assignment 1

Day 16 is unconventional, I'm going through Coursera's online class called: "Programming Mobile Services for Android Handheld Systems: Concurrency." This is the first assignment from that course. The assignment is to implement a couple of predefined Threads and Runnables and use a java semaphore. The UI and the app structure already existed. Here's the unfinished source.