Refactoring code and add ImageClientWebService.