public void logout() throws SecurityServiceException { ServletGraniteContext graniteContext = (ServletGraniteContext)GraniteContext.getCurrentInstance(); if (graniteContext instanceof HttpGraniteContext) { Request request = (Request)graniteContext.getRequest(); Authentication authentication = request.getAuthentication(); if (authentication instanceof Authentication.User) ((Authentication.User)authentication).logout(); if (request.getSession(false) != null) { endLogout(); request.getSession(false).invalidate(); } } else { HttpSession session = graniteContext.getSession(); if (session != null) { AuthenticationContext authenticationContext = (AuthenticationContext)session.getAttribute(AuthenticationContext.class.getName()); authenticationContext.logout(); session.removeAttribute(AuthenticationContext.class.getName()); endLogout(); session.invalidate(); } } }
Authentication authentication = request.getAuthentication(); if (authentication instanceof Authentication.User) ((Authentication.User)authentication).logout();
public void logout() { if (authentication instanceof Authentication.User) ((Authentication.User)authentication).logout(); } }
public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
@Override public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
public void logout() { if (authentication instanceof Authentication.User) ((Authentication.User)authentication).logout(); } }
@Override public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
@Override public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
@Override public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }
@Override public void logout() throws ServletException { if (_authentication instanceof Authentication.User) ((Authentication.User)_authentication).logout(); _authentication=Authentication.UNAUTHENTICATED; }