blob: dc238c31029f7a3e63a7c64ed046520f03155756 [file] [log] [blame]
/**
*
* Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany)
*
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation
*
*/
package org.eclipse.osbp.vaaclipse.addons.login;
import javax.inject.Inject;
import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute;
import org.eclipse.e4.core.services.events.IEventBroker;
import org.eclipse.osbp.vaaclipse.publicapi.authentication.AuthenticationConstants;
public class LogoutHandler {
@Inject
private IEventBroker eventBroker;
@Execute
public void execute() {
eventBroker.send(
AuthenticationConstants.Events.Authentication.PRE_LOGOUT,
new Object());
eventBroker.send(AuthenticationConstants.Events.Authentication.LOGOUT,
new Object());
}
@CanExecute
public boolean canExecute() {
return true;
}
}