diff options
author | Leif Åstrand <leif@vaadin.com> | 2012-07-23 15:23:43 +0300 |
---|---|---|
committer | Leif Åstrand <leif@vaadin.com> | 2012-07-23 15:23:43 +0300 |
commit | 3604bf01ded16d21041cbb655632429e00c94639 (patch) | |
tree | 9bf7ae9d3a33e6b672c164e696a24aef08ebc13e /src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java | |
parent | b7982bac6d8bca02fc76c9974ffd1c24d9a06f04 (diff) | |
download | vaadin-framework-3604bf01ded16d21041cbb655632429e00c94639.tar.gz vaadin-framework-3604bf01ded16d21041cbb655632429e00c94639.zip |
Add Java 6 @Override annotations to all methods from interfaces
Diffstat (limited to 'src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java')
-rw-r--r-- | src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java b/src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java index 15b5ced703..aed1c2c0e3 100644 --- a/src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java +++ b/src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java @@ -103,6 +103,7 @@ public class JsonPaintTarget implements PaintTarget { cacheEnabled = cachingRequired; } + @Override public void startTag(String tagName) throws PaintException { startTag(tagName, false); } @@ -159,6 +160,7 @@ public class JsonPaintTarget implements PaintTarget { * if the paint operation failed. */ + @Override public void endTag(String tagName) throws PaintException { // In case of null data output nothing: if (tagName == null) { @@ -326,14 +328,17 @@ public class JsonPaintTarget implements PaintTarget { * */ + @Override public void addText(String str) throws PaintException { tag.addData("\"" + escapeJSON(str) + "\""); } + @Override public void addAttribute(String name, boolean value) throws PaintException { tag.addAttribute("\"" + name + "\":" + (value ? "true" : "false")); } + @Override @SuppressWarnings("deprecation") public void addAttribute(String name, Resource value) throws PaintException { @@ -363,22 +368,27 @@ public class JsonPaintTarget implements PaintTarget { } + @Override public void addAttribute(String name, int value) throws PaintException { tag.addAttribute("\"" + name + "\":" + String.valueOf(value)); } + @Override public void addAttribute(String name, long value) throws PaintException { tag.addAttribute("\"" + name + "\":" + String.valueOf(value)); } + @Override public void addAttribute(String name, float value) throws PaintException { tag.addAttribute("\"" + name + "\":" + String.valueOf(value)); } + @Override public void addAttribute(String name, double value) throws PaintException { tag.addAttribute("\"" + name + "\":" + String.valueOf(value)); } + @Override public void addAttribute(String name, String value) throws PaintException { // In case of null data output nothing: if ((value == null) || (name == null)) { @@ -398,12 +408,14 @@ public class JsonPaintTarget implements PaintTarget { } + @Override public void addAttribute(String name, Component value) throws PaintException { final String id = value.getConnectorId(); addAttribute(name, id); } + @Override public void addAttribute(String name, Map<?, ?> value) throws PaintException { @@ -441,6 +453,7 @@ public class JsonPaintTarget implements PaintTarget { tag.addAttribute(sb.toString()); } + @Override public void addAttribute(String name, Object[] values) { // In case of null data output nothing: if ((values == null) || (name == null)) { @@ -461,41 +474,49 @@ public class JsonPaintTarget implements PaintTarget { tag.addAttribute(buf.toString()); } + @Override public void addVariable(VariableOwner owner, String name, String value) throws PaintException { tag.addVariable(new StringVariable(owner, name, escapeJSON(value))); } + @Override public void addVariable(VariableOwner owner, String name, Component value) throws PaintException { tag.addVariable(new StringVariable(owner, name, value.getConnectorId())); } + @Override public void addVariable(VariableOwner owner, String name, int value) throws PaintException { tag.addVariable(new IntVariable(owner, name, value)); } + @Override public void addVariable(VariableOwner owner, String name, long value) throws PaintException { tag.addVariable(new LongVariable(owner, name, value)); } + @Override public void addVariable(VariableOwner owner, String name, float value) throws PaintException { tag.addVariable(new FloatVariable(owner, name, value)); } + @Override public void addVariable(VariableOwner owner, String name, double value) throws PaintException { tag.addVariable(new DoubleVariable(owner, name, value)); } + @Override public void addVariable(VariableOwner owner, String name, boolean value) throws PaintException { tag.addVariable(new BooleanVariable(owner, name, value)); } + @Override public void addVariable(VariableOwner owner, String name, String[] value) throws PaintException { tag.addVariable(new ArrayVariable(owner, name, value)); @@ -515,6 +536,7 @@ public class JsonPaintTarget implements PaintTarget { * if the paint operation failed. */ + @Override public void addUploadStreamVariable(VariableOwner owner, String name) throws PaintException { startTag("uploadstream"); @@ -535,6 +557,7 @@ public class JsonPaintTarget implements PaintTarget { * if the paint operation failed. */ + @Override public void addSection(String sectionTagName, String sectionData) throws PaintException { tag.addData("{\"" + sectionTagName + "\":\"" + escapeJSON(sectionData) @@ -550,6 +573,7 @@ public class JsonPaintTarget implements PaintTarget { * if the paint operation failed. */ + @Override public void addUIDL(String xml) throws PaintException { // Ensure that the target is open @@ -584,6 +608,7 @@ public class JsonPaintTarget implements PaintTarget { * String) */ + @Override public void addXMLSection(String sectionTagName, String sectionData, String namespace) throws PaintException { @@ -649,6 +674,7 @@ public class JsonPaintTarget implements PaintTarget { * .Paintable, java.lang.String) */ + @Override public PaintStatus startPaintable(Component connector, String tagName) throws PaintException { boolean topLevelPaintable = openPaintables.isEmpty(); @@ -675,6 +701,7 @@ public class JsonPaintTarget implements PaintTarget { return PaintStatus.PAINTING; } + @Override public void endPaintable(Component paintable) throws PaintException { getLogger().fine( "endPaintable for " + paintable.getClass().getName() + "@" @@ -698,6 +725,7 @@ public class JsonPaintTarget implements PaintTarget { * @see com.vaadin.terminal.PaintTarget#addCharacterData(java.lang.String ) */ + @Override public void addCharacterData(String text) throws PaintException { if (text != null) { tag.addData(text); @@ -967,6 +995,7 @@ public class JsonPaintTarget implements PaintTarget { return usedResources; } + @Override @SuppressWarnings("unchecked") public String getTag(ClientConnector clientConnector) { Class<? extends ClientConnector> clientConnectorClass = clientConnector @@ -989,6 +1018,7 @@ public class JsonPaintTarget implements PaintTarget { return usedClientConnectors; } + @Override public void addVariable(VariableOwner owner, String name, StreamVariable value) throws PaintException { String url = manager.getStreamVariableTargetUrl( @@ -1005,6 +1035,7 @@ public class JsonPaintTarget implements PaintTarget { * @see com.vaadin.terminal.PaintTarget#isFullRepaint() */ + @Override public boolean isFullRepaint() { return !cacheEnabled; } |