aboutsummaryrefslogtreecommitdiffstats
path: root/src/com/itmill/toolkit/Application.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/itmill/toolkit/Application.java')
-rw-r--r--src/com/itmill/toolkit/Application.java38
1 files changed, 35 insertions, 3 deletions
diff --git a/src/com/itmill/toolkit/Application.java b/src/com/itmill/toolkit/Application.java
index 5a18903fa1..6a7758f880 100644
--- a/src/com/itmill/toolkit/Application.java
+++ b/src/com/itmill/toolkit/Application.java
@@ -163,11 +163,18 @@ public abstract class Application implements URIHandler, Terminal.ErrorListener
private long lastResourceKeyNumber = 0;
/**
- * URL the user is redirected to on application close or null if application
- * is just closed
+ * URL where the user is redirected to on application close, or null if
+ * application is just closed without redirection.
*/
private String logoutURL = null;
+ /**
+ * URL where the user is redirected to when the Toolkit ApplicationServlet
+ * session expires, or null if the application is just closed without
+ * redirection.
+ */
+ private String expiredURL = null;
+
private Focusable pendingFocus;
/**
@@ -996,7 +1003,7 @@ public abstract class Application implements URIHandler, Terminal.ErrorListener
}
/**
- * Returns the URL user is redirected to on application close.If the URL is
+ * Returns the URL user is redirected to on application close. If the URL is
* <code>null</code>, the application is closed normally as defined by
* the application running environment.
* <p>
@@ -1025,6 +1032,31 @@ public abstract class Application implements URIHandler, Terminal.ErrorListener
}
/**
+ * Returns the URL where user is redirected to when the Toolkit
+ * ApplicationServlet session expires. If the URL is <code>null</code>,
+ * the application is closed normally and it shows a notification to the
+ * client.
+ *
+ * @return the URL.
+ */
+ public String getSessionExpiredURL() {
+ return expiredURL;
+ }
+
+ /**
+ * Sets the URL where user is redirected to when the Toolkit
+ * ApplicationServlet session expires. If the URL is <code>null</code>,
+ * the application is closed normally and it shows a notification to the
+ * client.
+ *
+ * @param expiredURL
+ * the expiredURL to set.
+ */
+ public void setSessionExpiredURL(String expiredURL) {
+ this.expiredURL = expiredURL;
+ }
+
+ /**
* <p>
* Invoked by the terminal on any exception that occurs in application and
* is thrown by the <code>setVariable</code> to the terminal. The default