summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authorLeif Åstrand <leif@vaadin.com>2015-01-15 11:41:20 +0200
committerVaadin Code Review <review@vaadin.com>2015-01-15 11:26:03 +0000
commit8d4661f867aab6a58c257ebe49d342a4a4af56d7 (patch)
tree81eb51699125551abc3c969eb283bb15cd509bc8 /client
parent9839c54cb1d9cf6e774ff40f0bc0d1b2a64acd01 (diff)
downloadvaadin-framework-8d4661f867aab6a58c257ebe49d342a4a4af56d7.tar.gz
vaadin-framework-8d4661f867aab6a58c257ebe49d342a4a4af56d7.zip
Make Grid send Json as Json (#16244)
Change-Id: I2da481dcd3c258e48f2f77a9d3c8c46bb81048ff
Diffstat (limited to 'client')
-rw-r--r--client/src/com/vaadin/client/connectors/RpcDataSourceConnector.java9
1 files changed, 1 insertions, 8 deletions
diff --git a/client/src/com/vaadin/client/connectors/RpcDataSourceConnector.java b/client/src/com/vaadin/client/connectors/RpcDataSourceConnector.java
index 74c8dfb02f..f8d6ebcb62 100644
--- a/client/src/com/vaadin/client/connectors/RpcDataSourceConnector.java
+++ b/client/src/com/vaadin/client/connectors/RpcDataSourceConnector.java
@@ -30,8 +30,6 @@ import com.vaadin.shared.ui.grid.Range;
import elemental.json.Json;
import elemental.json.JsonArray;
import elemental.json.JsonObject;
-import elemental.json.JsonType;
-import elemental.json.JsonValue;
/**
* Connects a Vaadin server-side container data source to a Grid. This is
@@ -50,12 +48,7 @@ public class RpcDataSourceConnector extends AbstractExtensionConnector {
protected RpcDataSource() {
registerRpc(DataProviderRpc.class, new DataProviderRpc() {
@Override
- public void setRowData(int firstRow, String rowsJson) {
- JsonValue parsedJson = Json.instance().parse(rowsJson);
- assert parsedJson.getType() == JsonType.ARRAY : "Was unable to parse JSON into an array: "
- + parsedJson;
- JsonArray rowArray = (JsonArray) parsedJson;
-
+ public void setRowData(int firstRow, JsonArray rowArray) {
ArrayList<JsonObject> rows = new ArrayList<JsonObject>(
rowArray.length());
for (int i = 0; i < rowArray.length(); i++) {