Refactoring SphereJavaClient.