summaryrefslogtreecommitdiffstats
path: root/server/src
diff options
context:
space:
mode:
authorLeif Åstrand <leif@vaadin.com>2012-09-20 15:33:19 +0300
committerLeif Åstrand <leif@vaadin.com>2012-09-20 15:33:19 +0300
commit6335562c72fb193a2835a3a09b617aa6c90efea6 (patch)
tree63288fef0874cf5a03b8d3e034f65daae92c2c29 /server/src
parent23e77a833df4845c0c0011dde13e6fc5db901a1c (diff)
downloadvaadin-framework-6335562c72fb193a2835a3a09b617aa6c90efea6.tar.gz
vaadin-framework-6335562c72fb193a2835a3a09b617aa6c90efea6.zip
Rename WrappedXYZ -> VaadinXYZ but retain WrappedSession (#9633)
Diffstat (limited to 'server/src')
-rw-r--r--server/src/com/vaadin/server/AbstractClientConnector.java4
-rw-r--r--server/src/com/vaadin/server/AbstractCommunicationManager.java70
-rw-r--r--server/src/com/vaadin/server/AbstractUIProvider.java12
-rw-r--r--server/src/com/vaadin/server/BootstrapFragmentResponse.java8
-rw-r--r--server/src/com/vaadin/server/BootstrapHandler.java36
-rw-r--r--server/src/com/vaadin/server/BootstrapPageResponse.java12
-rw-r--r--server/src/com/vaadin/server/BootstrapResponse.java12
-rw-r--r--server/src/com/vaadin/server/ClientConnector.java4
-rw-r--r--server/src/com/vaadin/server/CombinedRequest.java14
-rw-r--r--server/src/com/vaadin/server/ConnectorResourceHandler.java6
-rw-r--r--server/src/com/vaadin/server/DefaultUIProvider.java2
-rw-r--r--server/src/com/vaadin/server/DownloadStream.java8
-rw-r--r--server/src/com/vaadin/server/DragAndDropService.java4
-rw-r--r--server/src/com/vaadin/server/DynamicConnectorResource.java6
-rw-r--r--server/src/com/vaadin/server/GAEVaadinServlet.java18
-rw-r--r--server/src/com/vaadin/server/GlobalResourceHandler.java6
-rw-r--r--server/src/com/vaadin/server/LegacyApplicationUIProvider.java12
-rw-r--r--server/src/com/vaadin/server/LegacyVaadinPortlet.java4
-rw-r--r--server/src/com/vaadin/server/LegacyVaadinServlet.java2
-rw-r--r--server/src/com/vaadin/server/Page.java4
-rw-r--r--server/src/com/vaadin/server/PortletCommunicationManager.java14
-rw-r--r--server/src/com/vaadin/server/RequestHandler.java4
-rw-r--r--server/src/com/vaadin/server/ServletPortletHelper.java12
-rw-r--r--server/src/com/vaadin/server/UIProvider.java22
-rw-r--r--server/src/com/vaadin/server/UnsupportedBrowserHandler.java6
-rw-r--r--server/src/com/vaadin/server/VaadinPortlet.java128
-rw-r--r--server/src/com/vaadin/server/VaadinPortletRequest.java (renamed from server/src/com/vaadin/server/WrappedPortletRequest.java)26
-rw-r--r--server/src/com/vaadin/server/VaadinPortletResponse.java (renamed from server/src/com/vaadin/server/WrappedPortletResponse.java)10
-rw-r--r--server/src/com/vaadin/server/VaadinPortletSession.java8
-rw-r--r--server/src/com/vaadin/server/VaadinRequest.java (renamed from server/src/com/vaadin/server/WrappedRequest.java)6
-rw-r--r--server/src/com/vaadin/server/VaadinResponse.java (renamed from server/src/com/vaadin/server/WrappedResponse.java)2
-rw-r--r--server/src/com/vaadin/server/VaadinService.java58
-rw-r--r--server/src/com/vaadin/server/VaadinServlet.java83
-rw-r--r--server/src/com/vaadin/server/VaadinServletRequest.java (renamed from server/src/com/vaadin/server/WrappedHttpServletRequest.java)26
-rw-r--r--server/src/com/vaadin/server/VaadinServletResponse.java (renamed from server/src/com/vaadin/server/WrappedHttpServletResponse.java)14
-rw-r--r--server/src/com/vaadin/server/VaadinSession.java24
-rw-r--r--server/src/com/vaadin/server/VaadinSessionInitializeEvent.java6
-rw-r--r--server/src/com/vaadin/server/WebBrowser.java4
-rw-r--r--server/src/com/vaadin/ui/AbstractMedia.java8
-rw-r--r--server/src/com/vaadin/ui/LoginForm.java6
-rw-r--r--server/src/com/vaadin/ui/UI.java30
41 files changed, 366 insertions, 375 deletions
diff --git a/server/src/com/vaadin/server/AbstractClientConnector.java b/server/src/com/vaadin/server/AbstractClientConnector.java
index 0f42c0a28f..278d726451 100644
--- a/server/src/com/vaadin/server/AbstractClientConnector.java
+++ b/server/src/com/vaadin/server/AbstractClientConnector.java
@@ -570,8 +570,8 @@ public abstract class AbstractClientConnector implements ClientConnector {
}
@Override
- public boolean handleConnectorRequest(WrappedRequest request,
- WrappedResponse response, String path) throws IOException {
+ public boolean handleConnectorRequest(VaadinRequest request,
+ VaadinResponse response, String path) throws IOException {
String[] parts = path.split("/", 2);
String key = parts[0];
diff --git a/server/src/com/vaadin/server/AbstractCommunicationManager.java b/server/src/com/vaadin/server/AbstractCommunicationManager.java
index 07959b1558..49243a0589 100644
--- a/server/src/com/vaadin/server/AbstractCommunicationManager.java
+++ b/server/src/com/vaadin/server/AbstractCommunicationManager.java
@@ -117,8 +117,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
@Deprecated
public interface Callback extends Serializable {
- public void criticalNotification(WrappedRequest request,
- WrappedResponse response, String cap, String msg,
+ public void criticalNotification(VaadinRequest request,
+ VaadinResponse response, String cap, String msg,
String details, String outOfSyncURL) throws IOException;
}
@@ -219,8 +219,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @param boundary
* @throws IOException
*/
- protected void doHandleSimpleMultipartFileUpload(WrappedRequest request,
- WrappedResponse response, StreamVariable streamVariable,
+ protected void doHandleSimpleMultipartFileUpload(VaadinRequest request,
+ VaadinResponse response, StreamVariable streamVariable,
String variableName, ClientConnector owner, String boundary)
throws IOException {
// multipart parsing, supports only one file for request, but that is
@@ -323,8 +323,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @param contentLength
* @throws IOException
*/
- protected void doHandleXhrFilePost(WrappedRequest request,
- WrappedResponse response, StreamVariable streamVariable,
+ protected void doHandleXhrFilePost(VaadinRequest request,
+ VaadinResponse response, StreamVariable streamVariable,
String variableName, ClientConnector owner, int contentLength)
throws IOException {
@@ -501,8 +501,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @param response
* @throws IOException
*/
- protected void sendUploadResponse(WrappedRequest request,
- WrappedResponse response) throws IOException {
+ protected void sendUploadResponse(VaadinRequest request,
+ VaadinResponse response) throws IOException {
response.setContentType("text/html");
final OutputStream out = response.getOutputStream();
final PrintWriter outWriter = new PrintWriter(new BufferedWriter(
@@ -516,7 +516,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* Internally process a UIDL request from the client.
*
* This method calls
- * {@link #handleVariables(WrappedRequest, WrappedResponse, Callback, VaadinSession, UI)}
+ * {@link #handleVariables(VaadinRequest, VaadinResponse, Callback, VaadinSession, UI)}
* to process any changes to variables by the client and then repaints
* affected components using {@link #paintAfterVariableChanges()}.
*
@@ -537,8 +537,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @throws InvalidUIDLSecurityKeyException
* @throws JSONException
*/
- public void handleUidlRequest(WrappedRequest request,
- WrappedResponse response, Callback callback, UI uI)
+ public void handleUidlRequest(VaadinRequest request,
+ VaadinResponse response, Callback callback, UI uI)
throws IOException, InvalidUIDLSecurityKeyException, JSONException {
checkWidgetsetVersion(request);
@@ -623,7 +623,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
*
* @param request
*/
- private void checkWidgetsetVersion(WrappedRequest request) {
+ private void checkWidgetsetVersion(VaadinRequest request) {
String widgetsetVersion = request.getParameter("wsver");
if (widgetsetVersion == null) {
// Only check when the widgetset version is reported. It is reported
@@ -752,8 +752,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @throws IOException
* @throws JSONException
*/
- private void paintAfterVariableChanges(WrappedRequest request,
- WrappedResponse response, Callback callback, boolean repaintAll,
+ private void paintAfterVariableChanges(VaadinRequest request,
+ VaadinResponse response, Callback callback, boolean repaintAll,
final PrintWriter outWriter, UI uI, boolean analyzeLayouts)
throws PaintException, IOException, JSONException {
openJsonMessage(outWriter, response);
@@ -780,7 +780,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @param request
* @return the security key UIDL or "" if the feature is turned off
*/
- public String getSecurityKeyUIDL(WrappedRequest request) {
+ public String getSecurityKeyUIDL(VaadinRequest request) {
final String seckey = getSecurityKey(request);
if (seckey != null) {
return "\"" + ApplicationConstants.UIDL_SECURITY_TOKEN_ID + "\":\""
@@ -796,7 +796,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @param request
* @return the security key
*/
- protected String getSecurityKey(WrappedRequest request) {
+ protected String getSecurityKey(VaadinRequest request) {
String seckey = null;
WrappedSession session = request.getWrappedSession();
seckey = (String) session
@@ -811,7 +811,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
}
@SuppressWarnings("unchecked")
- public void writeUidlResponse(WrappedRequest request, boolean repaintAll,
+ public void writeUidlResponse(VaadinRequest request, boolean repaintAll,
final PrintWriter outWriter, UI ui, boolean analyzeLayouts)
throws PaintException, JSONException {
ArrayList<ClientConnector> dirtyVisibleConnectors = new ArrayList<ClientConnector>();
@@ -1557,8 +1557,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
*
* @return true if successful, false if there was an inconsistency
*/
- private boolean handleVariables(WrappedRequest request,
- WrappedResponse response, Callback callback, VaadinSession session,
+ private boolean handleVariables(VaadinRequest request,
+ VaadinResponse response, Callback callback, VaadinSession session,
UI uI) throws IOException, InvalidUIDLSecurityKeyException,
JSONException {
boolean success = true;
@@ -1646,7 +1646,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @return true if the processing of the burst was successful and there were
* no messages to non-existent components
*/
- public boolean handleBurst(WrappedRequest source, UI uI, final String burst) {
+ public boolean handleBurst(VaadinRequest source, UI uI, final String burst) {
boolean success = true;
try {
Set<Connector> enabledConnectors = new HashSet<Connector>();
@@ -1908,7 +1908,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @return
* @throws IOException
*/
- protected String getRequestPayload(WrappedRequest request)
+ protected String getRequestPayload(VaadinRequest request)
throws IOException {
int requestLength = request.getContentLength();
@@ -2185,7 +2185,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @param response
*/
protected void openJsonMessage(PrintWriter outWriter,
- WrappedResponse response) {
+ VaadinResponse response) {
// Sets the response type
response.setContentType("application/json; charset=UTF-8");
// some dirt to prevent cross site scripting
@@ -2392,7 +2392,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* </p>
*
* @param request
- * the wrapped request to get information from
+ * the Vaadin request to get information from
* @param response
* the response to which data can be written
* @return returns <code>true</code> if a {@link RequestHandler} has
@@ -2406,8 +2406,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
*
* @since 7.0
*/
- protected boolean handleOtherRequest(WrappedRequest request,
- WrappedResponse response) throws IOException {
+ protected boolean handleOtherRequest(VaadinRequest request,
+ VaadinResponse response) throws IOException {
// Use a copy to avoid ConcurrentModificationException
for (RequestHandler handler : new ArrayList<RequestHandler>(
session.getRequestHandlers())) {
@@ -2419,8 +2419,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
return false;
}
- public void handleBrowserDetailsRequest(WrappedRequest request,
- WrappedResponse response, VaadinSession session) throws IOException {
+ public void handleBrowserDetailsRequest(VaadinRequest request,
+ VaadinResponse response, VaadinSession session) throws IOException {
session.getLock().lock();
@@ -2428,7 +2428,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
assert UI.getCurrent() == null;
CombinedRequest combinedRequest = new CombinedRequest(request);
- CurrentInstance.set(WrappedRequest.class, combinedRequest);
+ CurrentInstance.set(VaadinRequest.class, combinedRequest);
response.setContentType("application/json; charset=UTF-8");
@@ -2475,7 +2475,7 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @throws JSONException
* if an exception occurs while encoding output
*/
- protected String getInitialUIDL(WrappedRequest request, UI uI)
+ protected String getInitialUIDL(VaadinRequest request, UI uI)
throws PaintException, JSONException {
// TODO maybe unify writeUidlResponse()?
StringWriter sWriter = new StringWriter();
@@ -2505,8 +2505,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
*
* @throws IOException
*/
- public void serveConnectorResource(WrappedRequest request,
- WrappedResponse response) throws IOException {
+ public void serveConnectorResource(VaadinRequest request,
+ VaadinResponse response) throws IOException {
String pathInfo = request.getRequestPathInfo();
// + 2 to also remove beginning and ending slashes
@@ -2602,8 +2602,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @throws IOException
* @throws InvalidUIDLSecurityKeyException
*/
- public void handleFileUpload(VaadinSession session, WrappedRequest request,
- WrappedResponse response) throws IOException,
+ public void handleFileUpload(VaadinSession session, VaadinRequest request,
+ VaadinResponse response) throws IOException,
InvalidUIDLSecurityKeyException {
/*
@@ -2663,8 +2663,8 @@ public abstract class AbstractCommunicationManager implements Serializable {
* @param session
* @throws IOException
*/
- public void handleHeartbeatRequest(WrappedRequest request,
- WrappedResponse response, VaadinSession session) throws IOException {
+ public void handleHeartbeatRequest(VaadinRequest request,
+ VaadinResponse response, VaadinSession session) throws IOException {
UI ui = null;
try {
int uiId = Integer.parseInt(request
diff --git a/server/src/com/vaadin/server/AbstractUIProvider.java b/server/src/com/vaadin/server/AbstractUIProvider.java
index 5208997a65..32322fde65 100644
--- a/server/src/com/vaadin/server/AbstractUIProvider.java
+++ b/server/src/com/vaadin/server/AbstractUIProvider.java
@@ -27,7 +27,7 @@ import com.vaadin.ui.UI;
public abstract class AbstractUIProvider implements UIProvider {
@Override
- public UI createInstance(WrappedRequest request,
+ public UI createInstance(VaadinRequest request,
Class<? extends UI> type) {
try {
return type.newInstance();
@@ -75,7 +75,7 @@ public abstract class AbstractUIProvider implements UIProvider {
}
@Override
- public String getTheme(WrappedRequest request,
+ public String getTheme(VaadinRequest request,
Class<? extends UI> uiClass) {
Theme uiTheme = getAnnotationFor(uiClass, Theme.class);
if (uiTheme != null) {
@@ -86,7 +86,7 @@ public abstract class AbstractUIProvider implements UIProvider {
}
@Override
- public String getWidgetset(WrappedRequest request,
+ public String getWidgetset(VaadinRequest request,
Class<? extends UI> uiClass) {
Widgetset uiWidgetset = getAnnotationFor(uiClass, Widgetset.class);
if (uiWidgetset != null) {
@@ -97,7 +97,7 @@ public abstract class AbstractUIProvider implements UIProvider {
}
@Override
- public boolean isPreservedOnRefresh(WrappedRequest request,
+ public boolean isPreservedOnRefresh(VaadinRequest request,
Class<? extends UI> uiClass) {
PreserveOnRefresh preserveOnRefresh = getAnnotationFor(uiClass,
PreserveOnRefresh.class);
@@ -105,7 +105,7 @@ public abstract class AbstractUIProvider implements UIProvider {
}
@Override
- public String getPageTitle(WrappedRequest request,
+ public String getPageTitle(VaadinRequest request,
Class<? extends UI> uiClass) {
Title titleAnnotation = getAnnotationFor(uiClass, Title.class);
if (titleAnnotation == null) {
@@ -116,7 +116,7 @@ public abstract class AbstractUIProvider implements UIProvider {
}
@Override
- public UI getExistingUI(WrappedRequest request) {
+ public UI getExistingUI(VaadinRequest request) {
return null;
}
}
diff --git a/server/src/com/vaadin/server/BootstrapFragmentResponse.java b/server/src/com/vaadin/server/BootstrapFragmentResponse.java
index ea13a04b8f..0269d1cfc0 100644
--- a/server/src/com/vaadin/server/BootstrapFragmentResponse.java
+++ b/server/src/com/vaadin/server/BootstrapFragmentResponse.java
@@ -36,13 +36,13 @@ public class BootstrapFragmentResponse extends BootstrapResponse {
/**
* Crate a new bootstrap fragment response.
*
- * @see BootstrapResponse#BootstrapResponse(BootstrapHandler,
- * WrappedRequest, VaadinSession, Class)
+ * @see BootstrapResponse#BootstrapResponse(BootstrapHandler, VaadinRequest,
+ * VaadinSession, Class)
*
* @param handler
* the bootstrap handler that is firing the event
* @param request
- * the wrapped request for which the bootstrap page should be
+ * the Vaadin request for which the bootstrap page should be
* generated
* @param session
* the vaadin session for which the bootstrap page should be
@@ -54,7 +54,7 @@ public class BootstrapFragmentResponse extends BootstrapResponse {
* application HTML
*/
public BootstrapFragmentResponse(BootstrapHandler handler,
- WrappedRequest request, VaadinSession session,
+ VaadinRequest request, VaadinSession session,
Class<? extends UI> uiClass, List<Node> fragmentNodes) {
super(handler, request, session, uiClass);
this.fragmentNodes = fragmentNodes;
diff --git a/server/src/com/vaadin/server/BootstrapHandler.java b/server/src/com/vaadin/server/BootstrapHandler.java
index a25c1860ef..7e4fd653bf 100644
--- a/server/src/com/vaadin/server/BootstrapHandler.java
+++ b/server/src/com/vaadin/server/BootstrapHandler.java
@@ -54,24 +54,24 @@ public abstract class BootstrapHandler implements RequestHandler {
protected class BootstrapContext implements Serializable {
- private final WrappedResponse response;
+ private final VaadinResponse response;
private final BootstrapFragmentResponse bootstrapResponse;
private String widgetsetName;
private String themeName;
private String appId;
- public BootstrapContext(WrappedResponse response,
+ public BootstrapContext(VaadinResponse response,
BootstrapFragmentResponse bootstrapResponse) {
this.response = response;
this.bootstrapResponse = bootstrapResponse;
}
- public WrappedResponse getResponse() {
+ public VaadinResponse getResponse() {
return response;
}
- public WrappedRequest getRequest() {
+ public VaadinRequest getRequest() {
return bootstrapResponse.getRequest();
}
@@ -111,8 +111,8 @@ public abstract class BootstrapHandler implements RequestHandler {
}
@Override
- public boolean handleRequest(VaadinSession session, WrappedRequest request,
- WrappedResponse response) throws IOException {
+ public boolean handleRequest(VaadinSession session, VaadinRequest request,
+ VaadinResponse response) throws IOException {
try {
Class<? extends UI> uiClass = session.getUIClass(request);
@@ -136,8 +136,8 @@ public abstract class BootstrapHandler implements RequestHandler {
}
private String getBootstrapHtml(BootstrapContext context) {
- WrappedRequest request = context.getRequest();
- WrappedResponse response = context.getResponse();
+ VaadinRequest request = context.getRequest();
+ VaadinResponse response = context.getResponse();
VaadinService vaadinService = request.getVaadinService();
BootstrapFragmentResponse fragmentResponse = context
@@ -174,7 +174,7 @@ public abstract class BootstrapHandler implements RequestHandler {
}
}
- private void sendBootstrapHeaders(WrappedResponse response,
+ private void sendBootstrapHeaders(VaadinResponse response,
Map<String, Object> headers) {
Set<Entry<String, Object>> entrySet = headers.entrySet();
for (Entry<String, Object> header : entrySet) {
@@ -190,7 +190,7 @@ public abstract class BootstrapHandler implements RequestHandler {
}
}
- private void writeBootstrapPage(WrappedResponse response, String html)
+ private void writeBootstrapPage(VaadinResponse response, String html)
throws IOException {
response.setContentType("text/html");
BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(
@@ -250,8 +250,8 @@ public abstract class BootstrapHandler implements RequestHandler {
body.addClass(ApplicationConstants.GENERATED_BODY_CLASSNAME);
}
- private BootstrapContext createContext(WrappedRequest request,
- WrappedResponse response, VaadinSession application,
+ private BootstrapContext createContext(VaadinRequest request,
+ VaadinResponse response, VaadinSession application,
Class<? extends UI> uiClass) {
BootstrapContext context = new BootstrapContext(response,
new BootstrapFragmentResponse(this, request, application,
@@ -274,7 +274,7 @@ public abstract class BootstrapHandler implements RequestHandler {
protected abstract String getApplicationId(BootstrapContext context);
public String getWidgetsetForUI(BootstrapContext context) {
- WrappedRequest request = context.getRequest();
+ VaadinRequest request = context.getRequest();
String widgetset = context.getVaadinSession()
.getUiProvider(context.getRequest(), context.getUIClass())
@@ -331,7 +331,7 @@ public abstract class BootstrapHandler implements RequestHandler {
.append("You have to enable javascript in your browser to use an application built with Vaadin.");
fragmentNodes.add(mainDiv);
- WrappedRequest request = context.getRequest();
+ VaadinRequest request = context.getRequest();
VaadinService vaadinService = request.getVaadinService();
String staticFileLocation = vaadinService
@@ -423,7 +423,7 @@ public abstract class BootstrapHandler implements RequestHandler {
throws JSONException {
JSONObject defaults = new JSONObject();
- WrappedRequest request = context.getRequest();
+ VaadinRequest request = context.getRequest();
VaadinSession session = context.getVaadinSession();
VaadinService vaadinService = request.getVaadinService();
@@ -486,7 +486,7 @@ public abstract class BootstrapHandler implements RequestHandler {
* @return
*/
public String getThemeUri(BootstrapContext context, String themeName) {
- WrappedRequest request = context.getRequest();
+ VaadinRequest request = context.getRequest();
final String staticFilePath = request.getVaadinService()
.getStaticFileLocation(request);
return staticFilePath + "/" + VaadinServlet.THEME_DIRECTORY_PATH
@@ -514,7 +514,7 @@ public abstract class BootstrapHandler implements RequestHandler {
public String findAndEscapeThemeName(BootstrapContext context) {
String themeName = getThemeName(context);
if (themeName == null) {
- WrappedRequest request = context.getRequest();
+ VaadinRequest request = context.getRequest();
themeName = request.getVaadinService().getConfiguredTheme(request);
}
@@ -525,7 +525,7 @@ public abstract class BootstrapHandler implements RequestHandler {
return themeName;
}
- protected void writeError(WrappedResponse response, Throwable e)
+ protected void writeError(VaadinResponse response, Throwable e)
throws IOException {
response.sendError(HttpServletResponse.SC_INTERNAL_SERVER_ERROR,
e.getLocalizedMessage());
diff --git a/server/src/com/vaadin/server/BootstrapPageResponse.java b/server/src/com/vaadin/server/BootstrapPageResponse.java
index 0b98c59e22..72bc2163e6 100644
--- a/server/src/com/vaadin/server/BootstrapPageResponse.java
+++ b/server/src/com/vaadin/server/BootstrapPageResponse.java
@@ -38,13 +38,13 @@ public class BootstrapPageResponse extends BootstrapResponse {
/**
* Crate a new bootstrap page response.
*
- * @see BootstrapResponse#BootstrapResponse(BootstrapHandler,
- * WrappedRequest, VaadinSession, Class)
+ * @see BootstrapResponse#BootstrapResponse(BootstrapHandler, VaadinRequest,
+ * VaadinSession, Class)
*
* @param handler
* the bootstrap handler that is firing the event
* @param request
- * the wrapped request for which the bootstrap page should be
+ * the Vaadin request for which the bootstrap page should be
* generated
* @param session
* the vaadin session for which the bootstrap page should be
@@ -57,7 +57,7 @@ public class BootstrapPageResponse extends BootstrapResponse {
* a map into which header data can be added
*/
public BootstrapPageResponse(BootstrapHandler handler,
- WrappedRequest request, VaadinSession session,
+ VaadinRequest request, VaadinSession session,
Class<? extends UI> uiClass, Document document,
Map<String, Object> headers) {
super(handler, request, session, uiClass);
@@ -69,7 +69,7 @@ public class BootstrapPageResponse extends BootstrapResponse {
* Sets a header value that will be added to the HTTP response. If the
* header had already been set, the new value overwrites the previous one.
*
- * @see WrappedResponse#setHeader(String, String)
+ * @see VaadinResponse#setHeader(String, String)
*
* @param name
* the name of the header
@@ -86,7 +86,7 @@ public class BootstrapPageResponse extends BootstrapResponse {
* overwrites the previous one.
*
* @see #setHeader(String, String)
- * @see WrappedResponse#setDateHeader(String, long)
+ * @see VaadinResponse#setDateHeader(String, long)
*
* @param name
* the name of the header
diff --git a/server/src/com/vaadin/server/BootstrapResponse.java b/server/src/com/vaadin/server/BootstrapResponse.java
index c0c8d4e699..86b37de22e 100644
--- a/server/src/com/vaadin/server/BootstrapResponse.java
+++ b/server/src/com/vaadin/server/BootstrapResponse.java
@@ -28,7 +28,7 @@ import com.vaadin.ui.UI;
* @since 7.0.0
*/
public abstract class BootstrapResponse extends EventObject {
- private final WrappedRequest request;
+ private final VaadinRequest request;
private final VaadinSession session;
private final Class<? extends UI> uiClass;
@@ -38,14 +38,14 @@ public abstract class BootstrapResponse extends EventObject {
* @param handler
* the bootstrap handler that is firing the event
* @param request
- * the wrapped request for which the bootstrap page should be
+ * the Vaadin request for which the bootstrap page should be
* generated
* @param session
* the session for which the bootstrap page should be generated
* @param uiClass
* the class of the UI that will be displayed on the page
*/
- public BootstrapResponse(BootstrapHandler handler, WrappedRequest request,
+ public BootstrapResponse(BootstrapHandler handler, VaadinRequest request,
VaadinSession session, Class<? extends UI> uiClass) {
super(handler);
this.request = request;
@@ -65,14 +65,14 @@ public abstract class BootstrapResponse extends EventObject {
/**
* Gets the request for which the generated bootstrap HTML will be the
* response. This can be used to read request headers and other additional
- * information. Please note that {@link WrappedRequest#getBrowserDetails()}
+ * information. Please note that {@link VaadinRequest#getBrowserDetails()}
* will not be available because the bootstrap page is generated before the
* bootstrap javascript has had a chance to send any information back to the
* server.
*
- * @return the wrapped request that is being handled
+ * @return the Vaadin request that is being handled
*/
- public WrappedRequest getRequest() {
+ public VaadinRequest getRequest() {
return request;
}
diff --git a/server/src/com/vaadin/server/ClientConnector.java b/server/src/com/vaadin/server/ClientConnector.java
index 65c0ca366a..b38f2a9037 100644
--- a/server/src/com/vaadin/server/ClientConnector.java
+++ b/server/src/com/vaadin/server/ClientConnector.java
@@ -237,6 +237,6 @@ public interface ClientConnector extends Connector, RpcTarget {
* @throws IOException
* if there is a problem generating a response.
*/
- public boolean handleConnectorRequest(WrappedRequest request,
- WrappedResponse response, String path) throws IOException;
+ public boolean handleConnectorRequest(VaadinRequest request,
+ VaadinResponse response, String path) throws IOException;
}
diff --git a/server/src/com/vaadin/server/CombinedRequest.java b/server/src/com/vaadin/server/CombinedRequest.java
index 91c5093ece..0a7da84049 100644
--- a/server/src/com/vaadin/server/CombinedRequest.java
+++ b/server/src/com/vaadin/server/CombinedRequest.java
@@ -29,17 +29,17 @@ import org.json.JSONException;
import org.json.JSONObject;
/**
- * A {@link WrappedRequest} with path and parameters from one request and
- * {@link WrappedRequest.BrowserDetails} extracted from another request.
+ * A {@link VaadinRequest} with path and parameters from one request and
+ * {@link VaadinRequest.BrowserDetails} extracted from another request.
*
* This class is intended to be used for a two request initialization where the
* first request fetches the actual application page and the second request
* contains information extracted from the browser using javascript.
*
*/
-public class CombinedRequest implements WrappedRequest {
+public class CombinedRequest implements VaadinRequest {
- private final WrappedRequest secondRequest;
+ private final VaadinRequest secondRequest;
private Map<String, String[]> parameterMap;
/**
@@ -52,7 +52,7 @@ public class CombinedRequest implements WrappedRequest {
* @throws JSONException
* if the initialParams parameter can not be decoded
*/
- public CombinedRequest(WrappedRequest secondRequest) throws JSONException {
+ public CombinedRequest(VaadinRequest secondRequest) throws JSONException {
this.secondRequest = secondRequest;
HashMap<String, String[]> map = new HashMap<String, String[]>();
@@ -156,9 +156,9 @@ public class CombinedRequest implements WrappedRequest {
* Gets the original second request. This can be used e.g. if a request
* parameter from the second request is required.
*
- * @return the original second wrapped request
+ * @return the original second Vaadin request
*/
- public WrappedRequest getSecondRequest() {
+ public VaadinRequest getSecondRequest() {
return secondRequest;
}
diff --git a/server/src/com/vaadin/server/ConnectorResourceHandler.java b/server/src/com/vaadin/server/ConnectorResourceHandler.java
index 50e5377e8d..1edd497d7c 100644
--- a/server/src/com/vaadin/server/ConnectorResourceHandler.java
+++ b/server/src/com/vaadin/server/ConnectorResourceHandler.java
@@ -25,7 +25,7 @@ public class ConnectorResourceHandler implements RequestHandler {
@Override
public boolean handleRequest(VaadinSession session,
- WrappedRequest request, WrappedResponse response)
+ VaadinRequest request, VaadinResponse response)
throws IOException {
String requestPath = request.getRequestPathInfo();
if (requestPath == null) {
@@ -68,8 +68,8 @@ public class ConnectorResourceHandler implements RequestHandler {
}
}
- private static boolean error(WrappedRequest request,
- WrappedResponse response, String logMessage) throws IOException {
+ private static boolean error(VaadinRequest request,
+ VaadinResponse response, String logMessage) throws IOException {
getLogger().log(Level.WARNING, logMessage);
response.sendError(HttpServletResponse.SC_NOT_FOUND,
request.getRequestPathInfo() + " can not be found");
diff --git a/server/src/com/vaadin/server/DefaultUIProvider.java b/server/src/com/vaadin/server/DefaultUIProvider.java
index c4a8069269..87bb7d27c2 100644
--- a/server/src/com/vaadin/server/DefaultUIProvider.java
+++ b/server/src/com/vaadin/server/DefaultUIProvider.java
@@ -21,7 +21,7 @@ import com.vaadin.ui.UI;
public class DefaultUIProvider extends AbstractUIProvider {
@Override
- public Class<? extends UI> getUIClass(WrappedRequest request) {
+ public Class<? extends UI> getUIClass(VaadinRequest request) {
Object uiClassNameObj = request.getVaadinService()
.getDeploymentConfiguration().getInitParameters()
.getProperty(VaadinSession.UI_PARAMETER);
diff --git a/server/src/com/vaadin/server/DownloadStream.java b/server/src/com/vaadin/server/DownloadStream.java
index 0c00f96832..3ba8b3d39a 100644
--- a/server/src/com/vaadin/server/DownloadStream.java
+++ b/server/src/com/vaadin/server/DownloadStream.java
@@ -220,7 +220,7 @@ public class DownloadStream implements Serializable {
}
/**
- * Writes this download stream to a wrapped response. This takes care of
+ * Writes this download stream to a Vaadin response. This takes care of
* setting response headers according to what is defined in this download
* stream ({@link #getContentType()}, {@link #getCacheTime()},
* {@link #getFileName()}) and transferring the data from the stream (
@@ -233,14 +233,14 @@ public class DownloadStream implements Serializable {
* @param request
* the request for which the response should be written
* @param response
- * the wrapped response to write this download stream to
+ * the Vaadin response to write this download stream to
*
* @throws IOException
- * passed through from the wrapped response
+ * passed through from the Vaadin response
*
* @since 7.0
*/
- public void writeResponse(WrappedRequest request, WrappedResponse response)
+ public void writeResponse(VaadinRequest request, VaadinResponse response)
throws IOException {
if (getParameter("Location") != null) {
response.setStatus(HttpServletResponse.SC_MOVED_TEMPORARILY);
diff --git a/server/src/com/vaadin/server/DragAndDropService.java b/server/src/com/vaadin/server/DragAndDropService.java
index 2d0a9e73e9..69ab997b18 100644
--- a/server/src/com/vaadin/server/DragAndDropService.java
+++ b/server/src/com/vaadin/server/DragAndDropService.java
@@ -342,8 +342,8 @@ public class DragAndDropService implements VariableOwner, ClientConnector {
}
@Override
- public boolean handleConnectorRequest(WrappedRequest request,
- WrappedResponse response, String path) throws IOException {
+ public boolean handleConnectorRequest(VaadinRequest request,
+ VaadinResponse response, String path) throws IOException {
return false;
}
}
diff --git a/server/src/com/vaadin/server/DynamicConnectorResource.java b/server/src/com/vaadin/server/DynamicConnectorResource.java
index 8269f261f7..264afa3f59 100644
--- a/server/src/com/vaadin/server/DynamicConnectorResource.java
+++ b/server/src/com/vaadin/server/DynamicConnectorResource.java
@@ -23,7 +23,7 @@ import com.vaadin.service.FileTypeResolver;
/**
* A resource that is served by calling
- * {@link ClientConnector#handleConnectorRequest(WrappedRequest, WrappedResponse, String)}
+ * {@link ClientConnector#handleConnectorRequest(VaadinRequest, VaadinResponse, String)}
* with appropriate parameters.
*
* @author Vaadin Ltd
@@ -39,7 +39,7 @@ public class DynamicConnectorResource implements Resource {
/**
* Creates a DynamicConnectorResoruce for the given connector that will be
* served by calling
- * {@link ClientConnector#handleConnectorRequest(WrappedRequest, WrappedResponse, String)}
+ * {@link ClientConnector#handleConnectorRequest(VaadinRequest, VaadinResponse, String)}
* with the given path.
*
* @param connector
@@ -54,7 +54,7 @@ public class DynamicConnectorResource implements Resource {
/**
* Creates a DynamicConnectorResoruce for the given connector that will be
* served by calling
- * {@link ClientConnector#handleConnectorRequest(WrappedRequest, WrappedResponse, String)}
+ * {@link ClientConnector#handleConnectorRequest(VaadinRequest, VaadinResponse, String)}
* with the given path and the given request parameters.
*
* @param connector
diff --git a/server/src/com/vaadin/server/GAEVaadinServlet.java b/server/src/com/vaadin/server/GAEVaadinServlet.java
index 44aca14fe3..df7daedfb8 100644
--- a/server/src/com/vaadin/server/GAEVaadinServlet.java
+++ b/server/src/com/vaadin/server/GAEVaadinServlet.java
@@ -133,8 +133,8 @@ public class GAEVaadinServlet extends VaadinServlet {
private static final String PROPERTY_APPENGINE_EXPIRES = "_expires";
protected void sendDeadlineExceededNotification(
- WrappedHttpServletRequest request,
- WrappedHttpServletResponse response) throws IOException {
+ VaadinServletRequest request,
+ VaadinServletResponse response) throws IOException {
criticalNotification(
request,
response,
@@ -144,8 +144,8 @@ public class GAEVaadinServlet extends VaadinServlet {
}
protected void sendNotSerializableNotification(
- WrappedHttpServletRequest request,
- WrappedHttpServletResponse response) throws IOException {
+ VaadinServletRequest request,
+ VaadinServletResponse response) throws IOException {
criticalNotification(
request,
response,
@@ -156,8 +156,8 @@ public class GAEVaadinServlet extends VaadinServlet {
}
protected void sendCriticalErrorNotification(
- WrappedHttpServletRequest request,
- WrappedHttpServletResponse response) throws IOException {
+ VaadinServletRequest request,
+ VaadinServletResponse response) throws IOException {
criticalNotification(
request,
response,
@@ -171,9 +171,9 @@ public class GAEVaadinServlet extends VaadinServlet {
protected void service(HttpServletRequest unwrappedRequest,
HttpServletResponse unwrappedResponse) throws ServletException,
IOException {
- WrappedHttpServletRequest request = new WrappedHttpServletRequest(
+ VaadinServletRequest request = new VaadinServletRequest(
unwrappedRequest, getVaadinService());
- WrappedHttpServletResponse response = new WrappedHttpServletResponse(
+ VaadinServletResponse response = new VaadinServletResponse(
unwrappedResponse, getVaadinService());
if (isCleanupRequest(request)) {
@@ -342,7 +342,7 @@ public class GAEVaadinServlet extends VaadinServlet {
// will create new context if the above did not
try {
return getVaadinService().findVaadinSession(
- createWrappedRequest(request));
+ createVaadinRequest(request));
} catch (Exception e) {
throw new ServletException(e);
}
diff --git a/server/src/com/vaadin/server/GlobalResourceHandler.java b/server/src/com/vaadin/server/GlobalResourceHandler.java
index 33a965369d..a7fff8ae64 100644
--- a/server/src/com/vaadin/server/GlobalResourceHandler.java
+++ b/server/src/com/vaadin/server/GlobalResourceHandler.java
@@ -66,7 +66,7 @@ public class GlobalResourceHandler implements RequestHandler {
@Override
public boolean handleRequest(VaadinSession session,
- WrappedRequest request, WrappedResponse response)
+ VaadinRequest request, VaadinResponse response)
throws IOException {
String pathInfo = request.getRequestPathInfo();
if (pathInfo == null) {
@@ -225,8 +225,8 @@ public class GlobalResourceHandler implements RequestHandler {
return Logger.getLogger(GlobalResourceHandler.class.getName());
}
- private static boolean error(WrappedRequest request,
- WrappedResponse response, String logMessage) throws IOException {
+ private static boolean error(VaadinRequest request,
+ VaadinResponse response, String logMessage) throws IOException {
getLogger().log(Level.WARNING, logMessage);
response.sendError(HttpServletResponse.SC_NOT_FOUND,
request.getRequestPathInfo() + " can not be found");
diff --git a/server/src/com/vaadin/server/LegacyApplicationUIProvider.java b/server/src/com/vaadin/server/LegacyApplicationUIProvider.java
index c0f64088b4..0681d0bee1 100644
--- a/server/src/com/vaadin/server/LegacyApplicationUIProvider.java
+++ b/server/src/com/vaadin/server/LegacyApplicationUIProvider.java
@@ -30,7 +30,7 @@ public abstract class LegacyApplicationUIProvider extends AbstractUIProvider {
.compile("^/?([^/]+).*");
@Override
- public Class<? extends UI> getUIClass(WrappedRequest request) {
+ public Class<? extends UI> getUIClass(VaadinRequest request) {
UI uiInstance = getUIInstance(request);
if (uiInstance != null) {
return uiInstance.getClass();
@@ -39,12 +39,12 @@ public abstract class LegacyApplicationUIProvider extends AbstractUIProvider {
}
@Override
- public UI createInstance(WrappedRequest request, Class<? extends UI> type) {
+ public UI createInstance(VaadinRequest request, Class<? extends UI> type) {
return getUIInstance(request);
}
@Override
- public String getTheme(WrappedRequest request, Class<? extends UI> uiClass) {
+ public String getTheme(VaadinRequest request, Class<? extends UI> uiClass) {
LegacyApplication application = getApplication();
if (application != null) {
return application.getTheme();
@@ -54,7 +54,7 @@ public abstract class LegacyApplicationUIProvider extends AbstractUIProvider {
}
@Override
- public String getPageTitle(WrappedRequest request,
+ public String getPageTitle(VaadinRequest request,
Class<? extends UI> uiClass) {
UI uiInstance = getUIInstance(request);
if (uiInstance != null) {
@@ -64,7 +64,7 @@ public abstract class LegacyApplicationUIProvider extends AbstractUIProvider {
}
}
- private UI getUIInstance(WrappedRequest request) {
+ private UI getUIInstance(VaadinRequest request) {
String pathInfo = request.getRequestPathInfo();
String name = null;
if (pathInfo != null && pathInfo.length() > 0) {
@@ -94,7 +94,7 @@ public abstract class LegacyApplicationUIProvider extends AbstractUIProvider {
* {@inheritDoc}
*/
@Override
- public UI getExistingUI(WrappedRequest request) {
+ public UI getExistingUI(VaadinRequest request) {
UI uiInstance = getUIInstance(request);
if (uiInstance == null || uiInstance.getUIId() == -1) {
// Not initialized -> Let go through createUIInstance to make it
diff --git a/server/src/com/vaadin/server/LegacyVaadinPortlet.java b/server/src/com/vaadin/server/LegacyVaadinPortlet.java
index 6aa8fb7165..de970d5c17 100644
--- a/server/src/com/vaadin/server/LegacyVaadinPortlet.java
+++ b/server/src/com/vaadin/server/LegacyVaadinPortlet.java
@@ -54,7 +54,7 @@ public class LegacyVaadinPortlet extends VaadinPortlet {
VaadinSessionInitializeEvent event)
throws ServiceException {
try {
- onVaadinSessionStarted(WrappedPortletRequest
+ onVaadinSessionStarted(VaadinPortletRequest
.cast(event.getRequest()),
(VaadinPortletSession) event
.getVaadinSession());
@@ -85,7 +85,7 @@ public class LegacyVaadinPortlet extends VaadinPortlet {
}
}
- private void onVaadinSessionStarted(WrappedPortletRequest request,
+ private void onVaadinSessionStarted(VaadinPortletRequest request,
VaadinPortletSession session) throws PortletException {
session.addUIProvider(provider);
}
diff --git a/server/src/com/vaadin/server/LegacyVaadinServlet.java b/server/src/com/vaadin/server/LegacyVaadinServlet.java
index ace29e9e1f..69655eba34 100644
--- a/server/src/com/vaadin/server/LegacyVaadinServlet.java
+++ b/server/src/com/vaadin/server/LegacyVaadinServlet.java
@@ -90,7 +90,7 @@ public class LegacyVaadinServlet extends VaadinServlet {
return true;
}
- private void onVaadinSessionStarted(WrappedRequest wrappedRequest,
+ private void onVaadinSessionStarted(VaadinRequest request,
VaadinSession session) throws ServletException {
session.addUIProvider(provider);
}
diff --git a/server/src/com/vaadin/server/Page.java b/server/src/com/vaadin/server/Page.java
index bfbfe53429..e17643eb81 100644
--- a/server/src/com/vaadin/server/Page.java
+++ b/server/src/com/vaadin/server/Page.java
@@ -24,7 +24,7 @@ import java.util.LinkedList;
import java.util.List;
import com.vaadin.event.EventRouter;
-import com.vaadin.server.WrappedRequest.BrowserDetails;
+import com.vaadin.server.VaadinRequest.BrowserDetails;
import com.vaadin.shared.ui.BorderStyle;
import com.vaadin.shared.ui.ui.PageClientRpc;
import com.vaadin.shared.ui.ui.UIConstants;
@@ -404,7 +404,7 @@ public class Page implements Serializable {
return fragment;
}
- public void init(WrappedRequest request) {
+ public void init(VaadinRequest request) {
BrowserDetails browserDetails = request.getBrowserDetails();
if (browserDetails != null) {
fragment = browserDetails.getUriFragment();
diff --git a/server/src/com/vaadin/server/PortletCommunicationManager.java b/server/src/com/vaadin/server/PortletCommunicationManager.java
index c307c50348..449d39b38b 100644
--- a/server/src/com/vaadin/server/PortletCommunicationManager.java
+++ b/server/src/com/vaadin/server/PortletCommunicationManager.java
@@ -53,9 +53,9 @@ public class PortletCommunicationManager extends AbstractCommunicationManager {
return new BootstrapHandler() {
@Override
public boolean handleRequest(VaadinSession session,
- WrappedRequest request, WrappedResponse response)
+ VaadinRequest request, VaadinResponse response)
throws IOException {
- PortletRequest portletRequest = WrappedPortletRequest.cast(
+ PortletRequest portletRequest = VaadinPortletRequest.cast(
request).getPortletRequest();
if (portletRequest instanceof RenderRequest) {
return super.handleRequest(session, request, response);
@@ -66,7 +66,7 @@ public class PortletCommunicationManager extends AbstractCommunicationManager {
@Override
protected String getApplicationId(BootstrapContext context) {
- PortletRequest portletRequest = WrappedPortletRequest.cast(
+ PortletRequest portletRequest = VaadinPortletRequest.cast(
context.getRequest()).getPortletRequest();
/*
* We need to generate a unique ID because some portals already
@@ -81,7 +81,7 @@ public class PortletCommunicationManager extends AbstractCommunicationManager {
}
private RenderResponse getRenderResponse(BootstrapContext context) {
- PortletResponse response = ((WrappedPortletResponse) context
+ PortletResponse response = ((VaadinPortletResponse) context
.getResponse()).getPortletResponse();
RenderResponse renderResponse = (RenderResponse) response;
@@ -115,7 +115,7 @@ public class PortletCommunicationManager extends AbstractCommunicationManager {
throws JSONException, IOException {
// fixed base theme to use - all portal pages with Vaadin
// applications will load this exactly once
- String portalTheme = WrappedPortletRequest.cast(
+ String portalTheme = VaadinPortletRequest.cast(
context.getRequest()).getPortalProperty(
VaadinPortlet.PORTAL_PARAMETER_VAADIN_THEME);
if (portalTheme != null
@@ -143,9 +143,9 @@ public class PortletCommunicationManager extends AbstractCommunicationManager {
BootstrapContext context) throws JSONException,
PaintException {
JSONObject parameters = super.getApplicationParameters(context);
- WrappedPortletResponse wrappedPortletResponse = (WrappedPortletResponse) context
+ VaadinPortletResponse response = (VaadinPortletResponse) context
.getResponse();
- MimeResponse portletResponse = (MimeResponse) wrappedPortletResponse
+ MimeResponse portletResponse = (MimeResponse) response
.getPortletResponse();
ResourceURL resourceURL = portletResponse.createResourceURL();
resourceURL.setResourceID("browserDetails");
diff --git a/server/src/com/vaadin/server/RequestHandler.java b/server/src/com/vaadin/server/RequestHandler.java
index c2409af2d7..8eb2d6d746 100644
--- a/server/src/com/vaadin/server/RequestHandler.java
+++ b/server/src/com/vaadin/server/RequestHandler.java
@@ -41,7 +41,7 @@ public interface RequestHandler extends Serializable {
* handlers should be called, otherwise false
* @throws IOException
*/
- boolean handleRequest(VaadinSession session, WrappedRequest request,
- WrappedResponse response) throws IOException;
+ boolean handleRequest(VaadinSession session, VaadinRequest request,
+ VaadinResponse response) throws IOException;
}
diff --git a/server/src/com/vaadin/server/ServletPortletHelper.java b/server/src/com/vaadin/server/ServletPortletHelper.java
index 6b686c59c3..536af12239 100644
--- a/server/src/com/vaadin/server/ServletPortletHelper.java
+++ b/server/src/com/vaadin/server/ServletPortletHelper.java
@@ -77,7 +77,7 @@ class ServletPortletHelper implements Serializable {
}
}
- private static boolean hasPathPrefix(WrappedRequest request, String prefix) {
+ private static boolean hasPathPrefix(VaadinRequest request, String prefix) {
String pathInfo = request.getRequestPathInfo();
if (pathInfo == null) {
@@ -95,24 +95,24 @@ class ServletPortletHelper implements Serializable {
return false;
}
- public static boolean isFileUploadRequest(WrappedRequest request) {
+ public static boolean isFileUploadRequest(VaadinRequest request) {
return hasPathPrefix(request, UPLOAD_URL_PREFIX);
}
- public static boolean isConnectorResourceRequest(WrappedRequest request) {
+ public static boolean isConnectorResourceRequest(VaadinRequest request) {
return hasPathPrefix(request,
ApplicationConstants.CONNECTOR_RESOURCE_PREFIX + "/");
}
- public static boolean isUIDLRequest(WrappedRequest request) {
+ public static boolean isUIDLRequest(VaadinRequest request) {
return hasPathPrefix(request, ApplicationConstants.UIDL_REQUEST_PATH);
}
- public static boolean isAppRequest(WrappedRequest request) {
+ public static boolean isAppRequest(VaadinRequest request) {
return hasPathPrefix(request, ApplicationConstants.APP_REQUEST_PATH);
}
- public static boolean isHeartbeatRequest(WrappedRequest request) {
+ public static boolean isHeartbeatRequest(VaadinRequest request) {
return hasPathPrefix(request,
ApplicationConstants.HEARTBEAT_REQUEST_PATH);
}
diff --git a/server/src/com/vaadin/server/UIProvider.java b/server/src/com/vaadin/server/UIProvider.java
index a15a50a42a..81a53fae15 100644
--- a/server/src/com/vaadin/server/UIProvider.java
+++ b/server/src/com/vaadin/server/UIProvider.java
@@ -20,12 +20,11 @@ import com.vaadin.annotations.Widgetset;
import com.vaadin.ui.UI;
public interface UIProvider {
- public Class<? extends UI> getUIClass(WrappedRequest request);
+ public Class<? extends UI> getUIClass(VaadinRequest request);
- public UI createInstance(WrappedRequest request,
- Class<? extends UI> type);
+ public UI createInstance(VaadinRequest request, Class<? extends UI> type);
- public String getPageTitle(WrappedRequest request,
+ public String getPageTitle(VaadinRequest request,
Class<? extends UI> uiClass);
/**
@@ -40,7 +39,7 @@ public interface UIProvider {
* @return <code>true</code>if the same UI instance should be reused e.g.
* when the browser window is refreshed.
*/
- public boolean isPreservedOnRefresh(WrappedRequest request,
+ public boolean isPreservedOnRefresh(VaadinRequest request,
Class<? extends UI> uiClass);
/**
@@ -51,14 +50,14 @@ public interface UIProvider {
* defined for the UI class.
*
* @param request
- * the wrapped request for which to get a widgetset
+ * the Vaadin request for which to get a widgetset
* @param uiClass
* the UI class to get a widgetset for
* @return the name of the widgetset, or <code>null</code> if the default
* widgetset should be used
*
*/
- public String getWidgetset(WrappedRequest request,
+ public String getWidgetset(VaadinRequest request,
Class<? extends UI> uiClass);
/**
@@ -73,8 +72,7 @@ public interface UIProvider {
* should be used
*
*/
- public String getTheme(WrappedRequest request,
- Class<? extends UI> uiClass);
+ public String getTheme(VaadinRequest request, Class<? extends UI> uiClass);
/**
* Finds an existing {@link UI} for a request.
@@ -85,14 +83,14 @@ public interface UIProvider {
* <p>
* If no UI provider returns an existing UI, the framework does also check
* the window.name for an existing instance with
- * {@link #isPreservedOnRefresh(WrappedRequest, Class)} before falling back to
- * bootstrapping and creating a new UI instance.
+ * {@link #isPreservedOnRefresh(VaadinRequest, Class)} before falling back
+ * to bootstrapping and creating a new UI instance.
*
* @param request
* the request for which a UI is desired
* @return a UI belonging to the request, or <code>null</code> if this UI
* provider doesn't have an existing UI for the request.
*/
- public UI getExistingUI(WrappedRequest request);
+ public UI getExistingUI(VaadinRequest request);
}
diff --git a/server/src/com/vaadin/server/UnsupportedBrowserHandler.java b/server/src/com/vaadin/server/UnsupportedBrowserHandler.java
index 38ac14b2d2..8525dc29ca 100644
--- a/server/src/com/vaadin/server/UnsupportedBrowserHandler.java
+++ b/server/src/com/vaadin/server/UnsupportedBrowserHandler.java
@@ -35,7 +35,7 @@ public class UnsupportedBrowserHandler implements RequestHandler {
@Override
public boolean handleRequest(VaadinSession session,
- WrappedRequest request, WrappedResponse response)
+ VaadinRequest request, VaadinResponse response)
throws IOException {
if (request.getBrowserDetails() != null) {
@@ -62,8 +62,8 @@ public class UnsupportedBrowserHandler implements RequestHandler {
* @param response
* @throws IOException
*/
- protected void writeBrowserTooOldPage(WrappedRequest request,
- WrappedResponse response) throws IOException {
+ protected void writeBrowserTooOldPage(VaadinRequest request,
+ VaadinResponse response) throws IOException {
Writer page = response.getWriter();
WebBrowser b = request.getBrowserDetails().getWebBrowser();
diff --git a/server/src/com/vaadin/server/VaadinPortlet.java b/server/src/com/vaadin/server/VaadinPortlet.java
index 2027431f0b..83d152d653 100644
--- a/server/src/com/vaadin/server/VaadinPortlet.java
+++ b/server/src/com/vaadin/server/VaadinPortlet.java
@@ -88,7 +88,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
@Override
- public String getConfiguredWidgetset(WrappedRequest request) {
+ public String getConfiguredWidgetset(VaadinRequest request) {
String widgetset = getDeploymentConfiguration()
.getApplicationOrSystemProperty(PARAMETER_WIDGETSET, null);
@@ -96,7 +96,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
if (widgetset == null) {
// If no widgetset defined for the application, check the
// portal property
- widgetset = WrappedPortletRequest.cast(request)
+ widgetset = VaadinPortletRequest.cast(request)
.getPortalProperty(PORTAL_PARAMETER_VAADIN_WIDGETSET);
}
@@ -109,10 +109,10 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
@Override
- public String getConfiguredTheme(WrappedRequest request) {
+ public String getConfiguredTheme(VaadinRequest request) {
// is the default theme defined by the portal?
- String themeName = WrappedPortletRequest.cast(request)
+ String themeName = VaadinPortletRequest.cast(request)
.getPortalProperty(Constants.PORTAL_PARAMETER_VAADIN_THEME);
if (themeName == null) {
@@ -124,13 +124,13 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
@Override
- public boolean isStandalone(WrappedRequest request) {
+ public boolean isStandalone(VaadinRequest request) {
return false;
}
@Override
- public String getStaticFileLocation(WrappedRequest request) {
- String staticFileLocation = WrappedPortletRequest.cast(request)
+ public String getStaticFileLocation(VaadinRequest request) {
+ String staticFileLocation = VaadinPortletRequest.cast(request)
.getPortalProperty(
Constants.PORTAL_PARAMETER_VAADIN_RESOURCE_PATH);
if (staticFileLocation != null) {
@@ -179,7 +179,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
@Override
- protected boolean requestCanCreateSession(WrappedRequest request) {
+ protected boolean requestCanCreateSession(VaadinRequest request) {
RequestType requestType = getRequestType(request);
if (requestType == RequestType.RENDER) {
// In most cases the first request is a render request that
@@ -205,12 +205,12 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- protected RequestType getRequestType(WrappedRequest request) {
+ protected RequestType getRequestType(VaadinRequest request) {
RequestType type = (RequestType) request
.getAttribute(RequestType.class.getName());
if (type == null) {
type = getPortlet().getRequestType(
- WrappedPortletRequest.cast(request));
+ VaadinPortletRequest.cast(request));
request.setAttribute(RequestType.class.getName(), type);
}
return type;
@@ -223,9 +223,9 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
public static PortletRequest getCurrentPortletRequest() {
- WrappedRequest currentRequest = VaadinService.getCurrentRequest();
+ VaadinRequest currentRequest = VaadinService.getCurrentRequest();
try {
- WrappedPortletRequest request = WrappedPortletRequest
+ VaadinPortletRequest request = VaadinPortletRequest
.cast(currentRequest);
if (request != null) {
return request.getPortletRequest();
@@ -237,21 +237,21 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
}
- public static WrappedPortletResponse getCurrentResponse() {
- return (WrappedPortletResponse) VaadinService.getCurrentResponse();
+ public static VaadinPortletResponse getCurrentResponse() {
+ return (VaadinPortletResponse) VaadinService.getCurrentResponse();
}
@Override
- protected VaadinSession createVaadinSession(WrappedRequest request)
+ protected VaadinSession createVaadinSession(VaadinRequest request)
throws ServiceException {
return new VaadinPortletSession();
}
}
- public static class WrappedHttpAndPortletRequest extends
- WrappedPortletRequest {
+ public static class VaadinHttpAndPortletRequest extends
+ VaadinPortletRequest {
- public WrappedHttpAndPortletRequest(PortletRequest request,
+ public VaadinHttpAndPortletRequest(PortletRequest request,
HttpServletRequest originalRequest, PortletService vaadinService) {
super(request, vaadinService);
this.originalRequest = originalRequest;
@@ -292,9 +292,8 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
}
- public static class WrappedGateinRequest extends
- WrappedHttpAndPortletRequest {
- public WrappedGateinRequest(PortletRequest request,
+ public static class VaadinGateinRequest extends VaadinHttpAndPortletRequest {
+ public VaadinGateinRequest(PortletRequest request,
PortletService vaadinService) {
super(request, getOriginalRequest(request), vaadinService);
}
@@ -314,10 +313,10 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
}
- public static class WrappedLiferayRequest extends
- WrappedHttpAndPortletRequest {
+ public static class VaadinLiferayRequest extends
+ VaadinHttpAndPortletRequest {
- public WrappedLiferayRequest(PortletRequest request,
+ public VaadinLiferayRequest(PortletRequest request,
PortletService vaadinService) {
super(request, getOriginalRequest(request), vaadinService);
}
@@ -358,11 +357,11 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
@Override
- public void criticalNotification(WrappedRequest request,
- WrappedResponse response, String cap, String msg,
+ public void criticalNotification(VaadinRequest request,
+ VaadinResponse response, String cap, String msg,
String details, String outOfSyncURL) throws IOException {
- portlet.criticalNotification(WrappedPortletRequest.cast(request),
- (WrappedPortletResponse) response, cap, msg, details,
+ portlet.criticalNotification(VaadinPortletRequest.cast(request),
+ (VaadinPortletResponse) response, cap, msg, details,
outOfSyncURL);
}
}
@@ -465,30 +464,30 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
/**
- * @param wrappedRequest
+ * @param vaadinRequest
* @return
*
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- protected RequestType getRequestType(WrappedPortletRequest wrappedRequest) {
- PortletRequest request = wrappedRequest.getPortletRequest();
+ protected RequestType getRequestType(VaadinPortletRequest vaadinRequest) {
+ PortletRequest request = vaadinRequest.getPortletRequest();
if (request instanceof RenderRequest) {
return RequestType.RENDER;
} else if (request instanceof ResourceRequest) {
ResourceRequest resourceRequest = (ResourceRequest) request;
- if (ServletPortletHelper.isUIDLRequest(wrappedRequest)) {
+ if (ServletPortletHelper.isUIDLRequest(vaadinRequest)) {
return RequestType.UIDL;
} else if (isBrowserDetailsRequest(resourceRequest)) {
return RequestType.BROWSER_DETAILS;
- } else if (ServletPortletHelper.isFileUploadRequest(wrappedRequest)) {
+ } else if (ServletPortletHelper.isFileUploadRequest(vaadinRequest)) {
return RequestType.FILE_UPLOAD;
} else if (ServletPortletHelper
- .isConnectorResourceRequest(wrappedRequest)) {
+ .isConnectorResourceRequest(vaadinRequest)) {
return RequestType.CONNECTOR_RESOURCE;
- } else if (ServletPortletHelper.isAppRequest(wrappedRequest)) {
+ } else if (ServletPortletHelper.isAppRequest(vaadinRequest)) {
return RequestType.APP;
- } else if (ServletPortletHelper.isHeartbeatRequest(wrappedRequest)) {
+ } else if (ServletPortletHelper.isHeartbeatRequest(vaadinRequest)) {
return RequestType.HEARTBEAT;
} else if (isDummyRequest(resourceRequest)) {
return RequestType.DUMMY;
@@ -534,15 +533,15 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
AbstractApplicationPortletWrapper portletWrapper = new AbstractApplicationPortletWrapper(
this);
- WrappedPortletRequest wrappedRequest = createWrappedRequest(request);
+ VaadinPortletRequest vaadinRequest = createVaadinRequest(request);
- WrappedPortletResponse wrappedResponse = new WrappedPortletResponse(
+ VaadinPortletResponse vaadinResponse = new VaadinPortletResponse(
response, getVaadinService());
- getVaadinService().setCurrentInstances(wrappedRequest,
- wrappedResponse);
+ getVaadinService().setCurrentInstances(vaadinRequest,
+ vaadinResponse);
- RequestType requestType = getRequestType(wrappedRequest);
+ RequestType requestType = getRequestType(vaadinRequest);
if (requestType == RequestType.UNKNOWN) {
handleUnknownRequest(request, response);
@@ -571,7 +570,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
// redirectToApplication??
vaadinSession = (VaadinPortletSession) getVaadinService()
- .findVaadinSession(wrappedRequest);
+ .findVaadinSession(vaadinRequest);
if (vaadinSession == null) {
return;
}
@@ -584,17 +583,17 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
if (requestType == RequestType.CONNECTOR_RESOURCE) {
communicationManager.serveConnectorResource(
- wrappedRequest, wrappedResponse);
+ vaadinRequest, vaadinResponse);
return;
} else if (requestType == RequestType.HEARTBEAT) {
communicationManager.handleHeartbeatRequest(
- wrappedRequest, wrappedResponse, vaadinSession);
+ vaadinRequest, vaadinResponse, vaadinSession);
return;
}
/* Update browser information from request */
vaadinSession.getBrowser().updateRequestDetails(
- wrappedRequest);
+ vaadinRequest);
sessionProcessed = true;
@@ -610,7 +609,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
// Both action requests and render requests are ok
// without a UI as they render the initial HTML
// and then do a second request
- uI = vaadinSession.getUIForRequest(wrappedRequest);
+ uI = vaadinSession.getUIForRequest(vaadinRequest);
break;
case BROWSER_DETAILS:
// Should not try to find a UI here as the
@@ -623,7 +622,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
// Not related to any UI
break;
default:
- uI = vaadinSession.getUIForRequest(wrappedRequest);
+ uI = vaadinSession.getUIForRequest(vaadinRequest);
}
// if window not found, not a problem - use null
} finally {
@@ -655,19 +654,19 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
// UI is resolved in handleFileUpload by
// PortletCommunicationManager
communicationManager.handleFileUpload(vaadinSession,
- wrappedRequest, wrappedResponse);
+ vaadinRequest, vaadinResponse);
return;
} else if (requestType == RequestType.BROWSER_DETAILS) {
communicationManager.handleBrowserDetailsRequest(
- wrappedRequest, wrappedResponse, vaadinSession);
+ vaadinRequest, vaadinResponse, vaadinSession);
return;
} else if (requestType == RequestType.UIDL) {
// Handles AJAX UIDL requests
- communicationManager.handleUidlRequest(wrappedRequest,
- wrappedResponse, portletWrapper, uI);
+ communicationManager.handleUidlRequest(vaadinRequest,
+ vaadinResponse, portletWrapper, uI);
return;
} else {
- handleOtherRequest(wrappedRequest, wrappedResponse,
+ handleOtherRequest(vaadinRequest, vaadinResponse,
requestType, vaadinSession,
communicationManager);
}
@@ -681,7 +680,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
getLogger()
.fine("General security exception, the security key was probably incorrect.");
} catch (final Throwable e) {
- handleServiceException(wrappedRequest, wrappedResponse,
+ handleServiceException(vaadinRequest, vaadinResponse,
vaadinSession, e);
} finally {
@@ -700,22 +699,21 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
}
/**
- * Wraps the request in a (possibly portal specific) wrapped portlet
- * request.
+ * Wraps the request in a (possibly portal specific) Vaadin portlet request.
*
* @param request
* The original PortletRequest
* @return A wrapped version of the PorletRequest
*/
- protected WrappedPortletRequest createWrappedRequest(PortletRequest request) {
+ protected VaadinPortletRequest createVaadinRequest(PortletRequest request) {
String portalInfo = request.getPortalContext().getPortalInfo()
.toLowerCase();
if (portalInfo.contains("liferay")) {
- return new WrappedLiferayRequest(request, getVaadinService());
+ return new VaadinLiferayRequest(request, getVaadinService());
} else if (portalInfo.contains("gatein")) {
- return new WrappedGateinRequest(request, getVaadinService());
+ return new VaadinGateinRequest(request, getVaadinService());
} else {
- return new WrappedPortletRequest(request, getVaadinService());
+ return new VaadinPortletRequest(request, getVaadinService());
}
}
@@ -746,8 +744,8 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
* @throws IOException
* @throws MalformedURLException
*/
- private void handleOtherRequest(WrappedPortletRequest request,
- WrappedResponse response, RequestType requestType,
+ private void handleOtherRequest(VaadinPortletRequest request,
+ VaadinResponse response, RequestType requestType,
VaadinSession vaadinSession,
PortletCommunicationManager communicationManager)
throws PortletException, IOException, MalformedURLException {
@@ -832,8 +830,8 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
handleRequest(request, response);
}
- private void handleServiceException(WrappedPortletRequest request,
- WrappedPortletResponse response, VaadinSession vaadinSession,
+ private void handleServiceException(VaadinPortletRequest request,
+ VaadinPortletResponse response, VaadinSession vaadinSession,
Throwable e) throws IOException, PortletException {
// TODO Check that this error handler is working when running inside a
// portlet
@@ -898,8 +896,8 @@ public class VaadinPortlet extends GenericPortlet implements Constants {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- void criticalNotification(WrappedPortletRequest request,
- WrappedPortletResponse response, String caption, String message,
+ void criticalNotification(VaadinPortletRequest request,
+ VaadinPortletResponse response, String caption, String message,
String details, String url) throws IOException {
// clients JS app is still running, but server application either
diff --git a/server/src/com/vaadin/server/WrappedPortletRequest.java b/server/src/com/vaadin/server/VaadinPortletRequest.java
index d4670cfd92..b0a16d01a4 100644
--- a/server/src/com/vaadin/server/WrappedPortletRequest.java
+++ b/server/src/com/vaadin/server/VaadinPortletRequest.java
@@ -35,10 +35,10 @@ import com.vaadin.shared.ApplicationConstants;
* @author Vaadin Ltd.
* @since 7.0
*
- * @see WrappedRequest
- * @see WrappedPortletResponse
+ * @see VaadinRequest
+ * @see VaadinPortletResponse
*/
-public class WrappedPortletRequest implements WrappedRequest {
+public class VaadinPortletRequest implements VaadinRequest {
private final PortletRequest request;
private final PortletService vaadinService;
@@ -51,7 +51,7 @@ public class WrappedPortletRequest implements WrappedRequest {
* @param vaadinService
* the associated vaadin service
*/
- public WrappedPortletRequest(PortletRequest request,
+ public VaadinPortletRequest(PortletRequest request,
PortletService vaadinService) {
this.request = request;
this.vaadinService = vaadinService;
@@ -191,7 +191,7 @@ public class WrappedPortletRequest implements WrappedRequest {
}
/**
- * Reads a portal property from the portal context of the wrapped request.
+ * Reads a portal property from the portal context of the Vaadin request.
*
* @param name
* a string with the name of the portal property to get
@@ -208,21 +208,21 @@ public class WrappedPortletRequest implements WrappedRequest {
}
/**
- * Helper method to get a <code>WrappedPortlettRequest</code> from a
- * <code>WrappedRequest</code>. Aside from casting, this method also takes
- * care of situations where there's another level of wrapping.
+ * Helper method to get a {@link VaadinPortletRequest} from a
+ * {@link VaadinRequest}. Aside from casting, this method also takes care of
+ * situations where there's another level of wrapping.
*
* @param request
- * a wrapped request
- * @return a wrapped portlet request
+ * a Vaadin request
+ * @return a Vaadin portlet request
* @throws ClassCastException
- * if the wrapped request doesn't wrap a portlet request
+ * if the Vaadin request doesn't wrap a portlet request
*/
- public static WrappedPortletRequest cast(WrappedRequest request) {
+ public static VaadinPortletRequest cast(VaadinRequest request) {
if (request instanceof CombinedRequest) {
CombinedRequest combinedRequest = (CombinedRequest) request;
request = combinedRequest.getSecondRequest();
}
- return (WrappedPortletRequest) request;
+ return (VaadinPortletRequest) request;
}
}
diff --git a/server/src/com/vaadin/server/WrappedPortletResponse.java b/server/src/com/vaadin/server/VaadinPortletResponse.java
index 5888c33b43..5ca1ba580e 100644
--- a/server/src/com/vaadin/server/WrappedPortletResponse.java
+++ b/server/src/com/vaadin/server/VaadinPortletResponse.java
@@ -37,10 +37,10 @@ import com.vaadin.server.VaadinPortlet.PortletService;
* @author Vaadin Ltd.
* @since 7.0
*
- * @see WrappedResponse
- * @see WrappedPortletRequest
+ * @see VaadinResponse
+ * @see VaadinPortletRequest
*/
-public class WrappedPortletResponse implements WrappedResponse {
+public class VaadinPortletResponse implements VaadinResponse {
private static final DateFormat HTTP_DATE_FORMAT = new SimpleDateFormat(
"EEE, dd MMM yyyy HH:mm:ss zzz", Locale.ENGLISH);
static {
@@ -58,7 +58,7 @@ public class WrappedPortletResponse implements WrappedResponse {
* @param vaadinService
* the associated vaadin service
*/
- public WrappedPortletResponse(PortletResponse response,
+ public VaadinPortletResponse(PortletResponse response,
PortletService vaadinService) {
this.response = response;
this.vaadinService = vaadinService;
@@ -106,7 +106,7 @@ public class WrappedPortletResponse implements WrappedResponse {
@Override
public void setCacheTime(long milliseconds) {
- WrappedHttpServletResponse.doSetCacheTime(this, milliseconds);
+ VaadinServletResponse.doSetCacheTime(this, milliseconds);
}
@Override
diff --git a/server/src/com/vaadin/server/VaadinPortletSession.java b/server/src/com/vaadin/server/VaadinPortletSession.java
index bb37bbbcf3..e5b512588d 100644
--- a/server/src/com/vaadin/server/VaadinPortletSession.java
+++ b/server/src/com/vaadin/server/VaadinPortletSession.java
@@ -74,8 +74,8 @@ public class VaadinPortletSession extends VaadinSession {
}
private PortletResponse getCurrentResponse() {
- WrappedPortletResponse currentResponse = (WrappedPortletResponse) CurrentInstance
- .get(WrappedResponse.class);
+ VaadinPortletResponse currentResponse = (VaadinPortletResponse) CurrentInstance
+ .get(VaadinResponse.class);
if (currentResponse != null) {
return currentResponse.getPortletResponse();
@@ -85,8 +85,8 @@ public class VaadinPortletSession extends VaadinSession {
}
public PortletConfig getPortletConfig() {
- WrappedPortletResponse response = (WrappedPortletResponse) CurrentInstance
- .get(WrappedResponse.class);
+ VaadinPortletResponse response = (VaadinPortletResponse) CurrentInstance
+ .get(VaadinResponse.class);
return response.getVaadinService().getPortlet().getPortletConfig();
}
diff --git a/server/src/com/vaadin/server/WrappedRequest.java b/server/src/com/vaadin/server/VaadinRequest.java
index aeaff2b384..0664d53f65 100644
--- a/server/src/com/vaadin/server/WrappedRequest.java
+++ b/server/src/com/vaadin/server/VaadinRequest.java
@@ -35,12 +35,12 @@ import com.vaadin.ui.UI;
* @author Vaadin Ltd
* @since 7.0.0
*/
-public interface WrappedRequest extends Serializable {
+public interface VaadinRequest extends Serializable {
/**
* Detailed information extracted from the browser.
*
- * @see WrappedRequest#getBrowserDetails()
+ * @see VaadinRequest#getBrowserDetails()
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
@@ -209,7 +209,7 @@ public interface WrappedRequest extends Serializable {
* for instance using javascript in the browser.
*
* This information is only guaranteed to be available in some special
- * cases, for instance in {@link UI#init(WrappedRequest)}.
+ * cases, for instance in {@link UI#init(VaadinRequest)}.
*
* @return the browser details, or <code>null</code> if details are not
* available
diff --git a/server/src/com/vaadin/server/WrappedResponse.java b/server/src/com/vaadin/server/VaadinResponse.java
index 90c9a356e1..bfa36015a3 100644
--- a/server/src/com/vaadin/server/WrappedResponse.java
+++ b/server/src/com/vaadin/server/VaadinResponse.java
@@ -33,7 +33,7 @@ import javax.servlet.http.HttpServletResponse;
*
* @since 7.0
*/
-public interface WrappedResponse extends Serializable {
+public interface VaadinResponse extends Serializable {
/**
* Sets the (http) status code for the response. If you want to include an
diff --git a/server/src/com/vaadin/server/VaadinService.java b/server/src/com/vaadin/server/VaadinService.java
index 4b176d5f67..766ae47fdb 100644
--- a/server/src/com/vaadin/server/VaadinService.java
+++ b/server/src/com/vaadin/server/VaadinService.java
@@ -97,7 +97,7 @@ public abstract class VaadinService implements Serializable {
* @return The location of static resources (should contain the VAADIN
* directory). Never ends with a slash (/).
*/
- public abstract String getStaticFileLocation(WrappedRequest request);
+ public abstract String getStaticFileLocation(VaadinRequest request);
/**
* Gets the widgetset that is configured for this deployment, e.g. from a
@@ -107,7 +107,7 @@ public abstract class VaadinService implements Serializable {
* the request for which a widgetset is required
* @return the name of the widgetset
*/
- public abstract String getConfiguredWidgetset(WrappedRequest request);
+ public abstract String getConfiguredWidgetset(VaadinRequest request);
/**
* Gets the theme that is configured for this deployment, e.g. from a portal
@@ -117,7 +117,7 @@ public abstract class VaadinService implements Serializable {
* the request for which a theme is required
* @return the name of the theme
*/
- public abstract String getConfiguredTheme(WrappedRequest request);
+ public abstract String getConfiguredTheme(VaadinRequest request);
/**
* Checks whether the UI will be rendered on its own in the browser or
@@ -129,7 +129,7 @@ public abstract class VaadinService implements Serializable {
* the request for which the UI is loaded
* @return a boolean indicating whether the UI should be standalone
*/
- public abstract boolean isStandalone(WrappedRequest request);
+ public abstract boolean isStandalone(VaadinRequest request);
/**
* Get the class loader to use for loading classes loaded by name, e.g.
@@ -307,7 +307,7 @@ public abstract class VaadinService implements Serializable {
* session is found and this is a request for which a new session
* shouldn't be created.
*/
- public VaadinSession findVaadinSession(WrappedRequest request)
+ public VaadinSession findVaadinSession(VaadinRequest request)
throws ServiceException, SessionExpiredException {
boolean requestCanCreateSession = requestCanCreateSession(request);
@@ -356,7 +356,7 @@ public abstract class VaadinService implements Serializable {
}
- private VaadinSession createAndRegisterSession(WrappedRequest request)
+ private VaadinSession createAndRegisterSession(VaadinRequest request)
throws ServiceException {
VaadinSession session = createVaadinSession(request);
@@ -397,7 +397,7 @@ public abstract class VaadinService implements Serializable {
* @deprecated Only used to support {@link LegacyApplication}.
*/
@Deprecated
- protected URL getApplicationUrl(WrappedRequest request)
+ protected URL getApplicationUrl(VaadinRequest request)
throws MalformedURLException {
return null;
}
@@ -421,10 +421,10 @@ public abstract class VaadinService implements Serializable {
* @throws ServletException
* @throws MalformedURLException
*/
- protected abstract VaadinSession createVaadinSession(WrappedRequest request)
+ protected abstract VaadinSession createVaadinSession(VaadinRequest request)
throws ServiceException;
- private void onVaadinSessionStarted(WrappedRequest request,
+ private void onVaadinSessionStarted(VaadinRequest request,
VaadinSession session) throws ServiceException {
addonContext.fireApplicationStarted(session);
eventRouter.fireEvent(new VaadinSessionInitializeEvent(this, session,
@@ -444,7 +444,7 @@ public abstract class VaadinService implements Serializable {
}
}
- protected VaadinSession getExistingSession(WrappedRequest request,
+ protected VaadinSession getExistingSession(VaadinRequest request,
boolean allowSessionCreation) throws SessionExpiredException {
// Ensures that the session is still valid
@@ -472,7 +472,7 @@ public abstract class VaadinService implements Serializable {
* @return <code>true</code> if it's valid to create a new Vaadin session
* for the request; else <code>false</code>
*/
- protected abstract boolean requestCanCreateSession(WrappedRequest request);
+ protected abstract boolean requestCanCreateSession(VaadinRequest request);
/**
* Gets the currently used Vaadin service. The current service is
@@ -485,7 +485,7 @@ public abstract class VaadinService implements Serializable {
* @return the current Vaadin service instance if available, otherwise
* <code>null</code>
*
- * @see #setCurrentInstances(WrappedRequest, WrappedResponse)
+ * @see #setCurrentInstances(VaadinRequest, VaadinResponse)
*/
public static VaadinService getCurrent() {
return CurrentInstance.get(VaadinService.class);
@@ -493,7 +493,7 @@ public abstract class VaadinService implements Serializable {
/**
* Sets the this Vaadin service as the current service and also sets the
- * current wrapped request and wrapped response. This method is used by the
+ * current Vaadin request and Vaadin response. This method is used by the
* framework to set the current instances when a request related to the
* service is processed and they are cleared when the request has been
* processed.
@@ -504,51 +504,51 @@ public abstract class VaadinService implements Serializable {
* </p>
*
* @param request
- * the wrapped request to set as the current request, or
+ * the Vaadin request to set as the current request, or
* <code>null</code> if no request should be set.
* @param response
- * the wrapped response to set as the current response, or
+ * the Vaadin response to set as the current response, or
* <code>null</code> if no response should be set.
*
* @see #getCurrent()
* @see #getCurrentRequest()
* @see #getCurrentResponse()
*/
- public void setCurrentInstances(WrappedRequest request,
- WrappedResponse response) {
+ public void setCurrentInstances(VaadinRequest request,
+ VaadinResponse response) {
CurrentInstance.setInheritable(VaadinService.class, this);
- CurrentInstance.set(WrappedRequest.class, request);
- CurrentInstance.set(WrappedResponse.class, response);
+ CurrentInstance.set(VaadinRequest.class, request);
+ CurrentInstance.set(VaadinResponse.class, response);
}
/**
- * Gets the currently processed wrapped request. The current request is
+ * Gets the currently processed Vaadin request. The current request is
* automatically defined when the request is started. The current request
* can not be used in e.g. background threads because of the way server
* implementations reuse request instances.
*
- * @return the current wrapped request instance if available, otherwise
+ * @return the current Vaadin request instance if available, otherwise
* <code>null</code>
*
- * @see #setCurrentInstances(WrappedRequest, WrappedResponse)
+ * @see #setCurrentInstances(VaadinRequest, VaadinResponse)
*/
- public static WrappedRequest getCurrentRequest() {
- return CurrentInstance.get(WrappedRequest.class);
+ public static VaadinRequest getCurrentRequest() {
+ return CurrentInstance.get(VaadinRequest.class);
}
/**
- * Gets the currently processed wrapped request. The current request is
+ * Gets the currently processed Vaadin request. The current request is
* automatically defined when the request is started. The current request
* can not be used in e.g. background threads because of the way server
* implementations reuse request instances.
*
- * @return the current wrapped request instance if available, otherwise
+ * @return the current Vaadin request instance if available, otherwise
* <code>null</code>
*
- * @see #setCurrentInstances(WrappedRequest, WrappedResponse)
+ * @see #setCurrentInstances(VaadinRequest, VaadinResponse)
*/
- public static WrappedResponse getCurrentResponse() {
- return CurrentInstance.get(WrappedResponse.class);
+ public static VaadinResponse getCurrentResponse() {
+ return CurrentInstance.get(VaadinResponse.class);
}
}
diff --git a/server/src/com/vaadin/server/VaadinServlet.java b/server/src/com/vaadin/server/VaadinServlet.java
index 54709b41d1..518d26070b 100644
--- a/server/src/com/vaadin/server/VaadinServlet.java
+++ b/server/src/com/vaadin/server/VaadinServlet.java
@@ -66,8 +66,8 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
@Override
- public String getStaticFileLocation(WrappedRequest request) {
- HttpServletRequest servletRequest = WrappedHttpServletRequest
+ public String getStaticFileLocation(VaadinRequest request) {
+ HttpServletRequest servletRequest = VaadinServletRequest
.cast(request);
String staticFileLocation;
// if property is defined in configurations, use that
@@ -108,20 +108,20 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
@Override
- public String getConfiguredWidgetset(WrappedRequest request) {
+ public String getConfiguredWidgetset(VaadinRequest request) {
return getDeploymentConfiguration().getApplicationOrSystemProperty(
VaadinServlet.PARAMETER_WIDGETSET,
VaadinServlet.DEFAULT_WIDGETSET);
}
@Override
- public String getConfiguredTheme(WrappedRequest request) {
+ public String getConfiguredTheme(VaadinRequest request) {
// Use the default
return VaadinServlet.getDefaultTheme();
}
@Override
- public boolean isStandalone(WrappedRequest request) {
+ public boolean isStandalone(VaadinRequest request) {
return true;
}
@@ -146,7 +146,7 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
@Override
- protected boolean requestCanCreateSession(WrappedRequest request) {
+ protected boolean requestCanCreateSession(VaadinRequest request) {
RequestType requestType = getRequestType(request);
if (requestType == RequestType.BROWSER_DETAILS) {
// This is the first request if you are embedding by writing the
@@ -172,22 +172,22 @@ public class VaadinServlet extends HttpServlet implements Constants {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- protected RequestType getRequestType(WrappedRequest request) {
+ protected RequestType getRequestType(VaadinRequest request) {
RequestType type = (RequestType) request
.getAttribute(RequestType.class.getName());
if (type == null) {
type = getServlet().getRequestType(
- WrappedHttpServletRequest.cast(request));
+ VaadinServletRequest.cast(request));
request.setAttribute(RequestType.class.getName(), type);
}
return type;
}
@Override
- protected URL getApplicationUrl(WrappedRequest request)
+ protected URL getApplicationUrl(VaadinRequest request)
throws MalformedURLException {
return getServlet().getApplicationUrl(
- WrappedHttpServletRequest.cast(request));
+ VaadinServletRequest.cast(request));
}
@Override
@@ -197,9 +197,9 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
public static HttpServletRequest getCurrentServletRequest() {
- WrappedRequest currentRequest = VaadinService.getCurrentRequest();
+ VaadinRequest currentRequest = VaadinService.getCurrentRequest();
try {
- WrappedHttpServletRequest request = WrappedHttpServletRequest
+ VaadinServletRequest request = VaadinServletRequest
.cast(currentRequest);
if (request != null) {
return request.getHttpServletRequest();
@@ -211,13 +211,12 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
}
- public static WrappedHttpServletResponse getCurrentResponse() {
- return (WrappedHttpServletResponse) VaadinService
- .getCurrentResponse();
+ public static VaadinServletResponse getCurrentResponse() {
+ return (VaadinServletResponse) VaadinService.getCurrentResponse();
}
@Override
- protected VaadinSession createVaadinSession(WrappedRequest request)
+ protected VaadinSession createVaadinSession(VaadinRequest request)
throws ServiceException {
return new VaadinServletSession();
}
@@ -232,12 +231,11 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
@Override
- public void criticalNotification(WrappedRequest request,
- WrappedResponse response, String cap, String msg,
+ public void criticalNotification(VaadinRequest request,
+ VaadinResponse response, String cap, String msg,
String details, String outOfSyncURL) throws IOException {
- servlet.criticalNotification(
- WrappedHttpServletRequest.cast(request),
- ((WrappedHttpServletResponse) response), cap, msg, details,
+ servlet.criticalNotification(VaadinServletRequest.cast(request),
+ ((VaadinServletResponse) response), cap, msg, details,
outOfSyncURL);
}
}
@@ -381,11 +379,11 @@ public class VaadinServlet extends HttpServlet implements Constants {
HttpServletResponse response) throws ServletException, IOException {
CurrentInstance.clearAll();
setCurrent(this);
- service(createWrappedRequest(request), createWrappedResponse(response));
+ service(createVaadinRequest(request), createVaadinResponse(response));
}
- private void service(WrappedHttpServletRequest request,
- WrappedHttpServletResponse response) throws ServletException,
+ private void service(VaadinServletRequest request,
+ VaadinServletResponse response) throws ServletException,
IOException {
RequestTimer requestTimer = new RequestTimer();
requestTimer.start();
@@ -501,24 +499,22 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
}
- private WrappedHttpServletResponse createWrappedResponse(
+ private VaadinServletResponse createVaadinResponse(
HttpServletResponse response) {
- WrappedHttpServletResponse wrappedResponse = new WrappedHttpServletResponse(
- response, getVaadinService());
- return wrappedResponse;
+ return new VaadinServletResponse(response, getVaadinService());
}
/**
- * Create a wrapped request for a http servlet request. This method can be
- * overridden if the wrapped request should have special properties.
+ * Create a Vaadin request for a http servlet request. This method can be
+ * overridden if the Vaadin request should have special properties.
*
* @param request
* the original http servlet request
- * @return a wrapped request for the original request
+ * @return a Vaadin request for the original request
*/
- protected WrappedHttpServletRequest createWrappedRequest(
+ protected VaadinServletRequest createVaadinRequest(
HttpServletRequest request) {
- return new WrappedHttpServletRequest(request, getVaadinService());
+ return new VaadinServletRequest(request, getVaadinService());
}
/**
@@ -545,8 +541,8 @@ public class VaadinServlet extends HttpServlet implements Constants {
* @throws IOException
*/
private boolean ensureCookiesEnabled(RequestType requestType,
- WrappedHttpServletRequest request,
- WrappedHttpServletResponse response) throws IOException {
+ VaadinServletRequest request, VaadinServletResponse response)
+ throws IOException {
if (requestType == RequestType.UIDL) {
// In all other but the first UIDL request a cookie should be
// returned by the browser.
@@ -592,7 +588,7 @@ public class VaadinServlet extends HttpServlet implements Constants {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- protected void criticalNotification(WrappedHttpServletRequest request,
+ protected void criticalNotification(VaadinServletRequest request,
HttpServletResponse response, String caption, String message,
String details, String url) throws IOException {
@@ -705,8 +701,8 @@ public class VaadinServlet extends HttpServlet implements Constants {
return resultPath;
}
- private void handleServiceException(WrappedHttpServletRequest request,
- WrappedHttpServletResponse response, VaadinSession vaadinSession,
+ private void handleServiceException(VaadinServletRequest request,
+ VaadinServletResponse response, VaadinSession vaadinSession,
Throwable e) throws IOException, ServletException {
// if this was an UIDL request, response UIDL back to client
if (getRequestType(request) == RequestType.UIDL) {
@@ -772,8 +768,8 @@ public class VaadinServlet extends HttpServlet implements Constants {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- void handleServiceSessionExpired(WrappedHttpServletRequest request,
- WrappedHttpServletResponse response) throws IOException,
+ void handleServiceSessionExpired(VaadinServletRequest request,
+ VaadinServletResponse response) throws IOException,
ServletException {
if (isOnUnloadRequest(request)) {
@@ -818,9 +814,8 @@ public class VaadinServlet extends HttpServlet implements Constants {
}
- private void handleServiceSecurityException(
- WrappedHttpServletRequest request,
- WrappedHttpServletResponse response) throws IOException,
+ private void handleServiceSecurityException(VaadinServletRequest request,
+ VaadinServletResponse response) throws IOException,
ServletException {
if (isOnUnloadRequest(request)) {
/*
@@ -1212,7 +1207,7 @@ public class VaadinServlet extends HttpServlet implements Constants {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- protected RequestType getRequestType(WrappedHttpServletRequest request) {
+ protected RequestType getRequestType(VaadinServletRequest request) {
if (ServletPortletHelper.isFileUploadRequest(request)) {
return RequestType.FILE_UPLOAD;
} else if (ServletPortletHelper.isConnectorResourceRequest(request)) {
diff --git a/server/src/com/vaadin/server/WrappedHttpServletRequest.java b/server/src/com/vaadin/server/VaadinServletRequest.java
index 99e8881ec1..e9d673a1f3 100644
--- a/server/src/com/vaadin/server/WrappedHttpServletRequest.java
+++ b/server/src/com/vaadin/server/VaadinServletRequest.java
@@ -28,11 +28,11 @@ import com.vaadin.server.VaadinServlet.ServletService;
* @author Vaadin Ltd.
* @since 7.0
*
- * @see WrappedRequest
- * @see WrappedHttpServletResponse
+ * @see VaadinRequest
+ * @see VaadinServletResponse
*/
-public class WrappedHttpServletRequest extends HttpServletRequestWrapper
- implements WrappedRequest {
+public class VaadinServletRequest extends HttpServletRequestWrapper implements
+ VaadinRequest {
private final ServletService vaadinService;
@@ -44,7 +44,7 @@ public class WrappedHttpServletRequest extends HttpServletRequestWrapper
* @param vaadinService
* the associated vaadin service
*/
- public WrappedHttpServletRequest(HttpServletRequest request,
+ public VaadinServletRequest(HttpServletRequest request,
ServletService vaadinService) {
super(request);
this.vaadinService = vaadinService;
@@ -105,22 +105,22 @@ public class WrappedHttpServletRequest extends HttpServletRequestWrapper
}
/**
- * Helper method to get a <code>WrappedHttpServletRequest</code> from a
- * <code>WrappedRequest</code>. Aside from casting, this method also takes
- * care of situations where there's another level of wrapping.
+ * Helper method to get a {@link VaadinServletRequest} from a
+ * {@link VaadinRequest}. Aside from casting, this method also takes care of
+ * situations where there's another level of wrapping.
*
* @param request
- * a wrapped request
- * @return a wrapped http servlet request
+ * a Vaadin request
+ * @return a Vaadin http servlet request
* @throws ClassCastException
- * if the wrapped request doesn't wrap a http servlet request
+ * if the Vaadin request doesn't wrap a http servlet request
*/
- public static WrappedHttpServletRequest cast(WrappedRequest request) {
+ public static VaadinServletRequest cast(VaadinRequest request) {
if (request instanceof CombinedRequest) {
CombinedRequest combinedRequest = (CombinedRequest) request;
request = combinedRequest.getSecondRequest();
}
- return (WrappedHttpServletRequest) request;
+ return (VaadinServletRequest) request;
}
} \ No newline at end of file
diff --git a/server/src/com/vaadin/server/WrappedHttpServletResponse.java b/server/src/com/vaadin/server/VaadinServletResponse.java
index 74a580f874..b21ca34249 100644
--- a/server/src/com/vaadin/server/WrappedHttpServletResponse.java
+++ b/server/src/com/vaadin/server/VaadinServletResponse.java
@@ -27,11 +27,11 @@ import com.vaadin.server.VaadinServlet.ServletService;
* @author Vaadin Ltd.
* @since 7.0
*
- * @see WrappedResponse
- * @see WrappedHttpServletRequest
+ * @see VaadinResponse
+ * @see VaadinServletRequest
*/
-public class WrappedHttpServletResponse extends HttpServletResponseWrapper
- implements WrappedResponse {
+public class VaadinServletResponse extends HttpServletResponseWrapper implements
+ VaadinResponse {
private ServletService vaadinService;
@@ -43,7 +43,7 @@ public class WrappedHttpServletResponse extends HttpServletResponseWrapper
* @param vaadinService
* the associated vaadin service
*/
- public WrappedHttpServletResponse(HttpServletResponse response,
+ public VaadinServletResponse(HttpServletResponse response,
ServletService vaadinService) {
super(response);
this.vaadinService = vaadinService;
@@ -63,8 +63,8 @@ public class WrappedHttpServletResponse extends HttpServletResponseWrapper
doSetCacheTime(this, milliseconds);
}
- // Implementation shared with WrappedPortletResponse
- static void doSetCacheTime(WrappedResponse response, long milliseconds) {
+ // Implementation shared with VaadinPortletResponse
+ static void doSetCacheTime(VaadinResponse response, long milliseconds) {
if (milliseconds <= 0) {
response.setHeader("Cache-Control", "no-cache");
response.setHeader("Pragma", "no-cache");
diff --git a/server/src/com/vaadin/server/VaadinSession.java b/server/src/com/vaadin/server/VaadinSession.java
index 8fbc7af335..c3699bacfa 100644
--- a/server/src/com/vaadin/server/VaadinSession.java
+++ b/server/src/com/vaadin/server/VaadinSession.java
@@ -42,7 +42,7 @@ import com.vaadin.data.util.converter.Converter;
import com.vaadin.data.util.converter.ConverterFactory;
import com.vaadin.data.util.converter.DefaultConverterFactory;
import com.vaadin.event.EventRouter;
-import com.vaadin.server.WrappedRequest.BrowserDetails;
+import com.vaadin.server.VaadinRequest.BrowserDetails;
import com.vaadin.shared.ui.ui.UIConstants;
import com.vaadin.ui.AbstractField;
import com.vaadin.ui.Table;
@@ -615,18 +615,18 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* host page is requested.
*
* @param request
- * the wrapped request for which a UI is needed
+ * the Vaadin request for which a UI is needed
* @return a UI instance to use for the request
*
* @see UI
- * @see WrappedRequest#getBrowserDetails()
+ * @see VaadinRequest#getBrowserDetails()
*
* @since 7.0
*
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- public Class<? extends UI> getUIClass(WrappedRequest request) {
+ public Class<? extends UI> getUIClass(VaadinRequest request) {
UIProvider uiProvider = getUiProvider(request, null);
return uiProvider.getUIClass(request);
}
@@ -644,7 +644,7 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- protected <T extends UI> T createUIInstance(WrappedRequest request,
+ protected <T extends UI> T createUIInstance(VaadinRequest request,
Class<T> uiClass) {
UIProvider uiProvider = getUiProvider(request, uiClass);
return uiClass.cast(uiProvider.createInstance(request, uiClass));
@@ -672,7 +672,7 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- public UIProvider getUiProvider(WrappedRequest request, Class<?> uiClass) {
+ public UIProvider getUiProvider(VaadinRequest request, Class<?> uiClass) {
UIProvider provider = (UIProvider) request
.getAttribute(UIProvider.class.getName());
if (provider != null) {
@@ -708,7 +708,7 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- private UIProvider doGetUiProvider(WrappedRequest request, Class<?> uiClass) {
+ private UIProvider doGetUiProvider(VaadinRequest request, Class<?> uiClass) {
int providersSize = uiProviders.size();
if (providersSize == 0) {
throw new IllegalStateException("There are no UI providers");
@@ -853,14 +853,14 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* the request for which a UI is desired
* @return a UI belonging to the request
*
- * @see #createUI(WrappedRequest)
+ * @see #createUI(VaadinRequest)
*
* @since 7.0
*
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- public UI getUIForRequest(WrappedRequest request) {
+ public UI getUIForRequest(VaadinRequest request) {
UI uI = UI.getCurrent();
if (uI != null) {
return uI;
@@ -890,7 +890,7 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- private UI findExistingUi(WrappedRequest request) {
+ private UI findExistingUi(VaadinRequest request) {
// Check if some UI provider has an existing UI available
for (int i = uiProviders.size() - 1; i >= 0; i--) {
UIProvider provider = uiProviders.get(i);
@@ -939,7 +939,7 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- public UI createUI(WrappedRequest request) {
+ public UI createUI(VaadinRequest request) {
Class<? extends UI> uiClass = getUIClass(request);
UI ui = createUIInstance(request, uiClass);
@@ -986,7 +986,7 @@ public class VaadinSession implements HttpSessionBindingListener, Serializable {
* @deprecated might be refactored or removed before 7.0.0
*/
@Deprecated
- private static Integer getUIId(WrappedRequest request) {
+ private static Integer getUIId(VaadinRequest request) {
if (request instanceof CombinedRequest) {
// Combined requests has the uiId parameter in the second request
CombinedRequest combinedRequest = (CombinedRequest) request;
diff --git a/server/src/com/vaadin/server/VaadinSessionInitializeEvent.java b/server/src/com/vaadin/server/VaadinSessionInitializeEvent.java
index cc4a0990d6..217e3d8f7d 100644
--- a/server/src/com/vaadin/server/VaadinSessionInitializeEvent.java
+++ b/server/src/com/vaadin/server/VaadinSessionInitializeEvent.java
@@ -35,7 +35,7 @@ import java.util.EventObject;
public class VaadinSessionInitializeEvent extends EventObject {
private final VaadinSession session;
- private final WrappedRequest request;
+ private final VaadinRequest request;
/**
* Creates a new event.
@@ -48,7 +48,7 @@ public class VaadinSessionInitializeEvent extends EventObject {
* the request that triggered the initialization
*/
public VaadinSessionInitializeEvent(VaadinService service,
- VaadinSession session, WrappedRequest request) {
+ VaadinSession session, VaadinRequest request) {
super(service);
this.session = session;
this.request = request;
@@ -82,7 +82,7 @@ public class VaadinSessionInitializeEvent extends EventObject {
*
* @return the request
*/
- public WrappedRequest getRequest() {
+ public VaadinRequest getRequest() {
return request;
}
diff --git a/server/src/com/vaadin/server/WebBrowser.java b/server/src/com/vaadin/server/WebBrowser.java
index 6a377a3de9..676375a693 100644
--- a/server/src/com/vaadin/server/WebBrowser.java
+++ b/server/src/com/vaadin/server/WebBrowser.java
@@ -411,9 +411,9 @@ public class WebBrowser implements Serializable {
* properties in the class according to the given information.
*
* @param request
- * the wrapped request to read the information from
+ * the Vaadin request to read the information from
*/
- void updateRequestDetails(WrappedRequest request) {
+ void updateRequestDetails(VaadinRequest request) {
locale = request.getLocale();
address = request.getRemoteAddr();
secureConnection = request.isSecure();
diff --git a/server/src/com/vaadin/ui/AbstractMedia.java b/server/src/com/vaadin/ui/AbstractMedia.java
index 219413974b..3cc801817f 100644
--- a/server/src/com/vaadin/ui/AbstractMedia.java
+++ b/server/src/com/vaadin/ui/AbstractMedia.java
@@ -26,8 +26,8 @@ import java.util.regex.Pattern;
import com.vaadin.server.ConnectorResource;
import com.vaadin.server.Resource;
import com.vaadin.server.ResourceReference;
-import com.vaadin.server.WrappedRequest;
-import com.vaadin.server.WrappedResponse;
+import com.vaadin.server.VaadinRequest;
+import com.vaadin.server.VaadinResponse;
import com.vaadin.shared.communication.URLReference;
import com.vaadin.shared.ui.AbstractMediaState;
import com.vaadin.shared.ui.MediaControl;
@@ -79,8 +79,8 @@ public abstract class AbstractMedia extends AbstractComponent {
}
@Override
- public boolean handleConnectorRequest(WrappedRequest request,
- WrappedResponse response, String path) throws IOException {
+ public boolean handleConnectorRequest(VaadinRequest request,
+ VaadinResponse response, String path) throws IOException {
Matcher matcher = Pattern.compile("(\\d+)(/.*)?").matcher(path);
if (matcher.matches()) {
List<URLReference> sources = getState().sources;
diff --git a/server/src/com/vaadin/ui/LoginForm.java b/server/src/com/vaadin/ui/LoginForm.java
index 69778c4c07..661c24bf56 100644
--- a/server/src/com/vaadin/ui/LoginForm.java
+++ b/server/src/com/vaadin/ui/LoginForm.java
@@ -28,8 +28,8 @@ import com.vaadin.server.ConnectorResource;
import com.vaadin.server.DownloadStream;
import com.vaadin.server.RequestHandler;
import com.vaadin.server.VaadinSession;
-import com.vaadin.server.WrappedRequest;
-import com.vaadin.server.WrappedResponse;
+import com.vaadin.server.VaadinRequest;
+import com.vaadin.server.VaadinResponse;
import com.vaadin.shared.ApplicationConstants;
/**
@@ -84,7 +84,7 @@ public class LoginForm extends CustomComponent {
private final RequestHandler requestHandler = new RequestHandler() {
@Override
public boolean handleRequest(VaadinSession session,
- WrappedRequest request, WrappedResponse response)
+ VaadinRequest request, VaadinResponse response)
throws IOException {
String requestPathInfo = request.getRequestPathInfo();
if ("/loginHandler".equals(requestPathInfo)) {
diff --git a/server/src/com/vaadin/ui/UI.java b/server/src/com/vaadin/ui/UI.java
index 0d83f8258d..5beb80ffcd 100644
--- a/server/src/com/vaadin/ui/UI.java
+++ b/server/src/com/vaadin/ui/UI.java
@@ -41,10 +41,10 @@ import com.vaadin.server.Page.BrowserWindowResizeListener;
import com.vaadin.server.PaintException;
import com.vaadin.server.PaintTarget;
import com.vaadin.server.Resource;
+import com.vaadin.server.VaadinRequest;
+import com.vaadin.server.VaadinRequest.BrowserDetails;
import com.vaadin.server.VaadinServlet;
import com.vaadin.server.VaadinSession;
-import com.vaadin.server.WrappedRequest;
-import com.vaadin.server.WrappedRequest.BrowserDetails;
import com.vaadin.shared.EventId;
import com.vaadin.shared.MouseEventDetails;
import com.vaadin.shared.ui.BorderStyle;
@@ -67,21 +67,21 @@ import com.vaadin.util.ReflectTools;
* <p>
* When a new UI instance is needed, typically because the user opens a URL in a
* browser window which points to {@link VaadinServlet},
- * {@link VaadinSession#getUIForRequest(WrappedRequest)} is invoked to get a UI.
+ * {@link VaadinSession#getUIForRequest(VaadinRequest)} is invoked to get a UI.
* That method does by default create a UI according to the
* {@value VaadinSession#UI_PARAMETER} parameter from web.xml.
* </p>
* <p>
* After a UI has been created by the application, it is initialized using
- * {@link #init(WrappedRequest)}. This method is intended to be overridden by
- * the developer to add components to the user interface and initialize
+ * {@link #init(VaadinRequest)}. This method is intended to be overridden by the
+ * developer to add components to the user interface and initialize
* non-component functionality. The component hierarchy is initialized by
* passing a {@link ComponentContainer} with the main layout of the view to
* {@link #setContent(ComponentContainer)}.
* </p>
*
- * @see #init(WrappedRequest)
- * @see VaadinSession#createUI(WrappedRequest)
+ * @see #init(VaadinRequest)
+ * @see VaadinSession#createUI(VaadinRequest)
*
* @since 7.0
*/
@@ -126,7 +126,7 @@ public abstract class UI extends AbstractComponentContainer implements
}
@Override
- protected void init(WrappedRequest request) {
+ protected void init(VaadinRequest request) {
// Just empty
}
@@ -748,8 +748,8 @@ public abstract class UI extends AbstractComponentContainer implements
* Gets the id of the UI, used to identify this UI within its application
* when processing requests. The UI id should be present in every request to
* the server that originates from this UI.
- * {@link VaadinSession#getUIForRequest(WrappedRequest)} uses this id to
- * find the route to which the request belongs.
+ * {@link VaadinSession#getUIForRequest(VaadinRequest)} uses this id to find
+ * the route to which the request belongs.
*
* @return
*/
@@ -761,7 +761,7 @@ public abstract class UI extends AbstractComponentContainer implements
* Adds a window as a subwindow inside this UI. To open a new browser window
* or tab, you should instead use {@link open(Resource)} with an url
* pointing to this application and ensure
- * {@link VaadinSession#createUI(WrappedRequest)} returns an appropriate UI
+ * {@link VaadinSession#createUI(VaadinRequest)} returns an appropriate UI
* for the request.
*
* @param window
@@ -979,7 +979,7 @@ public abstract class UI extends AbstractComponentContainer implements
* @param uiId
* the id of the new ui
*/
- public void doInit(WrappedRequest request, int uiId) {
+ public void doInit(VaadinRequest request, int uiId) {
if (this.uiId != -1) {
throw new IllegalStateException("UI id has already been defined");
}
@@ -999,15 +999,15 @@ public abstract class UI extends AbstractComponentContainer implements
* Performing the initialization in a constructor is not suggested as the
* state of the UI is not properly set up when the constructor is invoked.
* <p>
- * The {@link WrappedRequest} can be used to get information about the
+ * The {@link VaadinRequest} can be used to get information about the
* request that caused this UI to be created. {@link BrowserDetails} will be
* available in the request.
* </p>
*
* @param request
- * the wrapped request that caused this UI to be created
+ * the Vaadin request that caused this UI to be created
*/
- protected abstract void init(WrappedRequest request);
+ protected abstract void init(VaadinRequest request);
/**
* Sets the thread local for the current UI. This method is used by the