OLD | NEW |
1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
2 | 2 |
3 library googleapis.urlshortener.v1; | 3 library googleapis.urlshortener.v1; |
4 | 4 |
5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
8 | 8 |
9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
10 import 'package:http/http.dart' as http; | 10 import 'package:http/http.dart' as http; |
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
216 platforms = _json["platforms"].map((value) => new StringCount.fromJson(val
ue)).toList(); | 216 platforms = _json["platforms"].map((value) => new StringCount.fromJson(val
ue)).toList(); |
217 } | 217 } |
218 if (_json.containsKey("referrers")) { | 218 if (_json.containsKey("referrers")) { |
219 referrers = _json["referrers"].map((value) => new StringCount.fromJson(val
ue)).toList(); | 219 referrers = _json["referrers"].map((value) => new StringCount.fromJson(val
ue)).toList(); |
220 } | 220 } |
221 if (_json.containsKey("shortUrlClicks")) { | 221 if (_json.containsKey("shortUrlClicks")) { |
222 shortUrlClicks = _json["shortUrlClicks"]; | 222 shortUrlClicks = _json["shortUrlClicks"]; |
223 } | 223 } |
224 } | 224 } |
225 | 225 |
226 core.Map toJson() { | 226 core.Map<core.String, core.Object> toJson() { |
227 var _json = new core.Map(); | 227 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
228 if (browsers != null) { | 228 if (browsers != null) { |
229 _json["browsers"] = browsers.map((value) => (value).toJson()).toList(); | 229 _json["browsers"] = browsers.map((value) => (value).toJson()).toList(); |
230 } | 230 } |
231 if (countries != null) { | 231 if (countries != null) { |
232 _json["countries"] = countries.map((value) => (value).toJson()).toList(); | 232 _json["countries"] = countries.map((value) => (value).toJson()).toList(); |
233 } | 233 } |
234 if (longUrlClicks != null) { | 234 if (longUrlClicks != null) { |
235 _json["longUrlClicks"] = longUrlClicks; | 235 _json["longUrlClicks"] = longUrlClicks; |
236 } | 236 } |
237 if (platforms != null) { | 237 if (platforms != null) { |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
272 month = new AnalyticsSnapshot.fromJson(_json["month"]); | 272 month = new AnalyticsSnapshot.fromJson(_json["month"]); |
273 } | 273 } |
274 if (_json.containsKey("twoHours")) { | 274 if (_json.containsKey("twoHours")) { |
275 twoHours = new AnalyticsSnapshot.fromJson(_json["twoHours"]); | 275 twoHours = new AnalyticsSnapshot.fromJson(_json["twoHours"]); |
276 } | 276 } |
277 if (_json.containsKey("week")) { | 277 if (_json.containsKey("week")) { |
278 week = new AnalyticsSnapshot.fromJson(_json["week"]); | 278 week = new AnalyticsSnapshot.fromJson(_json["week"]); |
279 } | 279 } |
280 } | 280 } |
281 | 281 |
282 core.Map toJson() { | 282 core.Map<core.String, core.Object> toJson() { |
283 var _json = new core.Map(); | 283 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
284 if (allTime != null) { | 284 if (allTime != null) { |
285 _json["allTime"] = (allTime).toJson(); | 285 _json["allTime"] = (allTime).toJson(); |
286 } | 286 } |
287 if (day != null) { | 287 if (day != null) { |
288 _json["day"] = (day).toJson(); | 288 _json["day"] = (day).toJson(); |
289 } | 289 } |
290 if (month != null) { | 290 if (month != null) { |
291 _json["month"] = (month).toJson(); | 291 _json["month"] = (month).toJson(); |
292 } | 292 } |
293 if (twoHours != null) { | 293 if (twoHours != null) { |
(...skipping 19 matching lines...) Expand all Loading... |
313 | 313 |
314 StringCount.fromJson(core.Map _json) { | 314 StringCount.fromJson(core.Map _json) { |
315 if (_json.containsKey("count")) { | 315 if (_json.containsKey("count")) { |
316 count = _json["count"]; | 316 count = _json["count"]; |
317 } | 317 } |
318 if (_json.containsKey("id")) { | 318 if (_json.containsKey("id")) { |
319 id = _json["id"]; | 319 id = _json["id"]; |
320 } | 320 } |
321 } | 321 } |
322 | 322 |
323 core.Map toJson() { | 323 core.Map<core.String, core.Object> toJson() { |
324 var _json = new core.Map(); | 324 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
325 if (count != null) { | 325 if (count != null) { |
326 _json["count"] = count; | 326 _json["count"] = count; |
327 } | 327 } |
328 if (id != null) { | 328 if (id != null) { |
329 _json["id"] = id; | 329 _json["id"] = id; |
330 } | 330 } |
331 return _json; | 331 return _json; |
332 } | 332 } |
333 } | 333 } |
334 | 334 |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
375 kind = _json["kind"]; | 375 kind = _json["kind"]; |
376 } | 376 } |
377 if (_json.containsKey("longUrl")) { | 377 if (_json.containsKey("longUrl")) { |
378 longUrl = _json["longUrl"]; | 378 longUrl = _json["longUrl"]; |
379 } | 379 } |
380 if (_json.containsKey("status")) { | 380 if (_json.containsKey("status")) { |
381 status = _json["status"]; | 381 status = _json["status"]; |
382 } | 382 } |
383 } | 383 } |
384 | 384 |
385 core.Map toJson() { | 385 core.Map<core.String, core.Object> toJson() { |
386 var _json = new core.Map(); | 386 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
387 if (analytics != null) { | 387 if (analytics != null) { |
388 _json["analytics"] = (analytics).toJson(); | 388 _json["analytics"] = (analytics).toJson(); |
389 } | 389 } |
390 if (created != null) { | 390 if (created != null) { |
391 _json["created"] = created; | 391 _json["created"] = created; |
392 } | 392 } |
393 if (id != null) { | 393 if (id != null) { |
394 _json["id"] = id; | 394 _json["id"] = id; |
395 } | 395 } |
396 if (kind != null) { | 396 if (kind != null) { |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
436 kind = _json["kind"]; | 436 kind = _json["kind"]; |
437 } | 437 } |
438 if (_json.containsKey("nextPageToken")) { | 438 if (_json.containsKey("nextPageToken")) { |
439 nextPageToken = _json["nextPageToken"]; | 439 nextPageToken = _json["nextPageToken"]; |
440 } | 440 } |
441 if (_json.containsKey("totalItems")) { | 441 if (_json.containsKey("totalItems")) { |
442 totalItems = _json["totalItems"]; | 442 totalItems = _json["totalItems"]; |
443 } | 443 } |
444 } | 444 } |
445 | 445 |
446 core.Map toJson() { | 446 core.Map<core.String, core.Object> toJson() { |
447 var _json = new core.Map(); | 447 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
448 if (items != null) { | 448 if (items != null) { |
449 _json["items"] = items.map((value) => (value).toJson()).toList(); | 449 _json["items"] = items.map((value) => (value).toJson()).toList(); |
450 } | 450 } |
451 if (itemsPerPage != null) { | 451 if (itemsPerPage != null) { |
452 _json["itemsPerPage"] = itemsPerPage; | 452 _json["itemsPerPage"] = itemsPerPage; |
453 } | 453 } |
454 if (kind != null) { | 454 if (kind != null) { |
455 _json["kind"] = kind; | 455 _json["kind"] = kind; |
456 } | 456 } |
457 if (nextPageToken != null) { | 457 if (nextPageToken != null) { |
458 _json["nextPageToken"] = nextPageToken; | 458 _json["nextPageToken"] = nextPageToken; |
459 } | 459 } |
460 if (totalItems != null) { | 460 if (totalItems != null) { |
461 _json["totalItems"] = totalItems; | 461 _json["totalItems"] = totalItems; |
462 } | 462 } |
463 return _json; | 463 return _json; |
464 } | 464 } |
465 } | 465 } |
OLD | NEW |