aboutsummaryrefslogtreecommitdiffstats
path: root/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java
diff options
context:
space:
mode:
authorLeif Åstrand <leif@vaadin.com>2012-09-05 17:10:31 +0300
committerLeif Åstrand <leif@vaadin.com>2012-09-05 17:10:31 +0300
commit5ab35cc6080653a7e9b25712f637db6c95c183ce (patch)
treed6fd4f845e96b5dd9c0e697aa9ff7683ec5742c8 /uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java
parent3ddaf280d61642742dff3f4a63376d0eedca5abf (diff)
downloadvaadin-framework-5ab35cc6080653a7e9b25712f637db6c95c183ce.tar.gz
vaadin-framework-5ab35cc6080653a7e9b25712f637db6c95c183ce.zip
Combine ApplicationContext into Application (#9402)
Diffstat (limited to 'uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java')
-rw-r--r--uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java9
1 files changed, 5 insertions, 4 deletions
diff --git a/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java b/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java
index a9a988f296..34c1cc1fce 100644
--- a/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java
+++ b/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java
@@ -34,6 +34,7 @@ import com.vaadin.LegacyApplication;
import com.vaadin.server.AbstractUIProvider;
import com.vaadin.server.ApplicationConfiguration;
import com.vaadin.server.LegacyVaadinServlet;
+import com.vaadin.server.ServletApplicationContext;
import com.vaadin.server.UIProvider;
import com.vaadin.server.WrappedHttpServletRequest;
import com.vaadin.server.WrappedRequest;
@@ -112,12 +113,12 @@ public class ApplicationRunnerServlet extends LegacyVaadinServlet {
}
@Override
- protected Application createApplication(HttpServletRequest request)
- throws ServletException {
+ protected ServletApplicationContext createApplication(
+ HttpServletRequest request) throws ServletException {
try {
final Class<?> classToRun = getClassToRun();
if (UI.class.isAssignableFrom(classToRun)) {
- Application application = new Application();
+ ServletApplicationContext application = new ServletApplicationContext();
application.addUIProvider(new AbstractUIProvider() {
@Override
@@ -130,7 +131,7 @@ public class ApplicationRunnerServlet extends LegacyVaadinServlet {
} else if (LegacyApplication.class.isAssignableFrom(classToRun)) {
return super.createApplication(request);
} else if (UIProvider.class.isAssignableFrom(classToRun)) {
- Application application = new Application();
+ ServletApplicationContext application = new ServletApplicationContext();
application
.addUIProvider((UIProvider) classToRun.newInstance());
return application;