private List<AddonContextListener> initedListeners = new ArrayList<AddonContextListener>();
/**
- * Creates a new context using a given deployment configuration. Only the
- * framework itself should typically create AddonContext methods.
+ * Creates a new context using a given vaadin service. Only the framework
+ * itself should typically create AddonContext instances.
*
* @param vaadinService
* the vaadin service for the associated servlet or portlet.
}
/**
- * Gets the deployment configuration for this context.
+ * Gets the vaadin service for this context.
*
- * @return the deployment configuration
+ * @return the vaadin service
*/
public VaadinService getVaadinService() {
return vaadinService;
}
/**
- * Gets a the deployment configuration for this servlet.
+ * Gets a the vaadin service for this servlet.
*
- * @return the deployment configuration
+ * @return the vaadin service
*/
protected ServletService getVaadinService() {
return servletService;
private final ServletService vaadinService;
/**
- * Wraps a http servlet request and associates with a deployment
- * configuration
+ * Wraps a http servlet request and associates with a vaadin service
*
* @param request
* the http servlet request to wrap
private ServletService vaadinService;
/**
- * Wraps a http servlet response and an associated deployment configuration
+ * Wraps a http servlet response and an associated vaadin service
*
* @param response
* the http servlet response to wrap
private final PortletService vaadinService;
/**
- * Wraps a portlet request and an associated deployment configuration
+ * Wraps a portlet request and an associated vaadin service
*
* @param request
* the portlet request to wrap
private PortletService vaadinService;
/**
- * Wraps a portlet response and an associated deployment configuration
+ * Wraps a portlet response and an associated vaadin service
*
* @param response
* the portlet response to wrap
servlet = new VaadinServlet();
// Workaround to avoid calling init and creating servlet config
- Field f = VaadinServlet.class
- .getDeclaredField("deploymentConfiguration");
+ Field f = VaadinServlet.class.getDeclaredField("servletService");
f.setAccessible(true);
f.set(servlet, new ServletService(servlet,
new DefaultApplicationConfiguration(servlet.getClass(),
}
private static WrappedRequest createRequestMock(ClassLoader classloader) {
- // Mock a DeploymentConfiguration to give the passed classloader
+ // Mock a VaadinService to give the passed classloader
VaadinService configurationMock = EasyMock
.createMock(VaadinService.class);
EasyMock.expect(configurationMock.getClassLoader()).andReturn(
classloader);
- // Mock a WrappedRequest to give the mocked deployment configuration
+ // Mock a WrappedRequest to give the mocked vaadin service
WrappedRequest requestMock = EasyMock.createMock(WrappedRequest.class);
EasyMock.expect(requestMock.getVaadinService()).andReturn(
configurationMock);