use of com.willshex.blogwt.client.api.user.event.GetEmailAvatarEventHandler.GetEmailAvatarSuccess in project blogwt by billy1380.
the class UserController method getEmailAvatar.
/**
* @param email
*/
public void getEmailAvatar(String email) {
final GetEmailAvatarRequest input = ApiHelper.setAccessCode(new GetEmailAvatarRequest());
input.session = SessionController.get().sessionForApiCall();
input.email = email;
if (getEmailAvatarRequest != null) {
getEmailAvatarRequest.cancel();
}
getEmailAvatarRequest = ApiHelper.createUserClient().getEmailAvatar(input, new AsyncCallback<GetEmailAvatarResponse>() {
@Override
public void onSuccess(GetEmailAvatarResponse output) {
getEmailAvatarRequest = null;
if (output.status == StatusType.StatusTypeSuccess) {
}
DefaultEventBus.get().fireEventFromSource(new GetEmailAvatarSuccess(input, output), UserController.this);
}
@Override
public void onFailure(Throwable caught) {
DefaultEventBus.get().fireEventFromSource(new GetEmailAvatarFailure(input, caught), UserController.this);
}
});
}
Aggregations