|
18 | 18 | package org.openqa.selenium.json;
|
19 | 19 |
|
20 | 20 | import com.google.common.io.CharStreams;
|
| 21 | +import com.google.common.reflect.TypeToken; |
21 | 22 | import com.google.gson.Gson;
|
22 | 23 | import com.google.gson.GsonBuilder;
|
23 | 24 | import com.google.gson.JsonElement;
|
24 | 25 | import com.google.gson.JsonParseException;
|
25 | 26 | import com.google.gson.TypeAdapter;
|
26 | 27 | import com.google.gson.TypeAdapterFactory;
|
27 |
| -import com.google.gson.reflect.TypeToken; |
28 | 28 | import com.google.gson.stream.JsonReader;
|
29 | 29 | import com.google.gson.stream.JsonToken;
|
30 | 30 | import com.google.gson.stream.JsonWriter;
|
@@ -127,7 +127,7 @@ private static class MapAdapter extends TypeAdapter<Map<?, ?>> {
|
127 | 127 | private final static TypeAdapterFactory FACTORY = new TypeAdapterFactory() {
|
128 | 128 | @SuppressWarnings("unchecked")
|
129 | 129 | @Override
|
130 |
| - public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> type) { |
| 130 | + public <T> TypeAdapter<T> create(Gson gson, com.google.gson.reflect.TypeToken<T> type) { |
131 | 131 | if (type.getRawType() == Map.class) {
|
132 | 132 | return (TypeAdapter<T>) new MapAdapter(gson);
|
133 | 133 | }
|
@@ -183,7 +183,7 @@ private static class ListAdapter extends TypeAdapter<List<?>> {
|
183 | 183 | private final static TypeAdapterFactory FACTORY = new TypeAdapterFactory() {
|
184 | 184 | @SuppressWarnings("unchecked")
|
185 | 185 | @Override
|
186 |
| - public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> type) { |
| 186 | + public <T> TypeAdapter<T> create(Gson gson, com.google.gson.reflect.TypeToken<T> type) { |
187 | 187 | if (type.getRawType() == List.class) {
|
188 | 188 | return (TypeAdapter<T>) new ListAdapter(gson);
|
189 | 189 | }
|
|
0 commit comments