[Android] Modified server to use resources.

I modified a server to use resources as in Web api draft so it will be easier to add new functionalities.