aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArtur Signell <artur@vaadin.com>2012-11-26 21:33:10 +0200
committerArtur Signell <artur@vaadin.com>2012-11-26 21:33:10 +0200
commit1281bb6c855bea61a97e146a894959ec98e5c401 (patch)
tree4eac3f175be43ed940b6d21d2063453811415595
parentc27a7044bb0ed55eb51b53bd7b2bd9204d614383 (diff)
downloadvaadin-framework-1281bb6c855bea61a97e146a894959ec98e5c401.tar.gz
vaadin-framework-1281bb6c855bea61a97e146a894959ec98e5c401.zip
Make AbstractExtensionConnector.extend abstract (#10378)
Change-Id: I96682d62c632588e05508a50765ac3d029500a74
-rw-r--r--client/src/com/vaadin/client/JavaScriptExtension.java6
-rw-r--r--client/src/com/vaadin/client/extensions/AbstractExtensionConnector.java4
-rw-r--r--client/src/com/vaadin/client/extensions/javascriptmanager/JavaScriptManagerConnector.java8
-rw-r--r--uitest/src/com/vaadin/tests/widgetset/client/SerializerTestConnector.java7
-rw-r--r--uitest/src/com/vaadin/tests/widgetset/client/helloworldfeature/HelloWorldExtensionConnector.java3
-rw-r--r--uitest/src/com/vaadin/tests/widgetset/client/minitutorials/v7a3/RefresherConnector.java7
6 files changed, 30 insertions, 5 deletions
diff --git a/client/src/com/vaadin/client/JavaScriptExtension.java b/client/src/com/vaadin/client/JavaScriptExtension.java
index bf1bb5b56a..a1ad5147a6 100644
--- a/client/src/com/vaadin/client/JavaScriptExtension.java
+++ b/client/src/com/vaadin/client/JavaScriptExtension.java
@@ -49,4 +49,10 @@ public final class JavaScriptExtension extends AbstractExtensionConnector
super.onUnregister();
helper.onUnregister();
}
+
+ @Override
+ protected void extend(ServerConnector target) {
+ // Nothing to do for JavaScriptExtension here. Everything is done in
+ // javascript.
+ }
}
diff --git a/client/src/com/vaadin/client/extensions/AbstractExtensionConnector.java b/client/src/com/vaadin/client/extensions/AbstractExtensionConnector.java
index a007e15357..ee5771e6e0 100644
--- a/client/src/com/vaadin/client/extensions/AbstractExtensionConnector.java
+++ b/client/src/com/vaadin/client/extensions/AbstractExtensionConnector.java
@@ -42,7 +42,5 @@ public abstract class AbstractExtensionConnector extends AbstractConnector {
}
}
- protected void extend(ServerConnector target) {
- // Default does nothing
- }
+ protected abstract void extend(ServerConnector target);
}
diff --git a/client/src/com/vaadin/client/extensions/javascriptmanager/JavaScriptManagerConnector.java b/client/src/com/vaadin/client/extensions/javascriptmanager/JavaScriptManagerConnector.java
index f6d643d1ba..2550fce208 100644
--- a/client/src/com/vaadin/client/extensions/javascriptmanager/JavaScriptManagerConnector.java
+++ b/client/src/com/vaadin/client/extensions/javascriptmanager/JavaScriptManagerConnector.java
@@ -22,6 +22,7 @@ import java.util.Set;
import com.google.gwt.core.client.JavaScriptObject;
import com.google.gwt.core.client.JsArray;
import com.google.gwt.json.client.JSONArray;
+import com.vaadin.client.ServerConnector;
import com.vaadin.client.communication.StateChangeEvent;
import com.vaadin.client.extensions.AbstractExtensionConnector;
import com.vaadin.shared.communication.MethodInvocation;
@@ -131,4 +132,11 @@ public class JavaScriptManagerConnector extends AbstractExtensionConnector {
public JavaScriptManagerState getState() {
return (JavaScriptManagerState) super.getState();
}
+
+ @Override
+ protected void extend(ServerConnector target) {
+ // Nothing to do there as we are not interested in the connector we
+ // extend (Page i.e. UI)
+
+ }
}
diff --git a/uitest/src/com/vaadin/tests/widgetset/client/SerializerTestConnector.java b/uitest/src/com/vaadin/tests/widgetset/client/SerializerTestConnector.java
index 26d41bc655..90cce49ace 100644
--- a/uitest/src/com/vaadin/tests/widgetset/client/SerializerTestConnector.java
+++ b/uitest/src/com/vaadin/tests/widgetset/client/SerializerTestConnector.java
@@ -26,6 +26,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
+import com.vaadin.client.ServerConnector;
import com.vaadin.client.communication.StateChangeEvent;
import com.vaadin.client.extensions.AbstractExtensionConnector;
import com.vaadin.shared.Connector;
@@ -263,4 +264,10 @@ public class SerializerTestConnector extends AbstractExtensionConnector {
// TODO do something clever
}
+ @Override
+ protected void extend(ServerConnector target) {
+ // TODO Auto-generated method stub
+
+ }
+
}
diff --git a/uitest/src/com/vaadin/tests/widgetset/client/helloworldfeature/HelloWorldExtensionConnector.java b/uitest/src/com/vaadin/tests/widgetset/client/helloworldfeature/HelloWorldExtensionConnector.java
index a0a6911eb2..54f5da4148 100644
--- a/uitest/src/com/vaadin/tests/widgetset/client/helloworldfeature/HelloWorldExtensionConnector.java
+++ b/uitest/src/com/vaadin/tests/widgetset/client/helloworldfeature/HelloWorldExtensionConnector.java
@@ -42,8 +42,7 @@ public class HelloWorldExtensionConnector extends AbstractExtensionConnector {
}
@Override
- public void setParent(ServerConnector parent) {
- super.setParent(parent);
+ protected void extend(ServerConnector target) {
greet();
}
diff --git a/uitest/src/com/vaadin/tests/widgetset/client/minitutorials/v7a3/RefresherConnector.java b/uitest/src/com/vaadin/tests/widgetset/client/minitutorials/v7a3/RefresherConnector.java
index 2deef7e1ba..b077d5b42d 100644
--- a/uitest/src/com/vaadin/tests/widgetset/client/minitutorials/v7a3/RefresherConnector.java
+++ b/uitest/src/com/vaadin/tests/widgetset/client/minitutorials/v7a3/RefresherConnector.java
@@ -1,6 +1,7 @@
package com.vaadin.tests.widgetset.client.minitutorials.v7a3;
import com.google.gwt.user.client.Timer;
+import com.vaadin.client.ServerConnector;
import com.vaadin.client.communication.StateChangeEvent;
import com.vaadin.client.extensions.AbstractExtensionConnector;
import com.vaadin.shared.ui.Connect;
@@ -31,6 +32,12 @@ public class RefresherConnector extends AbstractExtensionConnector {
}
@Override
+ protected void extend(ServerConnector target) {
+ // Nothing for refresher to do here as it does not need to access the
+ // connector it extends
+ }
+
+ @Override
public RefresherState getState() {
return (RefresherState) super.getState();
}