use of com.zimbra.soap.account.message.EndSessionRequest in project zm-mailbox by Zimbra.
the class ZMailbox method logout.
public void logout() throws ZClientException {
if (mAuthToken == null) {
return;
}
EndSessionRequest logout = new EndSessionRequest();
logout.setLogOff(true);
try {
invokeJaxb(logout);
} catch (ServiceException e) {
// do not thrown an exception if the authtoken has already expired as when user us redirected to logout tag when authtoken expires.
if (!ServiceException.AUTH_EXPIRED.equals(e.getCode())) {
throw ZClientException.CLIENT_ERROR("Failed to log out", e);
}
}
}
Aggregations