/** * Returns <code>true</code> if logins are currently forbidden according to the settings * of this message.<p> * * This checks the time settings using <code>{@link #isActive()}</code> and * <code>{@link #isEnabled()}</code> as well as the * <code>{@link #isLoginForbidden()}</code> flag.<p> * * @return <code>true</code> if logins are currently forbidden according to the settings of this message */ public boolean isLoginCurrentlyForbidden() { return m_loginForbidden && isActive(); }
/** * Returns <code>true</code> if logins are currently forbidden according to the settings * of this message.<p> * * This checks the time settings using <code>{@link #isActive()}</code> and * <code>{@link #isEnabled()}</code> as well as the * <code>{@link #isLoginForbidden()}</code> flag.<p> * * @return <code>true</code> if logins are currently forbidden according to the settings of this message */ public boolean isLoginCurrentlyForbidden() { return m_loginForbidden && isActive(); }
if ((loginMessage != null) && (loginMessage.isActive())) { String msg; if (loginMessage.isLoginForbidden()) {
if ((loginMessage != null) && (loginMessage.isActive())) { String msg; if (loginMessage.isLoginForbidden()) {
/** * Log a user in to the the CmsSell.<p> * * @param username the name of the user to log in * @param password the password of the user */ public void login(String username, String password) { username = OpenCms.getImportExportManager().translateUser(username); try { m_cms.loginUser(username, password); // reset the settings, this will switch the startup site root etc. m_shell.initSettings(); System.out.println(getMessages().key(Messages.GUI_SHELL_LOGIN_1, whoami().getName())); // output the login message if required CmsLoginMessage message = OpenCms.getLoginManager().getLoginMessage(); if ((message != null) && (message.isActive())) { System.out.println(message.getMessage()); } } catch (Exception exc) { System.out.println(getMessages().key(Messages.GUI_SHELL_LOGIN_FAILED_0)); } }
/** * Log a user in to the the CmsSell.<p> * * @param username the name of the user to log in * @param password the password of the user */ public void login(String username, String password) { username = OpenCms.getImportExportManager().translateUser(username); try { m_cms.loginUser(username, password); // reset the settings, this will switch the startup site root etc. m_shell.initSettings(); m_shell.getOut().println(getMessages().key(Messages.GUI_SHELL_LOGIN_1, whoami().getName())); // output the login message if required CmsLoginMessage message = OpenCms.getLoginManager().getLoginMessage(); if ((message != null) && (message.isActive())) { m_shell.getOut().println(message.getMessage()); } } catch (Exception exc) { m_shell.getOut().println(getMessages().key(Messages.GUI_SHELL_LOGIN_FAILED_0)); } }
if ((loginMessage != null) && loginMessage.isActive()) { OpenCms.getSessionManager().updateSessionInfo(getCmsObject(), getRequest()); OpenCms.getSessionManager().sendBroadcast(null, loginMessage.getMessage(), user);
CmsLoginMessage loginMessage = OpenCms.getLoginManager().getLoginMessage(); String storedMessage = null; if ((loginMessage != null) && !loginMessage.isLoginCurrentlyForbidden() && loginMessage.isActive()) { storedMessage = loginMessage.getMessage();