Refactoring Android client