Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1623)

Side by Side Diff: generated/googleapis/lib/fusiontables/v2.dart

Issue 3006323002: Api-Roll 54: 2017-09-11 (Closed)
Patch Set: use 2.0.0-dev.infinity sdk constraint in pubspecs Created 3 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « generated/googleapis/lib/fusiontables/v1.dart ('k') | generated/googleapis/lib/games/v1.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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.fusiontables.v2; 3 library googleapis.fusiontables.v2;
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;
11 11
12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show 12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart'
13 ApiRequestError, DetailedApiRequestError, Media, UploadOptions, 13 show
14 ResumableUploadOptions, DownloadOptions, PartialDownloadOptions, 14 ApiRequestError,
15 ByteRange; 15 DetailedApiRequestError,
16 Media,
17 UploadOptions,
18 ResumableUploadOptions,
19 DownloadOptions,
20 PartialDownloadOptions,
21 ByteRange;
16 22
17 const core.String USER_AGENT = 'dart-api-client fusiontables/v2'; 23 const core.String USER_AGENT = 'dart-api-client fusiontables/v2';
18 24
19 /** API for working with Fusion Tables data. */ 25 /// API for working with Fusion Tables data.
20 class FusiontablesApi { 26 class FusiontablesApi {
21 /** Manage your Fusion Tables */ 27 /// Manage your Fusion Tables
22 static const FusiontablesScope = "https://www.googleapis.com/auth/fusiontables "; 28 static const FusiontablesScope =
29 "https://www.googleapis.com/auth/fusiontables";
23 30
24 /** View your Fusion Tables */ 31 /// View your Fusion Tables
25 static const FusiontablesReadonlyScope = "https://www.googleapis.com/auth/fusi ontables.readonly"; 32 static const FusiontablesReadonlyScope =
26 33 "https://www.googleapis.com/auth/fusiontables.readonly";
27 34
28 final commons.ApiRequester _requester; 35 final commons.ApiRequester _requester;
29 36
30 ColumnResourceApi get column => new ColumnResourceApi(_requester); 37 ColumnResourceApi get column => new ColumnResourceApi(_requester);
31 QueryResourceApi get query => new QueryResourceApi(_requester); 38 QueryResourceApi get query => new QueryResourceApi(_requester);
32 StyleResourceApi get style => new StyleResourceApi(_requester); 39 StyleResourceApi get style => new StyleResourceApi(_requester);
33 TableResourceApi get table => new TableResourceApi(_requester); 40 TableResourceApi get table => new TableResourceApi(_requester);
34 TaskResourceApi get task => new TaskResourceApi(_requester); 41 TaskResourceApi get task => new TaskResourceApi(_requester);
35 TemplateResourceApi get template => new TemplateResourceApi(_requester); 42 TemplateResourceApi get template => new TemplateResourceApi(_requester);
36 43
37 FusiontablesApi(http.Client client, {core.String rootUrl: "https://www.googlea pis.com/", core.String servicePath: "fusiontables/v2/"}) : 44 FusiontablesApi(http.Client client,
38 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A GENT); 45 {core.String rootUrl: "https://www.googleapis.com/",
46 core.String servicePath: "fusiontables/v2/"})
47 : _requester =
48 new commons.ApiRequester(client, rootUrl, servicePath, USER_AGENT);
39 } 49 }
40 50
41
42 class ColumnResourceApi { 51 class ColumnResourceApi {
43 final commons.ApiRequester _requester; 52 final commons.ApiRequester _requester;
44 53
45 ColumnResourceApi(commons.ApiRequester client) : 54 ColumnResourceApi(commons.ApiRequester client) : _requester = client;
46 _requester = client;
47 55
48 /** 56 /// Deletes the specified column.
49 * Deletes the specified column. 57 ///
50 * 58 /// Request parameters:
51 * Request parameters: 59 ///
52 * 60 /// [tableId] - Table from which the column is being deleted.
53 * [tableId] - Table from which the column is being deleted. 61 ///
54 * 62 /// [columnId] - Name or identifier for the column being deleted.
55 * [columnId] - Name or identifier for the column being deleted. 63 ///
56 * 64 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
57 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 65 /// an error.
58 * error. 66 ///
59 * 67 /// If the used [http.Client] completes with an error when making a REST
60 * If the used [http.Client] completes with an error when making a REST call, 68 /// call, this method will complete with the same error.
61 * this method will complete with the same error.
62 */
63 async.Future delete(core.String tableId, core.String columnId) { 69 async.Future delete(core.String tableId, core.String columnId) {
64 var _url = null; 70 var _url = null;
65 var _queryParams = new core.Map(); 71 var _queryParams = new core.Map();
66 var _uploadMedia = null; 72 var _uploadMedia = null;
67 var _uploadOptions = null; 73 var _uploadOptions = null;
68 var _downloadOptions = commons.DownloadOptions.Metadata; 74 var _downloadOptions = commons.DownloadOptions.Metadata;
69 var _body = null; 75 var _body = null;
70 76
71 if (tableId == null) { 77 if (tableId == null) {
72 throw new core.ArgumentError("Parameter tableId is required."); 78 throw new core.ArgumentError("Parameter tableId is required.");
73 } 79 }
74 if (columnId == null) { 80 if (columnId == null) {
75 throw new core.ArgumentError("Parameter columnId is required."); 81 throw new core.ArgumentError("Parameter columnId is required.");
76 } 82 }
77 83
78 _downloadOptions = null; 84 _downloadOptions = null;
79 85
80 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns/' + commons.Escaper.ecapeVariable('$columnId'); 86 _url = 'tables/' +
87 commons.Escaper.ecapeVariable('$tableId') +
88 '/columns/' +
89 commons.Escaper.ecapeVariable('$columnId');
81 90
82 var _response = _requester.request(_url, 91 var _response = _requester.request(_url, "DELETE",
83 "DELETE", 92 body: _body,
84 body: _body, 93 queryParams: _queryParams,
85 queryParams: _queryParams, 94 uploadOptions: _uploadOptions,
86 uploadOptions: _uploadOptions, 95 uploadMedia: _uploadMedia,
87 uploadMedia: _uploadMedia, 96 downloadOptions: _downloadOptions);
88 downloadOptions: _downloadOptions);
89 return _response.then((data) => null); 97 return _response.then((data) => null);
90 } 98 }
91 99
92 /** 100 /// Retrieves a specific column by its ID.
93 * Retrieves a specific column by its ID. 101 ///
94 * 102 /// Request parameters:
95 * Request parameters: 103 ///
96 * 104 /// [tableId] - Table to which the column belongs.
97 * [tableId] - Table to which the column belongs. 105 ///
98 * 106 /// [columnId] - Name or identifier for the column that is being requested.
99 * [columnId] - Name or identifier for the column that is being requested. 107 ///
100 * 108 /// Completes with a [Column].
101 * Completes with a [Column]. 109 ///
102 * 110 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
103 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 111 /// an error.
104 * error. 112 ///
105 * 113 /// If the used [http.Client] completes with an error when making a REST
106 * If the used [http.Client] completes with an error when making a REST call, 114 /// call, this method will complete with the same error.
107 * this method will complete with the same error.
108 */
109 async.Future<Column> get(core.String tableId, core.String columnId) { 115 async.Future<Column> get(core.String tableId, core.String columnId) {
110 var _url = null; 116 var _url = null;
111 var _queryParams = new core.Map(); 117 var _queryParams = new core.Map();
112 var _uploadMedia = null; 118 var _uploadMedia = null;
113 var _uploadOptions = null; 119 var _uploadOptions = null;
114 var _downloadOptions = commons.DownloadOptions.Metadata; 120 var _downloadOptions = commons.DownloadOptions.Metadata;
115 var _body = null; 121 var _body = null;
116 122
117 if (tableId == null) { 123 if (tableId == null) {
118 throw new core.ArgumentError("Parameter tableId is required."); 124 throw new core.ArgumentError("Parameter tableId is required.");
119 } 125 }
120 if (columnId == null) { 126 if (columnId == null) {
121 throw new core.ArgumentError("Parameter columnId is required."); 127 throw new core.ArgumentError("Parameter columnId is required.");
122 } 128 }
123 129
124 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns/' + commons.Escaper.ecapeVariable('$columnId'); 130 _url = 'tables/' +
131 commons.Escaper.ecapeVariable('$tableId') +
132 '/columns/' +
133 commons.Escaper.ecapeVariable('$columnId');
125 134
126 var _response = _requester.request(_url, 135 var _response = _requester.request(_url, "GET",
127 "GET", 136 body: _body,
128 body: _body, 137 queryParams: _queryParams,
129 queryParams: _queryParams, 138 uploadOptions: _uploadOptions,
130 uploadOptions: _uploadOptions, 139 uploadMedia: _uploadMedia,
131 uploadMedia: _uploadMedia, 140 downloadOptions: _downloadOptions);
132 downloadOptions: _downloadOptions);
133 return _response.then((data) => new Column.fromJson(data)); 141 return _response.then((data) => new Column.fromJson(data));
134 } 142 }
135 143
136 /** 144 /// Adds a new column to the table.
137 * Adds a new column to the table. 145 ///
138 * 146 /// [request] - The metadata request object.
139 * [request] - The metadata request object. 147 ///
140 * 148 /// Request parameters:
141 * Request parameters: 149 ///
142 * 150 /// [tableId] - Table for which a new column is being added.
143 * [tableId] - Table for which a new column is being added. 151 ///
144 * 152 /// Completes with a [Column].
145 * Completes with a [Column]. 153 ///
146 * 154 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
147 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 155 /// an error.
148 * error. 156 ///
149 * 157 /// If the used [http.Client] completes with an error when making a REST
150 * If the used [http.Client] completes with an error when making a REST call, 158 /// call, this method will complete with the same error.
151 * this method will complete with the same error.
152 */
153 async.Future<Column> insert(Column request, core.String tableId) { 159 async.Future<Column> insert(Column request, core.String tableId) {
154 var _url = null; 160 var _url = null;
155 var _queryParams = new core.Map(); 161 var _queryParams = new core.Map();
156 var _uploadMedia = null; 162 var _uploadMedia = null;
157 var _uploadOptions = null; 163 var _uploadOptions = null;
158 var _downloadOptions = commons.DownloadOptions.Metadata; 164 var _downloadOptions = commons.DownloadOptions.Metadata;
159 var _body = null; 165 var _body = null;
160 166
161 if (request != null) { 167 if (request != null) {
162 _body = convert.JSON.encode((request).toJson()); 168 _body = convert.JSON.encode((request).toJson());
163 } 169 }
164 if (tableId == null) { 170 if (tableId == null) {
165 throw new core.ArgumentError("Parameter tableId is required."); 171 throw new core.ArgumentError("Parameter tableId is required.");
166 } 172 }
167 173
168 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns'; 174 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns';
169 175
170 var _response = _requester.request(_url, 176 var _response = _requester.request(_url, "POST",
171 "POST", 177 body: _body,
172 body: _body, 178 queryParams: _queryParams,
173 queryParams: _queryParams, 179 uploadOptions: _uploadOptions,
174 uploadOptions: _uploadOptions, 180 uploadMedia: _uploadMedia,
175 uploadMedia: _uploadMedia, 181 downloadOptions: _downloadOptions);
176 downloadOptions: _downloadOptions);
177 return _response.then((data) => new Column.fromJson(data)); 182 return _response.then((data) => new Column.fromJson(data));
178 } 183 }
179 184
180 /** 185 /// Retrieves a list of columns.
181 * Retrieves a list of columns. 186 ///
182 * 187 /// Request parameters:
183 * Request parameters: 188 ///
184 * 189 /// [tableId] - Table whose columns are being listed.
185 * [tableId] - Table whose columns are being listed. 190 ///
186 * 191 /// [maxResults] - Maximum number of columns to return. Default is 5.
187 * [maxResults] - Maximum number of columns to return. Default is 5. 192 ///
188 * 193 /// [pageToken] - Continuation token specifying which result page to return.
189 * [pageToken] - Continuation token specifying which result page to return. 194 ///
190 * 195 /// Completes with a [ColumnList].
191 * Completes with a [ColumnList]. 196 ///
192 * 197 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
193 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 198 /// an error.
194 * error. 199 ///
195 * 200 /// If the used [http.Client] completes with an error when making a REST
196 * If the used [http.Client] completes with an error when making a REST call, 201 /// call, this method will complete with the same error.
197 * this method will complete with the same error. 202 async.Future<ColumnList> list(core.String tableId,
198 */ 203 {core.int maxResults, core.String pageToken}) {
199 async.Future<ColumnList> list(core.String tableId, {core.int maxResults, core. String pageToken}) {
200 var _url = null; 204 var _url = null;
201 var _queryParams = new core.Map(); 205 var _queryParams = new core.Map();
202 var _uploadMedia = null; 206 var _uploadMedia = null;
203 var _uploadOptions = null; 207 var _uploadOptions = null;
204 var _downloadOptions = commons.DownloadOptions.Metadata; 208 var _downloadOptions = commons.DownloadOptions.Metadata;
205 var _body = null; 209 var _body = null;
206 210
207 if (tableId == null) { 211 if (tableId == null) {
208 throw new core.ArgumentError("Parameter tableId is required."); 212 throw new core.ArgumentError("Parameter tableId is required.");
209 } 213 }
210 if (maxResults != null) { 214 if (maxResults != null) {
211 _queryParams["maxResults"] = ["${maxResults}"]; 215 _queryParams["maxResults"] = ["${maxResults}"];
212 } 216 }
213 if (pageToken != null) { 217 if (pageToken != null) {
214 _queryParams["pageToken"] = [pageToken]; 218 _queryParams["pageToken"] = [pageToken];
215 } 219 }
216 220
217 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns'; 221 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns';
218 222
219 var _response = _requester.request(_url, 223 var _response = _requester.request(_url, "GET",
220 "GET", 224 body: _body,
221 body: _body, 225 queryParams: _queryParams,
222 queryParams: _queryParams, 226 uploadOptions: _uploadOptions,
223 uploadOptions: _uploadOptions, 227 uploadMedia: _uploadMedia,
224 uploadMedia: _uploadMedia, 228 downloadOptions: _downloadOptions);
225 downloadOptions: _downloadOptions);
226 return _response.then((data) => new ColumnList.fromJson(data)); 229 return _response.then((data) => new ColumnList.fromJson(data));
227 } 230 }
228 231
229 /** 232 /// Updates the name or type of an existing column. This method supports
230 * Updates the name or type of an existing column. This method supports patch 233 /// patch semantics.
231 * semantics. 234 ///
232 * 235 /// [request] - The metadata request object.
233 * [request] - The metadata request object. 236 ///
234 * 237 /// Request parameters:
235 * Request parameters: 238 ///
236 * 239 /// [tableId] - Table for which the column is being updated.
237 * [tableId] - Table for which the column is being updated. 240 ///
238 * 241 /// [columnId] - Name or identifier for the column that is being updated.
239 * [columnId] - Name or identifier for the column that is being updated. 242 ///
240 * 243 /// Completes with a [Column].
241 * Completes with a [Column]. 244 ///
242 * 245 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
243 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 246 /// an error.
244 * error. 247 ///
245 * 248 /// If the used [http.Client] completes with an error when making a REST
246 * If the used [http.Client] completes with an error when making a REST call, 249 /// call, this method will complete with the same error.
247 * this method will complete with the same error. 250 async.Future<Column> patch(
248 */ 251 Column request, core.String tableId, core.String columnId) {
249 async.Future<Column> patch(Column request, core.String tableId, core.String co lumnId) {
250 var _url = null; 252 var _url = null;
251 var _queryParams = new core.Map(); 253 var _queryParams = new core.Map();
252 var _uploadMedia = null; 254 var _uploadMedia = null;
253 var _uploadOptions = null; 255 var _uploadOptions = null;
254 var _downloadOptions = commons.DownloadOptions.Metadata; 256 var _downloadOptions = commons.DownloadOptions.Metadata;
255 var _body = null; 257 var _body = null;
256 258
257 if (request != null) { 259 if (request != null) {
258 _body = convert.JSON.encode((request).toJson()); 260 _body = convert.JSON.encode((request).toJson());
259 } 261 }
260 if (tableId == null) { 262 if (tableId == null) {
261 throw new core.ArgumentError("Parameter tableId is required."); 263 throw new core.ArgumentError("Parameter tableId is required.");
262 } 264 }
263 if (columnId == null) { 265 if (columnId == null) {
264 throw new core.ArgumentError("Parameter columnId is required."); 266 throw new core.ArgumentError("Parameter columnId is required.");
265 } 267 }
266 268
267 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns/' + commons.Escaper.ecapeVariable('$columnId'); 269 _url = 'tables/' +
270 commons.Escaper.ecapeVariable('$tableId') +
271 '/columns/' +
272 commons.Escaper.ecapeVariable('$columnId');
268 273
269 var _response = _requester.request(_url, 274 var _response = _requester.request(_url, "PATCH",
270 "PATCH", 275 body: _body,
271 body: _body, 276 queryParams: _queryParams,
272 queryParams: _queryParams, 277 uploadOptions: _uploadOptions,
273 uploadOptions: _uploadOptions, 278 uploadMedia: _uploadMedia,
274 uploadMedia: _uploadMedia, 279 downloadOptions: _downloadOptions);
275 downloadOptions: _downloadOptions);
276 return _response.then((data) => new Column.fromJson(data)); 280 return _response.then((data) => new Column.fromJson(data));
277 } 281 }
278 282
279 /** 283 /// Updates the name or type of an existing column.
280 * Updates the name or type of an existing column. 284 ///
281 * 285 /// [request] - The metadata request object.
282 * [request] - The metadata request object. 286 ///
283 * 287 /// Request parameters:
284 * Request parameters: 288 ///
285 * 289 /// [tableId] - Table for which the column is being updated.
286 * [tableId] - Table for which the column is being updated. 290 ///
287 * 291 /// [columnId] - Name or identifier for the column that is being updated.
288 * [columnId] - Name or identifier for the column that is being updated. 292 ///
289 * 293 /// Completes with a [Column].
290 * Completes with a [Column]. 294 ///
291 * 295 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
292 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 296 /// an error.
293 * error. 297 ///
294 * 298 /// If the used [http.Client] completes with an error when making a REST
295 * If the used [http.Client] completes with an error when making a REST call, 299 /// call, this method will complete with the same error.
296 * this method will complete with the same error. 300 async.Future<Column> update(
297 */ 301 Column request, core.String tableId, core.String columnId) {
298 async.Future<Column> update(Column request, core.String tableId, core.String c olumnId) {
299 var _url = null; 302 var _url = null;
300 var _queryParams = new core.Map(); 303 var _queryParams = new core.Map();
301 var _uploadMedia = null; 304 var _uploadMedia = null;
302 var _uploadOptions = null; 305 var _uploadOptions = null;
303 var _downloadOptions = commons.DownloadOptions.Metadata; 306 var _downloadOptions = commons.DownloadOptions.Metadata;
304 var _body = null; 307 var _body = null;
305 308
306 if (request != null) { 309 if (request != null) {
307 _body = convert.JSON.encode((request).toJson()); 310 _body = convert.JSON.encode((request).toJson());
308 } 311 }
309 if (tableId == null) { 312 if (tableId == null) {
310 throw new core.ArgumentError("Parameter tableId is required."); 313 throw new core.ArgumentError("Parameter tableId is required.");
311 } 314 }
312 if (columnId == null) { 315 if (columnId == null) {
313 throw new core.ArgumentError("Parameter columnId is required."); 316 throw new core.ArgumentError("Parameter columnId is required.");
314 } 317 }
315 318
316 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/columns/' + commons.Escaper.ecapeVariable('$columnId'); 319 _url = 'tables/' +
320 commons.Escaper.ecapeVariable('$tableId') +
321 '/columns/' +
322 commons.Escaper.ecapeVariable('$columnId');
317 323
318 var _response = _requester.request(_url, 324 var _response = _requester.request(_url, "PUT",
319 "PUT", 325 body: _body,
320 body: _body, 326 queryParams: _queryParams,
321 queryParams: _queryParams, 327 uploadOptions: _uploadOptions,
322 uploadOptions: _uploadOptions, 328 uploadMedia: _uploadMedia,
323 uploadMedia: _uploadMedia, 329 downloadOptions: _downloadOptions);
324 downloadOptions: _downloadOptions);
325 return _response.then((data) => new Column.fromJson(data)); 330 return _response.then((data) => new Column.fromJson(data));
326 } 331 }
327
328 } 332 }
329 333
330
331 class QueryResourceApi { 334 class QueryResourceApi {
332 final commons.ApiRequester _requester; 335 final commons.ApiRequester _requester;
333 336
334 QueryResourceApi(commons.ApiRequester client) : 337 QueryResourceApi(commons.ApiRequester client) : _requester = client;
335 _requester = client;
336 338
337 /** 339 /// Executes a Fusion Tables SQL statement, which can be any of
338 * Executes a Fusion Tables SQL statement, which can be any of 340 /// - SELECT
339 * - SELECT 341 /// - INSERT
340 * - INSERT 342 /// - UPDATE
341 * - UPDATE 343 /// - DELETE
342 * - DELETE 344 /// - SHOW
343 * - SHOW 345 /// - DESCRIBE
344 * - DESCRIBE 346 /// - CREATE statement.
345 * - CREATE statement. 347 ///
346 * 348 /// Request parameters:
347 * Request parameters: 349 ///
348 * 350 /// [sql_1] - A Fusion Tables SQL statement, which can be any of
349 * [sql_1] - A Fusion Tables SQL statement, which can be any of 351 /// - SELECT
350 * - SELECT 352 /// - INSERT
351 * - INSERT 353 /// - UPDATE
352 * - UPDATE 354 /// - DELETE
353 * - DELETE 355 /// - SHOW
354 * - SHOW 356 /// - DESCRIBE
355 * - DESCRIBE 357 /// - CREATE
356 * - CREATE 358 ///
357 * 359 /// [hdrs] - Whether column names are included in the first row. Default is
358 * [hdrs] - Whether column names are included in the first row. Default is 360 /// true.
359 * true. 361 ///
360 * 362 /// [typed] - Whether typed values are returned in the (JSON) response:
361 * [typed] - Whether typed values are returned in the (JSON) response: numbers 363 /// numbers for numeric values and parsed geometries for KML values. Default
362 * for numeric values and parsed geometries for KML values. Default is true. 364 /// is true.
363 * 365 ///
364 * [downloadOptions] - Options for downloading. A download can be either a 366 /// [downloadOptions] - Options for downloading. A download can be either a
365 * Metadata (default) or Media download. Partial Media downloads are possible 367 /// Metadata (default) or Media download. Partial Media downloads are
366 * as well. 368 /// possible as well.
367 * 369 ///
368 * Completes with a 370 /// Completes with a
369 * 371 ///
370 * - [Sqlresponse] for Metadata downloads (see [downloadOptions]). 372 /// - [Sqlresponse] for Metadata downloads (see [downloadOptions]).
371 * 373 ///
372 * - [commons.Media] for Media downloads (see [downloadOptions]). 374 /// - [commons.Media] for Media downloads (see [downloadOptions]).
373 * 375 ///
374 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 376 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
375 * error. 377 /// an error.
376 * 378 ///
377 * If the used [http.Client] completes with an error when making a REST call, 379 /// If the used [http.Client] completes with an error when making a REST
378 * this method will complete with the same error. 380 /// call, this method will complete with the same error.
379 */ 381 async.Future sql(core.String sql_1,
380 async.Future sql(core.String sql_1, {core.bool hdrs, core.bool typed, commons. DownloadOptions downloadOptions: commons.DownloadOptions.Metadata}) { 382 {core.bool hdrs,
383 core.bool typed,
384 commons.DownloadOptions downloadOptions:
385 commons.DownloadOptions.Metadata}) {
381 var _url = null; 386 var _url = null;
382 var _queryParams = new core.Map(); 387 var _queryParams = new core.Map();
383 var _uploadMedia = null; 388 var _uploadMedia = null;
384 var _uploadOptions = null; 389 var _uploadOptions = null;
385 var _downloadOptions = commons.DownloadOptions.Metadata; 390 var _downloadOptions = commons.DownloadOptions.Metadata;
386 var _body = null; 391 var _body = null;
387 392
388 if (sql_1 == null) { 393 if (sql_1 == null) {
389 throw new core.ArgumentError("Parameter sql_1 is required."); 394 throw new core.ArgumentError("Parameter sql_1 is required.");
390 } 395 }
391 _queryParams["sql"] = [sql_1]; 396 _queryParams["sql"] = [sql_1];
392 if (hdrs != null) { 397 if (hdrs != null) {
393 _queryParams["hdrs"] = ["${hdrs}"]; 398 _queryParams["hdrs"] = ["${hdrs}"];
394 } 399 }
395 if (typed != null) { 400 if (typed != null) {
396 _queryParams["typed"] = ["${typed}"]; 401 _queryParams["typed"] = ["${typed}"];
397 } 402 }
398 403
399 _downloadOptions = downloadOptions; 404 _downloadOptions = downloadOptions;
400 405
401 _url = 'query'; 406 _url = 'query';
402 407
403 var _response = _requester.request(_url, 408 var _response = _requester.request(_url, "POST",
404 "POST", 409 body: _body,
405 body: _body, 410 queryParams: _queryParams,
406 queryParams: _queryParams, 411 uploadOptions: _uploadOptions,
407 uploadOptions: _uploadOptions, 412 uploadMedia: _uploadMedia,
408 uploadMedia: _uploadMedia, 413 downloadOptions: _downloadOptions);
409 downloadOptions: _downloadOptions);
410 if (_downloadOptions == null || 414 if (_downloadOptions == null ||
411 _downloadOptions == commons.DownloadOptions.Metadata) { 415 _downloadOptions == commons.DownloadOptions.Metadata) {
412 return _response.then((data) => new Sqlresponse.fromJson(data)); 416 return _response.then((data) => new Sqlresponse.fromJson(data));
413 } else { 417 } else {
414 return _response; 418 return _response;
415 } 419 }
416 } 420 }
417 421
418 /** 422 /// Executes a SQL statement which can be any of
419 * Executes a SQL statement which can be any of 423 /// - SELECT
420 * - SELECT 424 /// - SHOW
421 * - SHOW 425 /// - DESCRIBE
422 * - DESCRIBE 426 ///
423 * 427 /// Request parameters:
424 * Request parameters: 428 ///
425 * 429 /// [sql_1] - A SQL statement which can be any of
426 * [sql_1] - A SQL statement which can be any of 430 /// - SELECT
427 * - SELECT 431 /// - SHOW
428 * - SHOW 432 /// - DESCRIBE
429 * - DESCRIBE 433 ///
430 * 434 /// [hdrs] - Whether column names are included (in the first row). Default is
431 * [hdrs] - Whether column names are included (in the first row). Default is 435 /// true.
432 * true. 436 ///
433 * 437 /// [typed] - Whether typed values are returned in the (JSON) response:
434 * [typed] - Whether typed values are returned in the (JSON) response: numbers 438 /// numbers for numeric values and parsed geometries for KML values. Default
435 * for numeric values and parsed geometries for KML values. Default is true. 439 /// is true.
436 * 440 ///
437 * [downloadOptions] - Options for downloading. A download can be either a 441 /// [downloadOptions] - Options for downloading. A download can be either a
438 * Metadata (default) or Media download. Partial Media downloads are possible 442 /// Metadata (default) or Media download. Partial Media downloads are
439 * as well. 443 /// possible as well.
440 * 444 ///
441 * Completes with a 445 /// Completes with a
442 * 446 ///
443 * - [Sqlresponse] for Metadata downloads (see [downloadOptions]). 447 /// - [Sqlresponse] for Metadata downloads (see [downloadOptions]).
444 * 448 ///
445 * - [commons.Media] for Media downloads (see [downloadOptions]). 449 /// - [commons.Media] for Media downloads (see [downloadOptions]).
446 * 450 ///
447 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 451 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
448 * error. 452 /// an error.
449 * 453 ///
450 * If the used [http.Client] completes with an error when making a REST call, 454 /// If the used [http.Client] completes with an error when making a REST
451 * this method will complete with the same error. 455 /// call, this method will complete with the same error.
452 */ 456 async.Future sqlGet(core.String sql_1,
453 async.Future sqlGet(core.String sql_1, {core.bool hdrs, core.bool typed, commo ns.DownloadOptions downloadOptions: commons.DownloadOptions.Metadata}) { 457 {core.bool hdrs,
458 core.bool typed,
459 commons.DownloadOptions downloadOptions:
460 commons.DownloadOptions.Metadata}) {
454 var _url = null; 461 var _url = null;
455 var _queryParams = new core.Map(); 462 var _queryParams = new core.Map();
456 var _uploadMedia = null; 463 var _uploadMedia = null;
457 var _uploadOptions = null; 464 var _uploadOptions = null;
458 var _downloadOptions = commons.DownloadOptions.Metadata; 465 var _downloadOptions = commons.DownloadOptions.Metadata;
459 var _body = null; 466 var _body = null;
460 467
461 if (sql_1 == null) { 468 if (sql_1 == null) {
462 throw new core.ArgumentError("Parameter sql_1 is required."); 469 throw new core.ArgumentError("Parameter sql_1 is required.");
463 } 470 }
464 _queryParams["sql"] = [sql_1]; 471 _queryParams["sql"] = [sql_1];
465 if (hdrs != null) { 472 if (hdrs != null) {
466 _queryParams["hdrs"] = ["${hdrs}"]; 473 _queryParams["hdrs"] = ["${hdrs}"];
467 } 474 }
468 if (typed != null) { 475 if (typed != null) {
469 _queryParams["typed"] = ["${typed}"]; 476 _queryParams["typed"] = ["${typed}"];
470 } 477 }
471 478
472 _downloadOptions = downloadOptions; 479 _downloadOptions = downloadOptions;
473 480
474 _url = 'query'; 481 _url = 'query';
475 482
476 var _response = _requester.request(_url, 483 var _response = _requester.request(_url, "GET",
477 "GET", 484 body: _body,
478 body: _body, 485 queryParams: _queryParams,
479 queryParams: _queryParams, 486 uploadOptions: _uploadOptions,
480 uploadOptions: _uploadOptions, 487 uploadMedia: _uploadMedia,
481 uploadMedia: _uploadMedia, 488 downloadOptions: _downloadOptions);
482 downloadOptions: _downloadOptions);
483 if (_downloadOptions == null || 489 if (_downloadOptions == null ||
484 _downloadOptions == commons.DownloadOptions.Metadata) { 490 _downloadOptions == commons.DownloadOptions.Metadata) {
485 return _response.then((data) => new Sqlresponse.fromJson(data)); 491 return _response.then((data) => new Sqlresponse.fromJson(data));
486 } else { 492 } else {
487 return _response; 493 return _response;
488 } 494 }
489 } 495 }
490
491 } 496 }
492 497
493
494 class StyleResourceApi { 498 class StyleResourceApi {
495 final commons.ApiRequester _requester; 499 final commons.ApiRequester _requester;
496 500
497 StyleResourceApi(commons.ApiRequester client) : 501 StyleResourceApi(commons.ApiRequester client) : _requester = client;
498 _requester = client;
499 502
500 /** 503 /// Deletes a style.
501 * Deletes a style. 504 ///
502 * 505 /// Request parameters:
503 * Request parameters: 506 ///
504 * 507 /// [tableId] - Table from which the style is being deleted
505 * [tableId] - Table from which the style is being deleted 508 ///
506 * 509 /// [styleId] - Identifier (within a table) for the style being deleted
507 * [styleId] - Identifier (within a table) for the style being deleted 510 ///
508 * 511 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
509 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 512 /// an error.
510 * error. 513 ///
511 * 514 /// If the used [http.Client] completes with an error when making a REST
512 * If the used [http.Client] completes with an error when making a REST call, 515 /// call, this method will complete with the same error.
513 * this method will complete with the same error.
514 */
515 async.Future delete(core.String tableId, core.int styleId) { 516 async.Future delete(core.String tableId, core.int styleId) {
516 var _url = null; 517 var _url = null;
517 var _queryParams = new core.Map(); 518 var _queryParams = new core.Map();
518 var _uploadMedia = null; 519 var _uploadMedia = null;
519 var _uploadOptions = null; 520 var _uploadOptions = null;
520 var _downloadOptions = commons.DownloadOptions.Metadata; 521 var _downloadOptions = commons.DownloadOptions.Metadata;
521 var _body = null; 522 var _body = null;
522 523
523 if (tableId == null) { 524 if (tableId == null) {
524 throw new core.ArgumentError("Parameter tableId is required."); 525 throw new core.ArgumentError("Parameter tableId is required.");
525 } 526 }
526 if (styleId == null) { 527 if (styleId == null) {
527 throw new core.ArgumentError("Parameter styleId is required."); 528 throw new core.ArgumentError("Parameter styleId is required.");
528 } 529 }
529 530
530 _downloadOptions = null; 531 _downloadOptions = null;
531 532
532 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles/' + commons.Escaper.ecapeVariable('$styleId'); 533 _url = 'tables/' +
534 commons.Escaper.ecapeVariable('$tableId') +
535 '/styles/' +
536 commons.Escaper.ecapeVariable('$styleId');
533 537
534 var _response = _requester.request(_url, 538 var _response = _requester.request(_url, "DELETE",
535 "DELETE", 539 body: _body,
536 body: _body, 540 queryParams: _queryParams,
537 queryParams: _queryParams, 541 uploadOptions: _uploadOptions,
538 uploadOptions: _uploadOptions, 542 uploadMedia: _uploadMedia,
539 uploadMedia: _uploadMedia, 543 downloadOptions: _downloadOptions);
540 downloadOptions: _downloadOptions);
541 return _response.then((data) => null); 544 return _response.then((data) => null);
542 } 545 }
543 546
544 /** 547 /// Gets a specific style.
545 * Gets a specific style. 548 ///
546 * 549 /// Request parameters:
547 * Request parameters: 550 ///
548 * 551 /// [tableId] - Table to which the requested style belongs
549 * [tableId] - Table to which the requested style belongs 552 ///
550 * 553 /// [styleId] - Identifier (integer) for a specific style in a table
551 * [styleId] - Identifier (integer) for a specific style in a table 554 ///
552 * 555 /// Completes with a [StyleSetting].
553 * Completes with a [StyleSetting]. 556 ///
554 * 557 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
555 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 558 /// an error.
556 * error. 559 ///
557 * 560 /// If the used [http.Client] completes with an error when making a REST
558 * If the used [http.Client] completes with an error when making a REST call, 561 /// call, this method will complete with the same error.
559 * this method will complete with the same error.
560 */
561 async.Future<StyleSetting> get(core.String tableId, core.int styleId) { 562 async.Future<StyleSetting> get(core.String tableId, core.int styleId) {
562 var _url = null; 563 var _url = null;
563 var _queryParams = new core.Map(); 564 var _queryParams = new core.Map();
564 var _uploadMedia = null; 565 var _uploadMedia = null;
565 var _uploadOptions = null; 566 var _uploadOptions = null;
566 var _downloadOptions = commons.DownloadOptions.Metadata; 567 var _downloadOptions = commons.DownloadOptions.Metadata;
567 var _body = null; 568 var _body = null;
568 569
569 if (tableId == null) { 570 if (tableId == null) {
570 throw new core.ArgumentError("Parameter tableId is required."); 571 throw new core.ArgumentError("Parameter tableId is required.");
571 } 572 }
572 if (styleId == null) { 573 if (styleId == null) {
573 throw new core.ArgumentError("Parameter styleId is required."); 574 throw new core.ArgumentError("Parameter styleId is required.");
574 } 575 }
575 576
576 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles/' + commons.Escaper.ecapeVariable('$styleId'); 577 _url = 'tables/' +
578 commons.Escaper.ecapeVariable('$tableId') +
579 '/styles/' +
580 commons.Escaper.ecapeVariable('$styleId');
577 581
578 var _response = _requester.request(_url, 582 var _response = _requester.request(_url, "GET",
579 "GET", 583 body: _body,
580 body: _body, 584 queryParams: _queryParams,
581 queryParams: _queryParams, 585 uploadOptions: _uploadOptions,
582 uploadOptions: _uploadOptions, 586 uploadMedia: _uploadMedia,
583 uploadMedia: _uploadMedia, 587 downloadOptions: _downloadOptions);
584 downloadOptions: _downloadOptions);
585 return _response.then((data) => new StyleSetting.fromJson(data)); 588 return _response.then((data) => new StyleSetting.fromJson(data));
586 } 589 }
587 590
588 /** 591 /// Adds a new style for the table.
589 * Adds a new style for the table. 592 ///
590 * 593 /// [request] - The metadata request object.
591 * [request] - The metadata request object. 594 ///
592 * 595 /// Request parameters:
593 * Request parameters: 596 ///
594 * 597 /// [tableId] - Table for which a new style is being added
595 * [tableId] - Table for which a new style is being added 598 ///
596 * 599 /// Completes with a [StyleSetting].
597 * Completes with a [StyleSetting]. 600 ///
598 * 601 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
599 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 602 /// an error.
600 * error. 603 ///
601 * 604 /// If the used [http.Client] completes with an error when making a REST
602 * If the used [http.Client] completes with an error when making a REST call, 605 /// call, this method will complete with the same error.
603 * this method will complete with the same error.
604 */
605 async.Future<StyleSetting> insert(StyleSetting request, core.String tableId) { 606 async.Future<StyleSetting> insert(StyleSetting request, core.String tableId) {
606 var _url = null; 607 var _url = null;
607 var _queryParams = new core.Map(); 608 var _queryParams = new core.Map();
608 var _uploadMedia = null; 609 var _uploadMedia = null;
609 var _uploadOptions = null; 610 var _uploadOptions = null;
610 var _downloadOptions = commons.DownloadOptions.Metadata; 611 var _downloadOptions = commons.DownloadOptions.Metadata;
611 var _body = null; 612 var _body = null;
612 613
613 if (request != null) { 614 if (request != null) {
614 _body = convert.JSON.encode((request).toJson()); 615 _body = convert.JSON.encode((request).toJson());
615 } 616 }
616 if (tableId == null) { 617 if (tableId == null) {
617 throw new core.ArgumentError("Parameter tableId is required."); 618 throw new core.ArgumentError("Parameter tableId is required.");
618 } 619 }
619 620
620 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles'; 621 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles';
621 622
622 var _response = _requester.request(_url, 623 var _response = _requester.request(_url, "POST",
623 "POST", 624 body: _body,
624 body: _body, 625 queryParams: _queryParams,
625 queryParams: _queryParams, 626 uploadOptions: _uploadOptions,
626 uploadOptions: _uploadOptions, 627 uploadMedia: _uploadMedia,
627 uploadMedia: _uploadMedia, 628 downloadOptions: _downloadOptions);
628 downloadOptions: _downloadOptions);
629 return _response.then((data) => new StyleSetting.fromJson(data)); 629 return _response.then((data) => new StyleSetting.fromJson(data));
630 } 630 }
631 631
632 /** 632 /// Retrieves a list of styles.
633 * Retrieves a list of styles. 633 ///
634 * 634 /// Request parameters:
635 * Request parameters: 635 ///
636 * 636 /// [tableId] - Table whose styles are being listed
637 * [tableId] - Table whose styles are being listed 637 ///
638 * 638 /// [maxResults] - Maximum number of styles to return. Optional. Default is
639 * [maxResults] - Maximum number of styles to return. Optional. Default is 5. 639 /// 5.
640 * 640 ///
641 * [pageToken] - Continuation token specifying which result page to return. 641 /// [pageToken] - Continuation token specifying which result page to return.
642 * Optional. 642 /// Optional.
643 * 643 ///
644 * Completes with a [StyleSettingList]. 644 /// Completes with a [StyleSettingList].
645 * 645 ///
646 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 646 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
647 * error. 647 /// an error.
648 * 648 ///
649 * If the used [http.Client] completes with an error when making a REST call, 649 /// If the used [http.Client] completes with an error when making a REST
650 * this method will complete with the same error. 650 /// call, this method will complete with the same error.
651 */ 651 async.Future<StyleSettingList> list(core.String tableId,
652 async.Future<StyleSettingList> list(core.String tableId, {core.int maxResults, core.String pageToken}) { 652 {core.int maxResults, core.String pageToken}) {
653 var _url = null; 653 var _url = null;
654 var _queryParams = new core.Map(); 654 var _queryParams = new core.Map();
655 var _uploadMedia = null; 655 var _uploadMedia = null;
656 var _uploadOptions = null; 656 var _uploadOptions = null;
657 var _downloadOptions = commons.DownloadOptions.Metadata; 657 var _downloadOptions = commons.DownloadOptions.Metadata;
658 var _body = null; 658 var _body = null;
659 659
660 if (tableId == null) { 660 if (tableId == null) {
661 throw new core.ArgumentError("Parameter tableId is required."); 661 throw new core.ArgumentError("Parameter tableId is required.");
662 } 662 }
663 if (maxResults != null) { 663 if (maxResults != null) {
664 _queryParams["maxResults"] = ["${maxResults}"]; 664 _queryParams["maxResults"] = ["${maxResults}"];
665 } 665 }
666 if (pageToken != null) { 666 if (pageToken != null) {
667 _queryParams["pageToken"] = [pageToken]; 667 _queryParams["pageToken"] = [pageToken];
668 } 668 }
669 669
670 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles'; 670 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles';
671 671
672 var _response = _requester.request(_url, 672 var _response = _requester.request(_url, "GET",
673 "GET", 673 body: _body,
674 body: _body, 674 queryParams: _queryParams,
675 queryParams: _queryParams, 675 uploadOptions: _uploadOptions,
676 uploadOptions: _uploadOptions, 676 uploadMedia: _uploadMedia,
677 uploadMedia: _uploadMedia, 677 downloadOptions: _downloadOptions);
678 downloadOptions: _downloadOptions);
679 return _response.then((data) => new StyleSettingList.fromJson(data)); 678 return _response.then((data) => new StyleSettingList.fromJson(data));
680 } 679 }
681 680
682 /** 681 /// Updates an existing style. This method supports patch semantics.
683 * Updates an existing style. This method supports patch semantics. 682 ///
684 * 683 /// [request] - The metadata request object.
685 * [request] - The metadata request object. 684 ///
686 * 685 /// Request parameters:
687 * Request parameters: 686 ///
688 * 687 /// [tableId] - Table whose style is being updated.
689 * [tableId] - Table whose style is being updated. 688 ///
690 * 689 /// [styleId] - Identifier (within a table) for the style being updated.
691 * [styleId] - Identifier (within a table) for the style being updated. 690 ///
692 * 691 /// Completes with a [StyleSetting].
693 * Completes with a [StyleSetting]. 692 ///
694 * 693 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
695 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 694 /// an error.
696 * error. 695 ///
697 * 696 /// If the used [http.Client] completes with an error when making a REST
698 * If the used [http.Client] completes with an error when making a REST call, 697 /// call, this method will complete with the same error.
699 * this method will complete with the same error. 698 async.Future<StyleSetting> patch(
700 */ 699 StyleSetting request, core.String tableId, core.int styleId) {
701 async.Future<StyleSetting> patch(StyleSetting request, core.String tableId, co re.int styleId) {
702 var _url = null; 700 var _url = null;
703 var _queryParams = new core.Map(); 701 var _queryParams = new core.Map();
704 var _uploadMedia = null; 702 var _uploadMedia = null;
705 var _uploadOptions = null; 703 var _uploadOptions = null;
706 var _downloadOptions = commons.DownloadOptions.Metadata; 704 var _downloadOptions = commons.DownloadOptions.Metadata;
707 var _body = null; 705 var _body = null;
708 706
709 if (request != null) { 707 if (request != null) {
710 _body = convert.JSON.encode((request).toJson()); 708 _body = convert.JSON.encode((request).toJson());
711 } 709 }
712 if (tableId == null) { 710 if (tableId == null) {
713 throw new core.ArgumentError("Parameter tableId is required."); 711 throw new core.ArgumentError("Parameter tableId is required.");
714 } 712 }
715 if (styleId == null) { 713 if (styleId == null) {
716 throw new core.ArgumentError("Parameter styleId is required."); 714 throw new core.ArgumentError("Parameter styleId is required.");
717 } 715 }
718 716
719 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles/' + commons.Escaper.ecapeVariable('$styleId'); 717 _url = 'tables/' +
718 commons.Escaper.ecapeVariable('$tableId') +
719 '/styles/' +
720 commons.Escaper.ecapeVariable('$styleId');
720 721
721 var _response = _requester.request(_url, 722 var _response = _requester.request(_url, "PATCH",
722 "PATCH", 723 body: _body,
723 body: _body, 724 queryParams: _queryParams,
724 queryParams: _queryParams, 725 uploadOptions: _uploadOptions,
725 uploadOptions: _uploadOptions, 726 uploadMedia: _uploadMedia,
726 uploadMedia: _uploadMedia, 727 downloadOptions: _downloadOptions);
727 downloadOptions: _downloadOptions);
728 return _response.then((data) => new StyleSetting.fromJson(data)); 728 return _response.then((data) => new StyleSetting.fromJson(data));
729 } 729 }
730 730
731 /** 731 /// Updates an existing style.
732 * Updates an existing style. 732 ///
733 * 733 /// [request] - The metadata request object.
734 * [request] - The metadata request object. 734 ///
735 * 735 /// Request parameters:
736 * Request parameters: 736 ///
737 * 737 /// [tableId] - Table whose style is being updated.
738 * [tableId] - Table whose style is being updated. 738 ///
739 * 739 /// [styleId] - Identifier (within a table) for the style being updated.
740 * [styleId] - Identifier (within a table) for the style being updated. 740 ///
741 * 741 /// Completes with a [StyleSetting].
742 * Completes with a [StyleSetting]. 742 ///
743 * 743 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
744 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 744 /// an error.
745 * error. 745 ///
746 * 746 /// If the used [http.Client] completes with an error when making a REST
747 * If the used [http.Client] completes with an error when making a REST call, 747 /// call, this method will complete with the same error.
748 * this method will complete with the same error. 748 async.Future<StyleSetting> update(
749 */ 749 StyleSetting request, core.String tableId, core.int styleId) {
750 async.Future<StyleSetting> update(StyleSetting request, core.String tableId, c ore.int styleId) {
751 var _url = null; 750 var _url = null;
752 var _queryParams = new core.Map(); 751 var _queryParams = new core.Map();
753 var _uploadMedia = null; 752 var _uploadMedia = null;
754 var _uploadOptions = null; 753 var _uploadOptions = null;
755 var _downloadOptions = commons.DownloadOptions.Metadata; 754 var _downloadOptions = commons.DownloadOptions.Metadata;
756 var _body = null; 755 var _body = null;
757 756
758 if (request != null) { 757 if (request != null) {
759 _body = convert.JSON.encode((request).toJson()); 758 _body = convert.JSON.encode((request).toJson());
760 } 759 }
761 if (tableId == null) { 760 if (tableId == null) {
762 throw new core.ArgumentError("Parameter tableId is required."); 761 throw new core.ArgumentError("Parameter tableId is required.");
763 } 762 }
764 if (styleId == null) { 763 if (styleId == null) {
765 throw new core.ArgumentError("Parameter styleId is required."); 764 throw new core.ArgumentError("Parameter styleId is required.");
766 } 765 }
767 766
768 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/styles/' + commons.Escaper.ecapeVariable('$styleId'); 767 _url = 'tables/' +
768 commons.Escaper.ecapeVariable('$tableId') +
769 '/styles/' +
770 commons.Escaper.ecapeVariable('$styleId');
769 771
770 var _response = _requester.request(_url, 772 var _response = _requester.request(_url, "PUT",
771 "PUT", 773 body: _body,
772 body: _body, 774 queryParams: _queryParams,
773 queryParams: _queryParams, 775 uploadOptions: _uploadOptions,
774 uploadOptions: _uploadOptions, 776 uploadMedia: _uploadMedia,
775 uploadMedia: _uploadMedia, 777 downloadOptions: _downloadOptions);
776 downloadOptions: _downloadOptions);
777 return _response.then((data) => new StyleSetting.fromJson(data)); 778 return _response.then((data) => new StyleSetting.fromJson(data));
778 } 779 }
779
780 } 780 }
781 781
782
783 class TableResourceApi { 782 class TableResourceApi {
784 final commons.ApiRequester _requester; 783 final commons.ApiRequester _requester;
785 784
786 TableResourceApi(commons.ApiRequester client) : 785 TableResourceApi(commons.ApiRequester client) : _requester = client;
787 _requester = client;
788 786
789 /** 787 /// Copies a table.
790 * Copies a table. 788 ///
791 * 789 /// Request parameters:
792 * Request parameters: 790 ///
793 * 791 /// [tableId] - ID of the table that is being copied.
794 * [tableId] - ID of the table that is being copied. 792 ///
795 * 793 /// [copyPresentation] - Whether to also copy tabs, styles, and templates.
796 * [copyPresentation] - Whether to also copy tabs, styles, and templates. 794 /// Default is false.
797 * Default is false. 795 ///
798 * 796 /// Completes with a [Table].
799 * Completes with a [Table]. 797 ///
800 * 798 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
801 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 799 /// an error.
802 * error. 800 ///
803 * 801 /// If the used [http.Client] completes with an error when making a REST
804 * If the used [http.Client] completes with an error when making a REST call, 802 /// call, this method will complete with the same error.
805 * this method will complete with the same error.
806 */
807 async.Future<Table> copy(core.String tableId, {core.bool copyPresentation}) { 803 async.Future<Table> copy(core.String tableId, {core.bool copyPresentation}) {
808 var _url = null; 804 var _url = null;
809 var _queryParams = new core.Map(); 805 var _queryParams = new core.Map();
810 var _uploadMedia = null; 806 var _uploadMedia = null;
811 var _uploadOptions = null; 807 var _uploadOptions = null;
812 var _downloadOptions = commons.DownloadOptions.Metadata; 808 var _downloadOptions = commons.DownloadOptions.Metadata;
813 var _body = null; 809 var _body = null;
814 810
815 if (tableId == null) { 811 if (tableId == null) {
816 throw new core.ArgumentError("Parameter tableId is required."); 812 throw new core.ArgumentError("Parameter tableId is required.");
817 } 813 }
818 if (copyPresentation != null) { 814 if (copyPresentation != null) {
819 _queryParams["copyPresentation"] = ["${copyPresentation}"]; 815 _queryParams["copyPresentation"] = ["${copyPresentation}"];
820 } 816 }
821 817
822 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/copy'; 818 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/copy';
823 819
824 var _response = _requester.request(_url, 820 var _response = _requester.request(_url, "POST",
825 "POST", 821 body: _body,
826 body: _body, 822 queryParams: _queryParams,
827 queryParams: _queryParams, 823 uploadOptions: _uploadOptions,
828 uploadOptions: _uploadOptions, 824 uploadMedia: _uploadMedia,
829 uploadMedia: _uploadMedia, 825 downloadOptions: _downloadOptions);
830 downloadOptions: _downloadOptions);
831 return _response.then((data) => new Table.fromJson(data)); 826 return _response.then((data) => new Table.fromJson(data));
832 } 827 }
833 828
834 /** 829 /// Deletes a table.
835 * Deletes a table. 830 ///
836 * 831 /// Request parameters:
837 * Request parameters: 832 ///
838 * 833 /// [tableId] - ID of the table to be deleted.
839 * [tableId] - ID of the table to be deleted. 834 ///
840 * 835 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
841 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 836 /// an error.
842 * error. 837 ///
843 * 838 /// If the used [http.Client] completes with an error when making a REST
844 * If the used [http.Client] completes with an error when making a REST call, 839 /// call, this method will complete with the same error.
845 * this method will complete with the same error.
846 */
847 async.Future delete(core.String tableId) { 840 async.Future delete(core.String tableId) {
848 var _url = null; 841 var _url = null;
849 var _queryParams = new core.Map(); 842 var _queryParams = new core.Map();
850 var _uploadMedia = null; 843 var _uploadMedia = null;
851 var _uploadOptions = null; 844 var _uploadOptions = null;
852 var _downloadOptions = commons.DownloadOptions.Metadata; 845 var _downloadOptions = commons.DownloadOptions.Metadata;
853 var _body = null; 846 var _body = null;
854 847
855 if (tableId == null) { 848 if (tableId == null) {
856 throw new core.ArgumentError("Parameter tableId is required."); 849 throw new core.ArgumentError("Parameter tableId is required.");
857 } 850 }
858 851
859 _downloadOptions = null; 852 _downloadOptions = null;
860 853
861 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId'); 854 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId');
862 855
863 var _response = _requester.request(_url, 856 var _response = _requester.request(_url, "DELETE",
864 "DELETE", 857 body: _body,
865 body: _body, 858 queryParams: _queryParams,
866 queryParams: _queryParams, 859 uploadOptions: _uploadOptions,
867 uploadOptions: _uploadOptions, 860 uploadMedia: _uploadMedia,
868 uploadMedia: _uploadMedia, 861 downloadOptions: _downloadOptions);
869 downloadOptions: _downloadOptions);
870 return _response.then((data) => null); 862 return _response.then((data) => null);
871 } 863 }
872 864
873 /** 865 /// Retrieves a specific table by its ID.
874 * Retrieves a specific table by its ID. 866 ///
875 * 867 /// Request parameters:
876 * Request parameters: 868 ///
877 * 869 /// [tableId] - Identifier for the table being requested.
878 * [tableId] - Identifier for the table being requested. 870 ///
879 * 871 /// Completes with a [Table].
880 * Completes with a [Table]. 872 ///
881 * 873 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
882 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 874 /// an error.
883 * error. 875 ///
884 * 876 /// If the used [http.Client] completes with an error when making a REST
885 * If the used [http.Client] completes with an error when making a REST call, 877 /// call, this method will complete with the same error.
886 * this method will complete with the same error.
887 */
888 async.Future<Table> get(core.String tableId) { 878 async.Future<Table> get(core.String tableId) {
889 var _url = null; 879 var _url = null;
890 var _queryParams = new core.Map(); 880 var _queryParams = new core.Map();
891 var _uploadMedia = null; 881 var _uploadMedia = null;
892 var _uploadOptions = null; 882 var _uploadOptions = null;
893 var _downloadOptions = commons.DownloadOptions.Metadata; 883 var _downloadOptions = commons.DownloadOptions.Metadata;
894 var _body = null; 884 var _body = null;
895 885
896 if (tableId == null) { 886 if (tableId == null) {
897 throw new core.ArgumentError("Parameter tableId is required."); 887 throw new core.ArgumentError("Parameter tableId is required.");
898 } 888 }
899 889
900 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId'); 890 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId');
901 891
902 var _response = _requester.request(_url, 892 var _response = _requester.request(_url, "GET",
903 "GET", 893 body: _body,
904 body: _body, 894 queryParams: _queryParams,
905 queryParams: _queryParams, 895 uploadOptions: _uploadOptions,
906 uploadOptions: _uploadOptions, 896 uploadMedia: _uploadMedia,
907 uploadMedia: _uploadMedia, 897 downloadOptions: _downloadOptions);
908 downloadOptions: _downloadOptions);
909 return _response.then((data) => new Table.fromJson(data)); 898 return _response.then((data) => new Table.fromJson(data));
910 } 899 }
911 900
912 /** 901 /// Imports more rows into a table.
913 * Imports more rows into a table. 902 ///
914 * 903 /// Request parameters:
915 * Request parameters: 904 ///
916 * 905 /// [tableId] - The table into which new rows are being imported.
917 * [tableId] - The table into which new rows are being imported. 906 ///
918 * 907 /// [delimiter] - The delimiter used to separate cell values. This can only
919 * [delimiter] - The delimiter used to separate cell values. This can only 908 /// consist of a single character. Default is ,.
920 * consist of a single character. Default is ,. 909 ///
921 * 910 /// [encoding] - The encoding of the content. Default is UTF-8. Use
922 * [encoding] - The encoding of the content. Default is UTF-8. Use auto-detect 911 /// auto-detect if you are unsure of the encoding.
923 * if you are unsure of the encoding. 912 ///
924 * 913 /// [endLine] - The index of the line up to which data will be imported.
925 * [endLine] - The index of the line up to which data will be imported. 914 /// Default is to import the entire file. If endLine is negative, it is an
926 * Default is to import the entire file. If endLine is negative, it is an 915 /// offset from the end of the file; the imported content will exclude the
927 * offset from the end of the file; the imported content will exclude the last 916 /// last endLine lines.
928 * endLine lines. 917 ///
929 * 918 /// [isStrict] - Whether the imported CSV must have the same number of values
930 * [isStrict] - Whether the imported CSV must have the same number of values 919 /// for each row. If false, rows with fewer values will be padded with empty
931 * for each row. If false, rows with fewer values will be padded with empty 920 /// values. Default is true.
932 * values. Default is true. 921 ///
933 * 922 /// [startLine] - The index of the first line from which to start importing,
934 * [startLine] - The index of the first line from which to start importing, 923 /// inclusive. Default is 0.
935 * inclusive. Default is 0. 924 ///
936 * 925 /// [uploadMedia] - The media to upload.
937 * [uploadMedia] - The media to upload. 926 ///
938 * 927 /// [uploadOptions] - Options for the media upload. Streaming Media without
939 * [uploadOptions] - Options for the media upload. Streaming Media without the 928 /// the length being known ahead of time is only supported via resumable
940 * length being known ahead of time is only supported via resumable uploads. 929 /// uploads.
941 * 930 ///
942 * Completes with a [Import]. 931 /// Completes with a [Import].
943 * 932 ///
944 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 933 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
945 * error. 934 /// an error.
946 * 935 ///
947 * If the used [http.Client] completes with an error when making a REST call, 936 /// If the used [http.Client] completes with an error when making a REST
948 * this method will complete with the same error. 937 /// call, this method will complete with the same error.
949 */ 938 async.Future<Import> importRows(core.String tableId,
950 async.Future<Import> importRows(core.String tableId, {core.String delimiter, c ore.String encoding, core.int endLine, core.bool isStrict, core.int startLine, c ommons.UploadOptions uploadOptions : commons.UploadOptions.Default, commons.Medi a uploadMedia}) { 939 {core.String delimiter,
940 core.String encoding,
941 core.int endLine,
942 core.bool isStrict,
943 core.int startLine,
944 commons.UploadOptions uploadOptions: commons.UploadOptions.Default,
945 commons.Media uploadMedia}) {
951 var _url = null; 946 var _url = null;
952 var _queryParams = new core.Map(); 947 var _queryParams = new core.Map();
953 var _uploadMedia = null; 948 var _uploadMedia = null;
954 var _uploadOptions = null; 949 var _uploadOptions = null;
955 var _downloadOptions = commons.DownloadOptions.Metadata; 950 var _downloadOptions = commons.DownloadOptions.Metadata;
956 var _body = null; 951 var _body = null;
957 952
958 if (tableId == null) { 953 if (tableId == null) {
959 throw new core.ArgumentError("Parameter tableId is required."); 954 throw new core.ArgumentError("Parameter tableId is required.");
960 } 955 }
961 if (delimiter != null) { 956 if (delimiter != null) {
962 _queryParams["delimiter"] = [delimiter]; 957 _queryParams["delimiter"] = [delimiter];
963 } 958 }
964 if (encoding != null) { 959 if (encoding != null) {
965 _queryParams["encoding"] = [encoding]; 960 _queryParams["encoding"] = [encoding];
966 } 961 }
967 if (endLine != null) { 962 if (endLine != null) {
968 _queryParams["endLine"] = ["${endLine}"]; 963 _queryParams["endLine"] = ["${endLine}"];
969 } 964 }
970 if (isStrict != null) { 965 if (isStrict != null) {
971 _queryParams["isStrict"] = ["${isStrict}"]; 966 _queryParams["isStrict"] = ["${isStrict}"];
972 } 967 }
973 if (startLine != null) { 968 if (startLine != null) {
974 _queryParams["startLine"] = ["${startLine}"]; 969 _queryParams["startLine"] = ["${startLine}"];
975 } 970 }
976 971
977 _uploadMedia = uploadMedia; 972 _uploadMedia = uploadMedia;
978 _uploadOptions = uploadOptions; 973 _uploadOptions = uploadOptions;
979 974
980 if (_uploadMedia == null) { 975 if (_uploadMedia == null) {
981 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/import'; 976 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/import';
982 } else if (_uploadOptions is commons.ResumableUploadOptions) { 977 } else if (_uploadOptions is commons.ResumableUploadOptions) {
983 _url = '/resumable/upload/fusiontables/v2/tables/' + commons.Escaper.ecape Variable('$tableId') + '/import'; 978 _url = '/resumable/upload/fusiontables/v2/tables/' +
979 commons.Escaper.ecapeVariable('$tableId') +
980 '/import';
984 } else { 981 } else {
985 _url = '/upload/fusiontables/v2/tables/' + commons.Escaper.ecapeVariable(' $tableId') + '/import'; 982 _url = '/upload/fusiontables/v2/tables/' +
983 commons.Escaper.ecapeVariable('$tableId') +
984 '/import';
986 } 985 }
987 986
988 987 var _response = _requester.request(_url, "POST",
989 var _response = _requester.request(_url, 988 body: _body,
990 "POST", 989 queryParams: _queryParams,
991 body: _body, 990 uploadOptions: _uploadOptions,
992 queryParams: _queryParams, 991 uploadMedia: _uploadMedia,
993 uploadOptions: _uploadOptions, 992 downloadOptions: _downloadOptions);
994 uploadMedia: _uploadMedia,
995 downloadOptions: _downloadOptions);
996 return _response.then((data) => new Import.fromJson(data)); 993 return _response.then((data) => new Import.fromJson(data));
997 } 994 }
998 995
999 /** 996 /// Imports a new table.
1000 * Imports a new table. 997 ///
1001 * 998 /// Request parameters:
1002 * Request parameters: 999 ///
1003 * 1000 /// [name] - The name to be assigned to the new table.
1004 * [name] - The name to be assigned to the new table. 1001 ///
1005 * 1002 /// [delimiter] - The delimiter used to separate cell values. This can only
1006 * [delimiter] - The delimiter used to separate cell values. This can only 1003 /// consist of a single character. Default is ,.
1007 * consist of a single character. Default is ,. 1004 ///
1008 * 1005 /// [encoding] - The encoding of the content. Default is UTF-8. Use
1009 * [encoding] - The encoding of the content. Default is UTF-8. Use auto-detect 1006 /// auto-detect if you are unsure of the encoding.
1010 * if you are unsure of the encoding. 1007 ///
1011 * 1008 /// [uploadMedia] - The media to upload.
1012 * [uploadMedia] - The media to upload. 1009 ///
1013 * 1010 /// [uploadOptions] - Options for the media upload. Streaming Media without
1014 * [uploadOptions] - Options for the media upload. Streaming Media without the 1011 /// the length being known ahead of time is only supported via resumable
1015 * length being known ahead of time is only supported via resumable uploads. 1012 /// uploads.
1016 * 1013 ///
1017 * Completes with a [Table]. 1014 /// Completes with a [Table].
1018 * 1015 ///
1019 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1016 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1020 * error. 1017 /// an error.
1021 * 1018 ///
1022 * If the used [http.Client] completes with an error when making a REST call, 1019 /// If the used [http.Client] completes with an error when making a REST
1023 * this method will complete with the same error. 1020 /// call, this method will complete with the same error.
1024 */ 1021 async.Future<Table> importTable(core.String name,
1025 async.Future<Table> importTable(core.String name, {core.String delimiter, core .String encoding, commons.UploadOptions uploadOptions : commons.UploadOptions.De fault, commons.Media uploadMedia}) { 1022 {core.String delimiter,
1023 core.String encoding,
1024 commons.UploadOptions uploadOptions: commons.UploadOptions.Default,
1025 commons.Media uploadMedia}) {
1026 var _url = null; 1026 var _url = null;
1027 var _queryParams = new core.Map(); 1027 var _queryParams = new core.Map();
1028 var _uploadMedia = null; 1028 var _uploadMedia = null;
1029 var _uploadOptions = null; 1029 var _uploadOptions = null;
1030 var _downloadOptions = commons.DownloadOptions.Metadata; 1030 var _downloadOptions = commons.DownloadOptions.Metadata;
1031 var _body = null; 1031 var _body = null;
1032 1032
1033 if (name == null) { 1033 if (name == null) {
1034 throw new core.ArgumentError("Parameter name is required."); 1034 throw new core.ArgumentError("Parameter name is required.");
1035 } 1035 }
1036 _queryParams["name"] = [name]; 1036 _queryParams["name"] = [name];
1037 if (delimiter != null) { 1037 if (delimiter != null) {
1038 _queryParams["delimiter"] = [delimiter]; 1038 _queryParams["delimiter"] = [delimiter];
1039 } 1039 }
1040 if (encoding != null) { 1040 if (encoding != null) {
1041 _queryParams["encoding"] = [encoding]; 1041 _queryParams["encoding"] = [encoding];
1042 } 1042 }
1043 1043
1044 _uploadMedia = uploadMedia; 1044 _uploadMedia = uploadMedia;
1045 _uploadOptions = uploadOptions; 1045 _uploadOptions = uploadOptions;
1046 1046
1047 if (_uploadMedia == null) { 1047 if (_uploadMedia == null) {
1048 _url = 'tables/import'; 1048 _url = 'tables/import';
1049 } else if (_uploadOptions is commons.ResumableUploadOptions) { 1049 } else if (_uploadOptions is commons.ResumableUploadOptions) {
1050 _url = '/resumable/upload/fusiontables/v2/tables/import'; 1050 _url = '/resumable/upload/fusiontables/v2/tables/import';
1051 } else { 1051 } else {
1052 _url = '/upload/fusiontables/v2/tables/import'; 1052 _url = '/upload/fusiontables/v2/tables/import';
1053 } 1053 }
1054 1054
1055 1055 var _response = _requester.request(_url, "POST",
1056 var _response = _requester.request(_url, 1056 body: _body,
1057 "POST", 1057 queryParams: _queryParams,
1058 body: _body, 1058 uploadOptions: _uploadOptions,
1059 queryParams: _queryParams, 1059 uploadMedia: _uploadMedia,
1060 uploadOptions: _uploadOptions, 1060 downloadOptions: _downloadOptions);
1061 uploadMedia: _uploadMedia,
1062 downloadOptions: _downloadOptions);
1063 return _response.then((data) => new Table.fromJson(data)); 1061 return _response.then((data) => new Table.fromJson(data));
1064 } 1062 }
1065 1063
1066 /** 1064 /// Creates a new table.
1067 * Creates a new table. 1065 ///
1068 * 1066 /// [request] - The metadata request object.
1069 * [request] - The metadata request object. 1067 ///
1070 * 1068 /// Request parameters:
1071 * Request parameters: 1069 ///
1072 * 1070 /// Completes with a [Table].
1073 * Completes with a [Table]. 1071 ///
1074 * 1072 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1075 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1073 /// an error.
1076 * error. 1074 ///
1077 * 1075 /// If the used [http.Client] completes with an error when making a REST
1078 * If the used [http.Client] completes with an error when making a REST call, 1076 /// call, this method will complete with the same error.
1079 * this method will complete with the same error.
1080 */
1081 async.Future<Table> insert(Table request) { 1077 async.Future<Table> insert(Table request) {
1082 var _url = null; 1078 var _url = null;
1083 var _queryParams = new core.Map(); 1079 var _queryParams = new core.Map();
1084 var _uploadMedia = null; 1080 var _uploadMedia = null;
1085 var _uploadOptions = null; 1081 var _uploadOptions = null;
1086 var _downloadOptions = commons.DownloadOptions.Metadata; 1082 var _downloadOptions = commons.DownloadOptions.Metadata;
1087 var _body = null; 1083 var _body = null;
1088 1084
1089 if (request != null) { 1085 if (request != null) {
1090 _body = convert.JSON.encode((request).toJson()); 1086 _body = convert.JSON.encode((request).toJson());
1091 } 1087 }
1092 1088
1093 _url = 'tables'; 1089 _url = 'tables';
1094 1090
1095 var _response = _requester.request(_url, 1091 var _response = _requester.request(_url, "POST",
1096 "POST", 1092 body: _body,
1097 body: _body, 1093 queryParams: _queryParams,
1098 queryParams: _queryParams, 1094 uploadOptions: _uploadOptions,
1099 uploadOptions: _uploadOptions, 1095 uploadMedia: _uploadMedia,
1100 uploadMedia: _uploadMedia, 1096 downloadOptions: _downloadOptions);
1101 downloadOptions: _downloadOptions);
1102 return _response.then((data) => new Table.fromJson(data)); 1097 return _response.then((data) => new Table.fromJson(data));
1103 } 1098 }
1104 1099
1105 /** 1100 /// Retrieves a list of tables a user owns.
1106 * Retrieves a list of tables a user owns. 1101 ///
1107 * 1102 /// Request parameters:
1108 * Request parameters: 1103 ///
1109 * 1104 /// [maxResults] - Maximum number of tables to return. Default is 5.
1110 * [maxResults] - Maximum number of tables to return. Default is 5. 1105 ///
1111 * 1106 /// [pageToken] - Continuation token specifying which result page to return.
1112 * [pageToken] - Continuation token specifying which result page to return. 1107 ///
1113 * 1108 /// Completes with a [TableList].
1114 * Completes with a [TableList]. 1109 ///
1115 * 1110 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1116 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1111 /// an error.
1117 * error. 1112 ///
1118 * 1113 /// If the used [http.Client] completes with an error when making a REST
1119 * If the used [http.Client] completes with an error when making a REST call, 1114 /// call, this method will complete with the same error.
1120 * this method will complete with the same error.
1121 */
1122 async.Future<TableList> list({core.int maxResults, core.String pageToken}) { 1115 async.Future<TableList> list({core.int maxResults, core.String pageToken}) {
1123 var _url = null; 1116 var _url = null;
1124 var _queryParams = new core.Map(); 1117 var _queryParams = new core.Map();
1125 var _uploadMedia = null; 1118 var _uploadMedia = null;
1126 var _uploadOptions = null; 1119 var _uploadOptions = null;
1127 var _downloadOptions = commons.DownloadOptions.Metadata; 1120 var _downloadOptions = commons.DownloadOptions.Metadata;
1128 var _body = null; 1121 var _body = null;
1129 1122
1130 if (maxResults != null) { 1123 if (maxResults != null) {
1131 _queryParams["maxResults"] = ["${maxResults}"]; 1124 _queryParams["maxResults"] = ["${maxResults}"];
1132 } 1125 }
1133 if (pageToken != null) { 1126 if (pageToken != null) {
1134 _queryParams["pageToken"] = [pageToken]; 1127 _queryParams["pageToken"] = [pageToken];
1135 } 1128 }
1136 1129
1137 _url = 'tables'; 1130 _url = 'tables';
1138 1131
1139 var _response = _requester.request(_url, 1132 var _response = _requester.request(_url, "GET",
1140 "GET", 1133 body: _body,
1141 body: _body, 1134 queryParams: _queryParams,
1142 queryParams: _queryParams, 1135 uploadOptions: _uploadOptions,
1143 uploadOptions: _uploadOptions, 1136 uploadMedia: _uploadMedia,
1144 uploadMedia: _uploadMedia, 1137 downloadOptions: _downloadOptions);
1145 downloadOptions: _downloadOptions);
1146 return _response.then((data) => new TableList.fromJson(data)); 1138 return _response.then((data) => new TableList.fromJson(data));
1147 } 1139 }
1148 1140
1149 /** 1141 /// Updates an existing table. Unless explicitly requested, only the name,
1150 * Updates an existing table. Unless explicitly requested, only the name, 1142 /// description, and attribution will be updated. This method supports patch
1151 * description, and attribution will be updated. This method supports patch 1143 /// semantics.
1152 * semantics. 1144 ///
1153 * 1145 /// [request] - The metadata request object.
1154 * [request] - The metadata request object. 1146 ///
1155 * 1147 /// Request parameters:
1156 * Request parameters: 1148 ///
1157 * 1149 /// [tableId] - ID of the table that is being updated.
1158 * [tableId] - ID of the table that is being updated. 1150 ///
1159 * 1151 /// [replaceViewDefinition] - Whether the view definition is also updated.
1160 * [replaceViewDefinition] - Whether the view definition is also updated. The 1152 /// The specified view definition replaces the existing one. Only a view can
1161 * specified view definition replaces the existing one. Only a view can be 1153 /// be updated with a new definition.
1162 * updated with a new definition. 1154 ///
1163 * 1155 /// Completes with a [Table].
1164 * Completes with a [Table]. 1156 ///
1165 * 1157 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1166 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1158 /// an error.
1167 * error. 1159 ///
1168 * 1160 /// If the used [http.Client] completes with an error when making a REST
1169 * If the used [http.Client] completes with an error when making a REST call, 1161 /// call, this method will complete with the same error.
1170 * this method will complete with the same error. 1162 async.Future<Table> patch(Table request, core.String tableId,
1171 */ 1163 {core.bool replaceViewDefinition}) {
1172 async.Future<Table> patch(Table request, core.String tableId, {core.bool repla ceViewDefinition}) {
1173 var _url = null; 1164 var _url = null;
1174 var _queryParams = new core.Map(); 1165 var _queryParams = new core.Map();
1175 var _uploadMedia = null; 1166 var _uploadMedia = null;
1176 var _uploadOptions = null; 1167 var _uploadOptions = null;
1177 var _downloadOptions = commons.DownloadOptions.Metadata; 1168 var _downloadOptions = commons.DownloadOptions.Metadata;
1178 var _body = null; 1169 var _body = null;
1179 1170
1180 if (request != null) { 1171 if (request != null) {
1181 _body = convert.JSON.encode((request).toJson()); 1172 _body = convert.JSON.encode((request).toJson());
1182 } 1173 }
1183 if (tableId == null) { 1174 if (tableId == null) {
1184 throw new core.ArgumentError("Parameter tableId is required."); 1175 throw new core.ArgumentError("Parameter tableId is required.");
1185 } 1176 }
1186 if (replaceViewDefinition != null) { 1177 if (replaceViewDefinition != null) {
1187 _queryParams["replaceViewDefinition"] = ["${replaceViewDefinition}"]; 1178 _queryParams["replaceViewDefinition"] = ["${replaceViewDefinition}"];
1188 } 1179 }
1189 1180
1190 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId'); 1181 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId');
1191 1182
1192 var _response = _requester.request(_url, 1183 var _response = _requester.request(_url, "PATCH",
1193 "PATCH", 1184 body: _body,
1194 body: _body, 1185 queryParams: _queryParams,
1195 queryParams: _queryParams, 1186 uploadOptions: _uploadOptions,
1196 uploadOptions: _uploadOptions, 1187 uploadMedia: _uploadMedia,
1197 uploadMedia: _uploadMedia, 1188 downloadOptions: _downloadOptions);
1198 downloadOptions: _downloadOptions);
1199 return _response.then((data) => new Table.fromJson(data)); 1189 return _response.then((data) => new Table.fromJson(data));
1200 } 1190 }
1201 1191
1202 /** 1192 /// Replaces rows of an existing table. Current rows remain visible until all
1203 * Replaces rows of an existing table. Current rows remain visible until all 1193 /// replacement rows are ready.
1204 * replacement rows are ready. 1194 ///
1205 * 1195 /// Request parameters:
1206 * Request parameters: 1196 ///
1207 * 1197 /// [tableId] - Table whose rows will be replaced.
1208 * [tableId] - Table whose rows will be replaced. 1198 ///
1209 * 1199 /// [delimiter] - The delimiter used to separate cell values. This can only
1210 * [delimiter] - The delimiter used to separate cell values. This can only 1200 /// consist of a single character. Default is ,.
1211 * consist of a single character. Default is ,. 1201 ///
1212 * 1202 /// [encoding] - The encoding of the content. Default is UTF-8. Use
1213 * [encoding] - The encoding of the content. Default is UTF-8. Use 1203 /// 'auto-detect' if you are unsure of the encoding.
1214 * 'auto-detect' if you are unsure of the encoding. 1204 ///
1215 * 1205 /// [endLine] - The index of the line up to which data will be imported.
1216 * [endLine] - The index of the line up to which data will be imported. 1206 /// Default is to import the entire file. If endLine is negative, it is an
1217 * Default is to import the entire file. If endLine is negative, it is an 1207 /// offset from the end of the file; the imported content will exclude the
1218 * offset from the end of the file; the imported content will exclude the last 1208 /// last endLine lines.
1219 * endLine lines. 1209 ///
1220 * 1210 /// [isStrict] - Whether the imported CSV must have the same number of column
1221 * [isStrict] - Whether the imported CSV must have the same number of column 1211 /// values for each row. If true, throws an exception if the CSV does not
1222 * values for each row. If true, throws an exception if the CSV does not have 1212 /// have the same number of columns. If false, rows with fewer column values
1223 * the same number of columns. If false, rows with fewer column values will be 1213 /// will be padded with empty values. Default is true.
1224 * padded with empty values. Default is true. 1214 ///
1225 * 1215 /// [startLine] - The index of the first line from which to start importing,
1226 * [startLine] - The index of the first line from which to start importing, 1216 /// inclusive. Default is 0.
1227 * inclusive. Default is 0. 1217 ///
1228 * 1218 /// [uploadMedia] - The media to upload.
1229 * [uploadMedia] - The media to upload. 1219 ///
1230 * 1220 /// [uploadOptions] - Options for the media upload. Streaming Media without
1231 * [uploadOptions] - Options for the media upload. Streaming Media without the 1221 /// the length being known ahead of time is only supported via resumable
1232 * length being known ahead of time is only supported via resumable uploads. 1222 /// uploads.
1233 * 1223 ///
1234 * Completes with a [Task]. 1224 /// Completes with a [Task].
1235 * 1225 ///
1236 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1226 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1237 * error. 1227 /// an error.
1238 * 1228 ///
1239 * If the used [http.Client] completes with an error when making a REST call, 1229 /// If the used [http.Client] completes with an error when making a REST
1240 * this method will complete with the same error. 1230 /// call, this method will complete with the same error.
1241 */ 1231 async.Future<Task> replaceRows(core.String tableId,
1242 async.Future<Task> replaceRows(core.String tableId, {core.String delimiter, co re.String encoding, core.int endLine, core.bool isStrict, core.int startLine, co mmons.UploadOptions uploadOptions : commons.UploadOptions.Default, commons.Media uploadMedia}) { 1232 {core.String delimiter,
1233 core.String encoding,
1234 core.int endLine,
1235 core.bool isStrict,
1236 core.int startLine,
1237 commons.UploadOptions uploadOptions: commons.UploadOptions.Default,
1238 commons.Media uploadMedia}) {
1243 var _url = null; 1239 var _url = null;
1244 var _queryParams = new core.Map(); 1240 var _queryParams = new core.Map();
1245 var _uploadMedia = null; 1241 var _uploadMedia = null;
1246 var _uploadOptions = null; 1242 var _uploadOptions = null;
1247 var _downloadOptions = commons.DownloadOptions.Metadata; 1243 var _downloadOptions = commons.DownloadOptions.Metadata;
1248 var _body = null; 1244 var _body = null;
1249 1245
1250 if (tableId == null) { 1246 if (tableId == null) {
1251 throw new core.ArgumentError("Parameter tableId is required."); 1247 throw new core.ArgumentError("Parameter tableId is required.");
1252 } 1248 }
1253 if (delimiter != null) { 1249 if (delimiter != null) {
1254 _queryParams["delimiter"] = [delimiter]; 1250 _queryParams["delimiter"] = [delimiter];
1255 } 1251 }
1256 if (encoding != null) { 1252 if (encoding != null) {
1257 _queryParams["encoding"] = [encoding]; 1253 _queryParams["encoding"] = [encoding];
1258 } 1254 }
1259 if (endLine != null) { 1255 if (endLine != null) {
1260 _queryParams["endLine"] = ["${endLine}"]; 1256 _queryParams["endLine"] = ["${endLine}"];
1261 } 1257 }
1262 if (isStrict != null) { 1258 if (isStrict != null) {
1263 _queryParams["isStrict"] = ["${isStrict}"]; 1259 _queryParams["isStrict"] = ["${isStrict}"];
1264 } 1260 }
1265 if (startLine != null) { 1261 if (startLine != null) {
1266 _queryParams["startLine"] = ["${startLine}"]; 1262 _queryParams["startLine"] = ["${startLine}"];
1267 } 1263 }
1268 1264
1269 _uploadMedia = uploadMedia; 1265 _uploadMedia = uploadMedia;
1270 _uploadOptions = uploadOptions; 1266 _uploadOptions = uploadOptions;
1271 1267
1272 if (_uploadMedia == null) { 1268 if (_uploadMedia == null) {
1273 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/replace'; 1269 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/replace';
1274 } else if (_uploadOptions is commons.ResumableUploadOptions) { 1270 } else if (_uploadOptions is commons.ResumableUploadOptions) {
1275 _url = '/resumable/upload/fusiontables/v2/tables/' + commons.Escaper.ecape Variable('$tableId') + '/replace'; 1271 _url = '/resumable/upload/fusiontables/v2/tables/' +
1272 commons.Escaper.ecapeVariable('$tableId') +
1273 '/replace';
1276 } else { 1274 } else {
1277 _url = '/upload/fusiontables/v2/tables/' + commons.Escaper.ecapeVariable(' $tableId') + '/replace'; 1275 _url = '/upload/fusiontables/v2/tables/' +
1276 commons.Escaper.ecapeVariable('$tableId') +
1277 '/replace';
1278 } 1278 }
1279 1279
1280 1280 var _response = _requester.request(_url, "POST",
1281 var _response = _requester.request(_url, 1281 body: _body,
1282 "POST", 1282 queryParams: _queryParams,
1283 body: _body, 1283 uploadOptions: _uploadOptions,
1284 queryParams: _queryParams, 1284 uploadMedia: _uploadMedia,
1285 uploadOptions: _uploadOptions, 1285 downloadOptions: _downloadOptions);
1286 uploadMedia: _uploadMedia,
1287 downloadOptions: _downloadOptions);
1288 return _response.then((data) => new Task.fromJson(data)); 1286 return _response.then((data) => new Task.fromJson(data));
1289 } 1287 }
1290 1288
1291 /** 1289 /// Updates an existing table. Unless explicitly requested, only the name,
1292 * Updates an existing table. Unless explicitly requested, only the name, 1290 /// description, and attribution will be updated.
1293 * description, and attribution will be updated. 1291 ///
1294 * 1292 /// [request] - The metadata request object.
1295 * [request] - The metadata request object. 1293 ///
1296 * 1294 /// Request parameters:
1297 * Request parameters: 1295 ///
1298 * 1296 /// [tableId] - ID of the table that is being updated.
1299 * [tableId] - ID of the table that is being updated. 1297 ///
1300 * 1298 /// [replaceViewDefinition] - Whether the view definition is also updated.
1301 * [replaceViewDefinition] - Whether the view definition is also updated. The 1299 /// The specified view definition replaces the existing one. Only a view can
1302 * specified view definition replaces the existing one. Only a view can be 1300 /// be updated with a new definition.
1303 * updated with a new definition. 1301 ///
1304 * 1302 /// Completes with a [Table].
1305 * Completes with a [Table]. 1303 ///
1306 * 1304 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1307 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1305 /// an error.
1308 * error. 1306 ///
1309 * 1307 /// If the used [http.Client] completes with an error when making a REST
1310 * If the used [http.Client] completes with an error when making a REST call, 1308 /// call, this method will complete with the same error.
1311 * this method will complete with the same error. 1309 async.Future<Table> update(Table request, core.String tableId,
1312 */ 1310 {core.bool replaceViewDefinition}) {
1313 async.Future<Table> update(Table request, core.String tableId, {core.bool repl aceViewDefinition}) {
1314 var _url = null; 1311 var _url = null;
1315 var _queryParams = new core.Map(); 1312 var _queryParams = new core.Map();
1316 var _uploadMedia = null; 1313 var _uploadMedia = null;
1317 var _uploadOptions = null; 1314 var _uploadOptions = null;
1318 var _downloadOptions = commons.DownloadOptions.Metadata; 1315 var _downloadOptions = commons.DownloadOptions.Metadata;
1319 var _body = null; 1316 var _body = null;
1320 1317
1321 if (request != null) { 1318 if (request != null) {
1322 _body = convert.JSON.encode((request).toJson()); 1319 _body = convert.JSON.encode((request).toJson());
1323 } 1320 }
1324 if (tableId == null) { 1321 if (tableId == null) {
1325 throw new core.ArgumentError("Parameter tableId is required."); 1322 throw new core.ArgumentError("Parameter tableId is required.");
1326 } 1323 }
1327 if (replaceViewDefinition != null) { 1324 if (replaceViewDefinition != null) {
1328 _queryParams["replaceViewDefinition"] = ["${replaceViewDefinition}"]; 1325 _queryParams["replaceViewDefinition"] = ["${replaceViewDefinition}"];
1329 } 1326 }
1330 1327
1331 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId'); 1328 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId');
1332 1329
1333 var _response = _requester.request(_url, 1330 var _response = _requester.request(_url, "PUT",
1334 "PUT", 1331 body: _body,
1335 body: _body, 1332 queryParams: _queryParams,
1336 queryParams: _queryParams, 1333 uploadOptions: _uploadOptions,
1337 uploadOptions: _uploadOptions, 1334 uploadMedia: _uploadMedia,
1338 uploadMedia: _uploadMedia, 1335 downloadOptions: _downloadOptions);
1339 downloadOptions: _downloadOptions);
1340 return _response.then((data) => new Table.fromJson(data)); 1336 return _response.then((data) => new Table.fromJson(data));
1341 } 1337 }
1342
1343 } 1338 }
1344 1339
1345
1346 class TaskResourceApi { 1340 class TaskResourceApi {
1347 final commons.ApiRequester _requester; 1341 final commons.ApiRequester _requester;
1348 1342
1349 TaskResourceApi(commons.ApiRequester client) : 1343 TaskResourceApi(commons.ApiRequester client) : _requester = client;
1350 _requester = client;
1351 1344
1352 /** 1345 /// Deletes a specific task by its ID, unless that task has already started
1353 * Deletes a specific task by its ID, unless that task has already started 1346 /// running.
1354 * running. 1347 ///
1355 * 1348 /// Request parameters:
1356 * Request parameters: 1349 ///
1357 * 1350 /// [tableId] - Table from which the task is being deleted.
1358 * [tableId] - Table from which the task is being deleted. 1351 ///
1359 * 1352 /// [taskId] - The identifier of the task to delete.
1360 * [taskId] - The identifier of the task to delete. 1353 ///
1361 * 1354 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1362 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1355 /// an error.
1363 * error. 1356 ///
1364 * 1357 /// If the used [http.Client] completes with an error when making a REST
1365 * If the used [http.Client] completes with an error when making a REST call, 1358 /// call, this method will complete with the same error.
1366 * this method will complete with the same error.
1367 */
1368 async.Future delete(core.String tableId, core.String taskId) { 1359 async.Future delete(core.String tableId, core.String taskId) {
1369 var _url = null; 1360 var _url = null;
1370 var _queryParams = new core.Map(); 1361 var _queryParams = new core.Map();
1371 var _uploadMedia = null; 1362 var _uploadMedia = null;
1372 var _uploadOptions = null; 1363 var _uploadOptions = null;
1373 var _downloadOptions = commons.DownloadOptions.Metadata; 1364 var _downloadOptions = commons.DownloadOptions.Metadata;
1374 var _body = null; 1365 var _body = null;
1375 1366
1376 if (tableId == null) { 1367 if (tableId == null) {
1377 throw new core.ArgumentError("Parameter tableId is required."); 1368 throw new core.ArgumentError("Parameter tableId is required.");
1378 } 1369 }
1379 if (taskId == null) { 1370 if (taskId == null) {
1380 throw new core.ArgumentError("Parameter taskId is required."); 1371 throw new core.ArgumentError("Parameter taskId is required.");
1381 } 1372 }
1382 1373
1383 _downloadOptions = null; 1374 _downloadOptions = null;
1384 1375
1385 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/tasks/' + c ommons.Escaper.ecapeVariable('$taskId'); 1376 _url = 'tables/' +
1377 commons.Escaper.ecapeVariable('$tableId') +
1378 '/tasks/' +
1379 commons.Escaper.ecapeVariable('$taskId');
1386 1380
1387 var _response = _requester.request(_url, 1381 var _response = _requester.request(_url, "DELETE",
1388 "DELETE", 1382 body: _body,
1389 body: _body, 1383 queryParams: _queryParams,
1390 queryParams: _queryParams, 1384 uploadOptions: _uploadOptions,
1391 uploadOptions: _uploadOptions, 1385 uploadMedia: _uploadMedia,
1392 uploadMedia: _uploadMedia, 1386 downloadOptions: _downloadOptions);
1393 downloadOptions: _downloadOptions);
1394 return _response.then((data) => null); 1387 return _response.then((data) => null);
1395 } 1388 }
1396 1389
1397 /** 1390 /// Retrieves a specific task by its ID.
1398 * Retrieves a specific task by its ID. 1391 ///
1399 * 1392 /// Request parameters:
1400 * Request parameters: 1393 ///
1401 * 1394 /// [tableId] - Table to which the task belongs.
1402 * [tableId] - Table to which the task belongs. 1395 ///
1403 * 1396 /// [taskId] - The identifier of the task to get.
1404 * [taskId] - The identifier of the task to get. 1397 ///
1405 * 1398 /// Completes with a [Task].
1406 * Completes with a [Task]. 1399 ///
1407 * 1400 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1408 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1401 /// an error.
1409 * error. 1402 ///
1410 * 1403 /// If the used [http.Client] completes with an error when making a REST
1411 * If the used [http.Client] completes with an error when making a REST call, 1404 /// call, this method will complete with the same error.
1412 * this method will complete with the same error.
1413 */
1414 async.Future<Task> get(core.String tableId, core.String taskId) { 1405 async.Future<Task> get(core.String tableId, core.String taskId) {
1415 var _url = null; 1406 var _url = null;
1416 var _queryParams = new core.Map(); 1407 var _queryParams = new core.Map();
1417 var _uploadMedia = null; 1408 var _uploadMedia = null;
1418 var _uploadOptions = null; 1409 var _uploadOptions = null;
1419 var _downloadOptions = commons.DownloadOptions.Metadata; 1410 var _downloadOptions = commons.DownloadOptions.Metadata;
1420 var _body = null; 1411 var _body = null;
1421 1412
1422 if (tableId == null) { 1413 if (tableId == null) {
1423 throw new core.ArgumentError("Parameter tableId is required."); 1414 throw new core.ArgumentError("Parameter tableId is required.");
1424 } 1415 }
1425 if (taskId == null) { 1416 if (taskId == null) {
1426 throw new core.ArgumentError("Parameter taskId is required."); 1417 throw new core.ArgumentError("Parameter taskId is required.");
1427 } 1418 }
1428 1419
1429 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/tasks/' + c ommons.Escaper.ecapeVariable('$taskId'); 1420 _url = 'tables/' +
1421 commons.Escaper.ecapeVariable('$tableId') +
1422 '/tasks/' +
1423 commons.Escaper.ecapeVariable('$taskId');
1430 1424
1431 var _response = _requester.request(_url, 1425 var _response = _requester.request(_url, "GET",
1432 "GET", 1426 body: _body,
1433 body: _body, 1427 queryParams: _queryParams,
1434 queryParams: _queryParams, 1428 uploadOptions: _uploadOptions,
1435 uploadOptions: _uploadOptions, 1429 uploadMedia: _uploadMedia,
1436 uploadMedia: _uploadMedia, 1430 downloadOptions: _downloadOptions);
1437 downloadOptions: _downloadOptions);
1438 return _response.then((data) => new Task.fromJson(data)); 1431 return _response.then((data) => new Task.fromJson(data));
1439 } 1432 }
1440 1433
1441 /** 1434 /// Retrieves a list of tasks.
1442 * Retrieves a list of tasks. 1435 ///
1443 * 1436 /// Request parameters:
1444 * Request parameters: 1437 ///
1445 * 1438 /// [tableId] - Table whose tasks are being listed.
1446 * [tableId] - Table whose tasks are being listed. 1439 ///
1447 * 1440 /// [maxResults] - Maximum number of tasks to return. Default is 5.
1448 * [maxResults] - Maximum number of tasks to return. Default is 5. 1441 ///
1449 * 1442 /// [pageToken] - Continuation token specifying which result page to return.
1450 * [pageToken] - Continuation token specifying which result page to return. 1443 ///
1451 * 1444 /// [startIndex] - Index of the first result returned in the current page.
1452 * [startIndex] - Index of the first result returned in the current page. 1445 ///
1453 * 1446 /// Completes with a [TaskList].
1454 * Completes with a [TaskList]. 1447 ///
1455 * 1448 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1456 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1449 /// an error.
1457 * error. 1450 ///
1458 * 1451 /// If the used [http.Client] completes with an error when making a REST
1459 * If the used [http.Client] completes with an error when making a REST call, 1452 /// call, this method will complete with the same error.
1460 * this method will complete with the same error. 1453 async.Future<TaskList> list(core.String tableId,
1461 */ 1454 {core.int maxResults, core.String pageToken, core.int startIndex}) {
1462 async.Future<TaskList> list(core.String tableId, {core.int maxResults, core.St ring pageToken, core.int startIndex}) {
1463 var _url = null; 1455 var _url = null;
1464 var _queryParams = new core.Map(); 1456 var _queryParams = new core.Map();
1465 var _uploadMedia = null; 1457 var _uploadMedia = null;
1466 var _uploadOptions = null; 1458 var _uploadOptions = null;
1467 var _downloadOptions = commons.DownloadOptions.Metadata; 1459 var _downloadOptions = commons.DownloadOptions.Metadata;
1468 var _body = null; 1460 var _body = null;
1469 1461
1470 if (tableId == null) { 1462 if (tableId == null) {
1471 throw new core.ArgumentError("Parameter tableId is required."); 1463 throw new core.ArgumentError("Parameter tableId is required.");
1472 } 1464 }
1473 if (maxResults != null) { 1465 if (maxResults != null) {
1474 _queryParams["maxResults"] = ["${maxResults}"]; 1466 _queryParams["maxResults"] = ["${maxResults}"];
1475 } 1467 }
1476 if (pageToken != null) { 1468 if (pageToken != null) {
1477 _queryParams["pageToken"] = [pageToken]; 1469 _queryParams["pageToken"] = [pageToken];
1478 } 1470 }
1479 if (startIndex != null) { 1471 if (startIndex != null) {
1480 _queryParams["startIndex"] = ["${startIndex}"]; 1472 _queryParams["startIndex"] = ["${startIndex}"];
1481 } 1473 }
1482 1474
1483 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/tasks'; 1475 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/tasks';
1484 1476
1485 var _response = _requester.request(_url, 1477 var _response = _requester.request(_url, "GET",
1486 "GET", 1478 body: _body,
1487 body: _body, 1479 queryParams: _queryParams,
1488 queryParams: _queryParams, 1480 uploadOptions: _uploadOptions,
1489 uploadOptions: _uploadOptions, 1481 uploadMedia: _uploadMedia,
1490 uploadMedia: _uploadMedia, 1482 downloadOptions: _downloadOptions);
1491 downloadOptions: _downloadOptions);
1492 return _response.then((data) => new TaskList.fromJson(data)); 1483 return _response.then((data) => new TaskList.fromJson(data));
1493 } 1484 }
1494
1495 } 1485 }
1496 1486
1497
1498 class TemplateResourceApi { 1487 class TemplateResourceApi {
1499 final commons.ApiRequester _requester; 1488 final commons.ApiRequester _requester;
1500 1489
1501 TemplateResourceApi(commons.ApiRequester client) : 1490 TemplateResourceApi(commons.ApiRequester client) : _requester = client;
1502 _requester = client;
1503 1491
1504 /** 1492 /// Deletes a template
1505 * Deletes a template 1493 ///
1506 * 1494 /// Request parameters:
1507 * Request parameters: 1495 ///
1508 * 1496 /// [tableId] - Table from which the template is being deleted
1509 * [tableId] - Table from which the template is being deleted 1497 ///
1510 * 1498 /// [templateId] - Identifier for the template which is being deleted
1511 * [templateId] - Identifier for the template which is being deleted 1499 ///
1512 * 1500 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1513 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1501 /// an error.
1514 * error. 1502 ///
1515 * 1503 /// If the used [http.Client] completes with an error when making a REST
1516 * If the used [http.Client] completes with an error when making a REST call, 1504 /// call, this method will complete with the same error.
1517 * this method will complete with the same error.
1518 */
1519 async.Future delete(core.String tableId, core.int templateId) { 1505 async.Future delete(core.String tableId, core.int templateId) {
1520 var _url = null; 1506 var _url = null;
1521 var _queryParams = new core.Map(); 1507 var _queryParams = new core.Map();
1522 var _uploadMedia = null; 1508 var _uploadMedia = null;
1523 var _uploadOptions = null; 1509 var _uploadOptions = null;
1524 var _downloadOptions = commons.DownloadOptions.Metadata; 1510 var _downloadOptions = commons.DownloadOptions.Metadata;
1525 var _body = null; 1511 var _body = null;
1526 1512
1527 if (tableId == null) { 1513 if (tableId == null) {
1528 throw new core.ArgumentError("Parameter tableId is required."); 1514 throw new core.ArgumentError("Parameter tableId is required.");
1529 } 1515 }
1530 if (templateId == null) { 1516 if (templateId == null) {
1531 throw new core.ArgumentError("Parameter templateId is required."); 1517 throw new core.ArgumentError("Parameter templateId is required.");
1532 } 1518 }
1533 1519
1534 _downloadOptions = null; 1520 _downloadOptions = null;
1535 1521
1536 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates/' + commons.Escaper.ecapeVariable('$templateId'); 1522 _url = 'tables/' +
1523 commons.Escaper.ecapeVariable('$tableId') +
1524 '/templates/' +
1525 commons.Escaper.ecapeVariable('$templateId');
1537 1526
1538 var _response = _requester.request(_url, 1527 var _response = _requester.request(_url, "DELETE",
1539 "DELETE", 1528 body: _body,
1540 body: _body, 1529 queryParams: _queryParams,
1541 queryParams: _queryParams, 1530 uploadOptions: _uploadOptions,
1542 uploadOptions: _uploadOptions, 1531 uploadMedia: _uploadMedia,
1543 uploadMedia: _uploadMedia, 1532 downloadOptions: _downloadOptions);
1544 downloadOptions: _downloadOptions);
1545 return _response.then((data) => null); 1533 return _response.then((data) => null);
1546 } 1534 }
1547 1535
1548 /** 1536 /// Retrieves a specific template by its id
1549 * Retrieves a specific template by its id 1537 ///
1550 * 1538 /// Request parameters:
1551 * Request parameters: 1539 ///
1552 * 1540 /// [tableId] - Table to which the template belongs
1553 * [tableId] - Table to which the template belongs 1541 ///
1554 * 1542 /// [templateId] - Identifier for the template that is being requested
1555 * [templateId] - Identifier for the template that is being requested 1543 ///
1556 * 1544 /// Completes with a [Template].
1557 * Completes with a [Template]. 1545 ///
1558 * 1546 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1559 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1547 /// an error.
1560 * error. 1548 ///
1561 * 1549 /// If the used [http.Client] completes with an error when making a REST
1562 * If the used [http.Client] completes with an error when making a REST call, 1550 /// call, this method will complete with the same error.
1563 * this method will complete with the same error.
1564 */
1565 async.Future<Template> get(core.String tableId, core.int templateId) { 1551 async.Future<Template> get(core.String tableId, core.int templateId) {
1566 var _url = null; 1552 var _url = null;
1567 var _queryParams = new core.Map(); 1553 var _queryParams = new core.Map();
1568 var _uploadMedia = null; 1554 var _uploadMedia = null;
1569 var _uploadOptions = null; 1555 var _uploadOptions = null;
1570 var _downloadOptions = commons.DownloadOptions.Metadata; 1556 var _downloadOptions = commons.DownloadOptions.Metadata;
1571 var _body = null; 1557 var _body = null;
1572 1558
1573 if (tableId == null) { 1559 if (tableId == null) {
1574 throw new core.ArgumentError("Parameter tableId is required."); 1560 throw new core.ArgumentError("Parameter tableId is required.");
1575 } 1561 }
1576 if (templateId == null) { 1562 if (templateId == null) {
1577 throw new core.ArgumentError("Parameter templateId is required."); 1563 throw new core.ArgumentError("Parameter templateId is required.");
1578 } 1564 }
1579 1565
1580 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates/' + commons.Escaper.ecapeVariable('$templateId'); 1566 _url = 'tables/' +
1567 commons.Escaper.ecapeVariable('$tableId') +
1568 '/templates/' +
1569 commons.Escaper.ecapeVariable('$templateId');
1581 1570
1582 var _response = _requester.request(_url, 1571 var _response = _requester.request(_url, "GET",
1583 "GET", 1572 body: _body,
1584 body: _body, 1573 queryParams: _queryParams,
1585 queryParams: _queryParams, 1574 uploadOptions: _uploadOptions,
1586 uploadOptions: _uploadOptions, 1575 uploadMedia: _uploadMedia,
1587 uploadMedia: _uploadMedia, 1576 downloadOptions: _downloadOptions);
1588 downloadOptions: _downloadOptions);
1589 return _response.then((data) => new Template.fromJson(data)); 1577 return _response.then((data) => new Template.fromJson(data));
1590 } 1578 }
1591 1579
1592 /** 1580 /// Creates a new template for the table.
1593 * Creates a new template for the table. 1581 ///
1594 * 1582 /// [request] - The metadata request object.
1595 * [request] - The metadata request object. 1583 ///
1596 * 1584 /// Request parameters:
1597 * Request parameters: 1585 ///
1598 * 1586 /// [tableId] - Table for which a new template is being created
1599 * [tableId] - Table for which a new template is being created 1587 ///
1600 * 1588 /// Completes with a [Template].
1601 * Completes with a [Template]. 1589 ///
1602 * 1590 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1603 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1591 /// an error.
1604 * error. 1592 ///
1605 * 1593 /// If the used [http.Client] completes with an error when making a REST
1606 * If the used [http.Client] completes with an error when making a REST call, 1594 /// call, this method will complete with the same error.
1607 * this method will complete with the same error.
1608 */
1609 async.Future<Template> insert(Template request, core.String tableId) { 1595 async.Future<Template> insert(Template request, core.String tableId) {
1610 var _url = null; 1596 var _url = null;
1611 var _queryParams = new core.Map(); 1597 var _queryParams = new core.Map();
1612 var _uploadMedia = null; 1598 var _uploadMedia = null;
1613 var _uploadOptions = null; 1599 var _uploadOptions = null;
1614 var _downloadOptions = commons.DownloadOptions.Metadata; 1600 var _downloadOptions = commons.DownloadOptions.Metadata;
1615 var _body = null; 1601 var _body = null;
1616 1602
1617 if (request != null) { 1603 if (request != null) {
1618 _body = convert.JSON.encode((request).toJson()); 1604 _body = convert.JSON.encode((request).toJson());
1619 } 1605 }
1620 if (tableId == null) { 1606 if (tableId == null) {
1621 throw new core.ArgumentError("Parameter tableId is required."); 1607 throw new core.ArgumentError("Parameter tableId is required.");
1622 } 1608 }
1623 1609
1624 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates'; 1610 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates';
1625 1611
1626 var _response = _requester.request(_url, 1612 var _response = _requester.request(_url, "POST",
1627 "POST", 1613 body: _body,
1628 body: _body, 1614 queryParams: _queryParams,
1629 queryParams: _queryParams, 1615 uploadOptions: _uploadOptions,
1630 uploadOptions: _uploadOptions, 1616 uploadMedia: _uploadMedia,
1631 uploadMedia: _uploadMedia, 1617 downloadOptions: _downloadOptions);
1632 downloadOptions: _downloadOptions);
1633 return _response.then((data) => new Template.fromJson(data)); 1618 return _response.then((data) => new Template.fromJson(data));
1634 } 1619 }
1635 1620
1636 /** 1621 /// Retrieves a list of templates.
1637 * Retrieves a list of templates. 1622 ///
1638 * 1623 /// Request parameters:
1639 * Request parameters: 1624 ///
1640 * 1625 /// [tableId] - Identifier for the table whose templates are being requested
1641 * [tableId] - Identifier for the table whose templates are being requested 1626 ///
1642 * 1627 /// [maxResults] - Maximum number of templates to return. Optional. Default
1643 * [maxResults] - Maximum number of templates to return. Optional. Default is 1628 /// is 5.
1644 * 5. 1629 ///
1645 * 1630 /// [pageToken] - Continuation token specifying which results page to return.
1646 * [pageToken] - Continuation token specifying which results page to return. 1631 /// Optional.
1647 * Optional. 1632 ///
1648 * 1633 /// Completes with a [TemplateList].
1649 * Completes with a [TemplateList]. 1634 ///
1650 * 1635 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1651 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1636 /// an error.
1652 * error. 1637 ///
1653 * 1638 /// If the used [http.Client] completes with an error when making a REST
1654 * If the used [http.Client] completes with an error when making a REST call, 1639 /// call, this method will complete with the same error.
1655 * this method will complete with the same error. 1640 async.Future<TemplateList> list(core.String tableId,
1656 */ 1641 {core.int maxResults, core.String pageToken}) {
1657 async.Future<TemplateList> list(core.String tableId, {core.int maxResults, cor e.String pageToken}) {
1658 var _url = null; 1642 var _url = null;
1659 var _queryParams = new core.Map(); 1643 var _queryParams = new core.Map();
1660 var _uploadMedia = null; 1644 var _uploadMedia = null;
1661 var _uploadOptions = null; 1645 var _uploadOptions = null;
1662 var _downloadOptions = commons.DownloadOptions.Metadata; 1646 var _downloadOptions = commons.DownloadOptions.Metadata;
1663 var _body = null; 1647 var _body = null;
1664 1648
1665 if (tableId == null) { 1649 if (tableId == null) {
1666 throw new core.ArgumentError("Parameter tableId is required."); 1650 throw new core.ArgumentError("Parameter tableId is required.");
1667 } 1651 }
1668 if (maxResults != null) { 1652 if (maxResults != null) {
1669 _queryParams["maxResults"] = ["${maxResults}"]; 1653 _queryParams["maxResults"] = ["${maxResults}"];
1670 } 1654 }
1671 if (pageToken != null) { 1655 if (pageToken != null) {
1672 _queryParams["pageToken"] = [pageToken]; 1656 _queryParams["pageToken"] = [pageToken];
1673 } 1657 }
1674 1658
1675 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates'; 1659 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates';
1676 1660
1677 var _response = _requester.request(_url, 1661 var _response = _requester.request(_url, "GET",
1678 "GET", 1662 body: _body,
1679 body: _body, 1663 queryParams: _queryParams,
1680 queryParams: _queryParams, 1664 uploadOptions: _uploadOptions,
1681 uploadOptions: _uploadOptions, 1665 uploadMedia: _uploadMedia,
1682 uploadMedia: _uploadMedia, 1666 downloadOptions: _downloadOptions);
1683 downloadOptions: _downloadOptions);
1684 return _response.then((data) => new TemplateList.fromJson(data)); 1667 return _response.then((data) => new TemplateList.fromJson(data));
1685 } 1668 }
1686 1669
1687 /** 1670 /// Updates an existing template. This method supports patch semantics.
1688 * Updates an existing template. This method supports patch semantics. 1671 ///
1689 * 1672 /// [request] - The metadata request object.
1690 * [request] - The metadata request object. 1673 ///
1691 * 1674 /// Request parameters:
1692 * Request parameters: 1675 ///
1693 * 1676 /// [tableId] - Table to which the updated template belongs
1694 * [tableId] - Table to which the updated template belongs 1677 ///
1695 * 1678 /// [templateId] - Identifier for the template that is being updated
1696 * [templateId] - Identifier for the template that is being updated 1679 ///
1697 * 1680 /// Completes with a [Template].
1698 * Completes with a [Template]. 1681 ///
1699 * 1682 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1700 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1683 /// an error.
1701 * error. 1684 ///
1702 * 1685 /// If the used [http.Client] completes with an error when making a REST
1703 * If the used [http.Client] completes with an error when making a REST call, 1686 /// call, this method will complete with the same error.
1704 * this method will complete with the same error. 1687 async.Future<Template> patch(
1705 */ 1688 Template request, core.String tableId, core.int templateId) {
1706 async.Future<Template> patch(Template request, core.String tableId, core.int t emplateId) {
1707 var _url = null; 1689 var _url = null;
1708 var _queryParams = new core.Map(); 1690 var _queryParams = new core.Map();
1709 var _uploadMedia = null; 1691 var _uploadMedia = null;
1710 var _uploadOptions = null; 1692 var _uploadOptions = null;
1711 var _downloadOptions = commons.DownloadOptions.Metadata; 1693 var _downloadOptions = commons.DownloadOptions.Metadata;
1712 var _body = null; 1694 var _body = null;
1713 1695
1714 if (request != null) { 1696 if (request != null) {
1715 _body = convert.JSON.encode((request).toJson()); 1697 _body = convert.JSON.encode((request).toJson());
1716 } 1698 }
1717 if (tableId == null) { 1699 if (tableId == null) {
1718 throw new core.ArgumentError("Parameter tableId is required."); 1700 throw new core.ArgumentError("Parameter tableId is required.");
1719 } 1701 }
1720 if (templateId == null) { 1702 if (templateId == null) {
1721 throw new core.ArgumentError("Parameter templateId is required."); 1703 throw new core.ArgumentError("Parameter templateId is required.");
1722 } 1704 }
1723 1705
1724 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates/' + commons.Escaper.ecapeVariable('$templateId'); 1706 _url = 'tables/' +
1707 commons.Escaper.ecapeVariable('$tableId') +
1708 '/templates/' +
1709 commons.Escaper.ecapeVariable('$templateId');
1725 1710
1726 var _response = _requester.request(_url, 1711 var _response = _requester.request(_url, "PATCH",
1727 "PATCH", 1712 body: _body,
1728 body: _body, 1713 queryParams: _queryParams,
1729 queryParams: _queryParams, 1714 uploadOptions: _uploadOptions,
1730 uploadOptions: _uploadOptions, 1715 uploadMedia: _uploadMedia,
1731 uploadMedia: _uploadMedia, 1716 downloadOptions: _downloadOptions);
1732 downloadOptions: _downloadOptions);
1733 return _response.then((data) => new Template.fromJson(data)); 1717 return _response.then((data) => new Template.fromJson(data));
1734 } 1718 }
1735 1719
1736 /** 1720 /// Updates an existing template
1737 * Updates an existing template 1721 ///
1738 * 1722 /// [request] - The metadata request object.
1739 * [request] - The metadata request object. 1723 ///
1740 * 1724 /// Request parameters:
1741 * Request parameters: 1725 ///
1742 * 1726 /// [tableId] - Table to which the updated template belongs
1743 * [tableId] - Table to which the updated template belongs 1727 ///
1744 * 1728 /// [templateId] - Identifier for the template that is being updated
1745 * [templateId] - Identifier for the template that is being updated 1729 ///
1746 * 1730 /// Completes with a [Template].
1747 * Completes with a [Template]. 1731 ///
1748 * 1732 /// Completes with a [commons.ApiRequestError] if the API endpoint returned
1749 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 1733 /// an error.
1750 * error. 1734 ///
1751 * 1735 /// If the used [http.Client] completes with an error when making a REST
1752 * If the used [http.Client] completes with an error when making a REST call, 1736 /// call, this method will complete with the same error.
1753 * this method will complete with the same error. 1737 async.Future<Template> update(
1754 */ 1738 Template request, core.String tableId, core.int templateId) {
1755 async.Future<Template> update(Template request, core.String tableId, core.int templateId) {
1756 var _url = null; 1739 var _url = null;
1757 var _queryParams = new core.Map(); 1740 var _queryParams = new core.Map();
1758 var _uploadMedia = null; 1741 var _uploadMedia = null;
1759 var _uploadOptions = null; 1742 var _uploadOptions = null;
1760 var _downloadOptions = commons.DownloadOptions.Metadata; 1743 var _downloadOptions = commons.DownloadOptions.Metadata;
1761 var _body = null; 1744 var _body = null;
1762 1745
1763 if (request != null) { 1746 if (request != null) {
1764 _body = convert.JSON.encode((request).toJson()); 1747 _body = convert.JSON.encode((request).toJson());
1765 } 1748 }
1766 if (tableId == null) { 1749 if (tableId == null) {
1767 throw new core.ArgumentError("Parameter tableId is required."); 1750 throw new core.ArgumentError("Parameter tableId is required.");
1768 } 1751 }
1769 if (templateId == null) { 1752 if (templateId == null) {
1770 throw new core.ArgumentError("Parameter templateId is required."); 1753 throw new core.ArgumentError("Parameter templateId is required.");
1771 } 1754 }
1772 1755
1773 _url = 'tables/' + commons.Escaper.ecapeVariable('$tableId') + '/templates/' + commons.Escaper.ecapeVariable('$templateId'); 1756 _url = 'tables/' +
1757 commons.Escaper.ecapeVariable('$tableId') +
1758 '/templates/' +
1759 commons.Escaper.ecapeVariable('$templateId');
1774 1760
1775 var _response = _requester.request(_url, 1761 var _response = _requester.request(_url, "PUT",
1776 "PUT", 1762 body: _body,
1777 body: _body, 1763 queryParams: _queryParams,
1778 queryParams: _queryParams, 1764 uploadOptions: _uploadOptions,
1779 uploadOptions: _uploadOptions, 1765 uploadMedia: _uploadMedia,
1780 uploadMedia: _uploadMedia, 1766 downloadOptions: _downloadOptions);
1781 downloadOptions: _downloadOptions);
1782 return _response.then((data) => new Template.fromJson(data)); 1767 return _response.then((data) => new Template.fromJson(data));
1783 } 1768 }
1784
1785 } 1769 }
1786 1770
1771 /// Specifies the minimum and maximum values, the color, opacity, icon and
1772 /// weight of a bucket within a StyleSetting.
1773 class Bucket {
1774 /// Color of line or the interior of a polygon in #RRGGBB format.
1775 core.String color;
1787 1776
1777 /// Icon name used for a point.
1778 core.String icon;
1788 1779
1789 /** 1780 /// Maximum value in the selected column for a row to be styled according to
1790 * Specifies the minimum and maximum values, the color, opacity, icon and weight 1781 /// the bucket color, opacity, icon, or weight.
1791 * of a bucket within a StyleSetting.
1792 */
1793 class Bucket {
1794 /** Color of line or the interior of a polygon in #RRGGBB format. */
1795 core.String color;
1796 /** Icon name used for a point. */
1797 core.String icon;
1798 /**
1799 * Maximum value in the selected column for a row to be styled according to
1800 * the bucket color, opacity, icon, or weight.
1801 */
1802 core.double max; 1782 core.double max;
1803 /** 1783
1804 * Minimum value in the selected column for a row to be styled according to 1784 /// Minimum value in the selected column for a row to be styled according to
1805 * the bucket color, opacity, icon, or weight. 1785 /// the bucket color, opacity, icon, or weight.
1806 */
1807 core.double min; 1786 core.double min;
1808 /** Opacity of the color: 0.0 (transparent) to 1.0 (opaque). */ 1787
1788 /// Opacity of the color: 0.0 (transparent) to 1.0 (opaque).
1809 core.double opacity; 1789 core.double opacity;
1810 /** Width of a line (in pixels). */ 1790
1791 /// Width of a line (in pixels).
1811 core.int weight; 1792 core.int weight;
1812 1793
1813 Bucket(); 1794 Bucket();
1814 1795
1815 Bucket.fromJson(core.Map _json) { 1796 Bucket.fromJson(core.Map _json) {
1816 if (_json.containsKey("color")) { 1797 if (_json.containsKey("color")) {
1817 color = _json["color"]; 1798 color = _json["color"];
1818 } 1799 }
1819 if (_json.containsKey("icon")) { 1800 if (_json.containsKey("icon")) {
1820 icon = _json["icon"]; 1801 icon = _json["icon"];
1821 } 1802 }
1822 if (_json.containsKey("max")) { 1803 if (_json.containsKey("max")) {
1823 max = _json["max"]; 1804 max = _json["max"];
1824 } 1805 }
1825 if (_json.containsKey("min")) { 1806 if (_json.containsKey("min")) {
1826 min = _json["min"]; 1807 min = _json["min"];
1827 } 1808 }
1828 if (_json.containsKey("opacity")) { 1809 if (_json.containsKey("opacity")) {
1829 opacity = _json["opacity"]; 1810 opacity = _json["opacity"];
1830 } 1811 }
1831 if (_json.containsKey("weight")) { 1812 if (_json.containsKey("weight")) {
1832 weight = _json["weight"]; 1813 weight = _json["weight"];
1833 } 1814 }
1834 } 1815 }
1835 1816
1836 core.Map<core.String, core.Object> toJson() { 1817 core.Map<core.String, core.Object> toJson() {
1837 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 1818 final core.Map<core.String, core.Object> _json =
1819 new core.Map<core.String, core.Object>();
1838 if (color != null) { 1820 if (color != null) {
1839 _json["color"] = color; 1821 _json["color"] = color;
1840 } 1822 }
1841 if (icon != null) { 1823 if (icon != null) {
1842 _json["icon"] = icon; 1824 _json["icon"] = icon;
1843 } 1825 }
1844 if (max != null) { 1826 if (max != null) {
1845 _json["max"] = max; 1827 _json["max"] = max;
1846 } 1828 }
1847 if (min != null) { 1829 if (min != null) {
1848 _json["min"] = min; 1830 _json["min"] = min;
1849 } 1831 }
1850 if (opacity != null) { 1832 if (opacity != null) {
1851 _json["opacity"] = opacity; 1833 _json["opacity"] = opacity;
1852 } 1834 }
1853 if (weight != null) { 1835 if (weight != null) {
1854 _json["weight"] = weight; 1836 _json["weight"] = weight;
1855 } 1837 }
1856 return _json; 1838 return _json;
1857 } 1839 }
1858 } 1840 }
1859 1841
1860 /** 1842 /// Identifier of the base column. If present, this column is derived from the
1861 * Identifier of the base column. If present, this column is derived from the 1843 /// specified base column.
1862 * specified base column.
1863 */
1864 class ColumnBaseColumn { 1844 class ColumnBaseColumn {
1865 /** 1845 /// The id of the column in the base table from which this column is derived.
1866 * The id of the column in the base table from which this column is derived.
1867 */
1868 core.int columnId; 1846 core.int columnId;
1869 /** 1847
1870 * Offset to the entry in the list of base tables in the table definition. 1848 /// Offset to the entry in the list of base tables in the table definition.
1871 */
1872 core.int tableIndex; 1849 core.int tableIndex;
1873 1850
1874 ColumnBaseColumn(); 1851 ColumnBaseColumn();
1875 1852
1876 ColumnBaseColumn.fromJson(core.Map _json) { 1853 ColumnBaseColumn.fromJson(core.Map _json) {
1877 if (_json.containsKey("columnId")) { 1854 if (_json.containsKey("columnId")) {
1878 columnId = _json["columnId"]; 1855 columnId = _json["columnId"];
1879 } 1856 }
1880 if (_json.containsKey("tableIndex")) { 1857 if (_json.containsKey("tableIndex")) {
1881 tableIndex = _json["tableIndex"]; 1858 tableIndex = _json["tableIndex"];
1882 } 1859 }
1883 } 1860 }
1884 1861
1885 core.Map<core.String, core.Object> toJson() { 1862 core.Map<core.String, core.Object> toJson() {
1886 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 1863 final core.Map<core.String, core.Object> _json =
1864 new core.Map<core.String, core.Object>();
1887 if (columnId != null) { 1865 if (columnId != null) {
1888 _json["columnId"] = columnId; 1866 _json["columnId"] = columnId;
1889 } 1867 }
1890 if (tableIndex != null) { 1868 if (tableIndex != null) {
1891 _json["tableIndex"] = tableIndex; 1869 _json["tableIndex"] = tableIndex;
1892 } 1870 }
1893 return _json; 1871 return _json;
1894 } 1872 }
1895 } 1873 }
1896 1874
1897 /** Specifies the details of a column in a table. */ 1875 /// Specifies the details of a column in a table.
1898 class Column { 1876 class Column {
1899 /** 1877 /// Identifier of the base column. If present, this column is derived from
1900 * Identifier of the base column. If present, this column is derived from the 1878 /// the specified base column.
1901 * specified base column.
1902 */
1903 ColumnBaseColumn baseColumn; 1879 ColumnBaseColumn baseColumn;
1904 /** Identifier for the column. */ 1880
1881 /// Identifier for the column.
1905 core.int columnId; 1882 core.int columnId;
1906 /** JSON schema for interpreting JSON in this column. */ 1883
1884 /// JSON schema for interpreting JSON in this column.
1907 core.String columnJsonSchema; 1885 core.String columnJsonSchema;
1908 /** JSON object containing custom column properties. */ 1886
1887 /// JSON object containing custom column properties.
1909 core.String columnPropertiesJson; 1888 core.String columnPropertiesJson;
1910 /** Column description. */ 1889
1890 /// Column description.
1911 core.String description; 1891 core.String description;
1912 /** 1892
1913 * Format pattern. 1893 /// Format pattern.
1914 * Acceptable values are DT_DATE_MEDIUMe.g Dec 24, 2008 DT_DATE_SHORTfor 1894 /// Acceptable values are DT_DATE_MEDIUMe.g Dec 24, 2008 DT_DATE_SHORTfor
1915 * example 12/24/08 DT_DATE_TIME_MEDIUMfor example Dec 24, 2008 8:30:45 PM 1895 /// example 12/24/08 DT_DATE_TIME_MEDIUMfor example Dec 24, 2008 8:30:45 PM
1916 * DT_DATE_TIME_SHORTfor example 12/24/08 8:30 PM DT_DAY_MONTH_2_DIGIT_YEARfor 1896 /// DT_DATE_TIME_SHORTfor example 12/24/08 8:30 PM
1917 * example 24/12/08 DT_DAY_MONTH_2_DIGIT_YEAR_TIMEfor example 24/12/08 20:30 1897 /// DT_DAY_MONTH_2_DIGIT_YEARfor example 24/12/08
1918 * DT_DAY_MONTH_2_DIGIT_YEAR_TIME_MERIDIANfor example 24/12/08 8:30 PM 1898 /// DT_DAY_MONTH_2_DIGIT_YEAR_TIMEfor example 24/12/08 20:30
1919 * DT_DAY_MONTH_4_DIGIT_YEARfor example 24/12/2008 1899 /// DT_DAY_MONTH_2_DIGIT_YEAR_TIME_MERIDIANfor example 24/12/08 8:30 PM
1920 * DT_DAY_MONTH_4_DIGIT_YEAR_TIMEfor example 24/12/2008 20:30 1900 /// DT_DAY_MONTH_4_DIGIT_YEARfor example 24/12/2008
1921 * DT_DAY_MONTH_4_DIGIT_YEAR_TIME_MERIDIANfor example 24/12/2008 8:30 PM 1901 /// DT_DAY_MONTH_4_DIGIT_YEAR_TIMEfor example 24/12/2008 20:30
1922 * DT_ISO_YEAR_MONTH_DAYfor example 2008-12-24 DT_ISO_YEAR_MONTH_DAY_TIMEfor 1902 /// DT_DAY_MONTH_4_DIGIT_YEAR_TIME_MERIDIANfor example 24/12/2008 8:30 PM
1923 * example 2008-12-24 20:30:45 DT_MONTH_DAY_4_DIGIT_YEARfor example 12/24/2008 1903 /// DT_ISO_YEAR_MONTH_DAYfor example 2008-12-24 DT_ISO_YEAR_MONTH_DAY_TIMEfor
1924 * DT_TIME_LONGfor example 8:30:45 PM UTC-6 DT_TIME_MEDIUMfor example 8:30:45 1904 /// example 2008-12-24 20:30:45 DT_MONTH_DAY_4_DIGIT_YEARfor example
1925 * PM DT_TIME_SHORTfor example 8:30 PM DT_YEAR_ONLYfor example 2008 1905 /// 12/24/2008 DT_TIME_LONGfor example 8:30:45 PM UTC-6 DT_TIME_MEDIUMfor
1926 * HIGHLIGHT_UNTYPED_CELLSHighlight cell data that does not match the data 1906 /// example 8:30:45 PM DT_TIME_SHORTfor example 8:30 PM DT_YEAR_ONLYfor
1927 * type NONENo formatting (default) NUMBER_CURRENCYfor example $1234.56 1907 /// example 2008 HIGHLIGHT_UNTYPED_CELLSHighlight cell data that does not
1928 * NUMBER_DEFAULTfor example 1,234.56 NUMBER_INTEGERfor example 1235 1908 /// match the data type NONENo formatting (default) NUMBER_CURRENCYfor
1929 * NUMBER_NO_SEPARATORfor example 1234.56 NUMBER_PERCENTfor example 123,456% 1909 /// example $1234.56 NUMBER_DEFAULTfor example 1,234.56 NUMBER_INTEGERfor
1930 * NUMBER_SCIENTIFICfor example 1E3 STRING_EIGHT_LINE_IMAGEDisplays thumbnail 1910 /// example 1235 NUMBER_NO_SEPARATORfor example 1234.56 NUMBER_PERCENTfor
1931 * images as tall as eight lines of text STRING_FOUR_LINE_IMAGEDisplays 1911 /// example 123,456% NUMBER_SCIENTIFICfor example 1E3
1932 * thumbnail images as tall as four lines of text STRING_JSON_TEXTAllows 1912 /// STRING_EIGHT_LINE_IMAGEDisplays thumbnail images as tall as eight lines
1933 * editing of text as JSON in UI STRING_JSON_LISTAllows editing of text as a 1913 /// of text STRING_FOUR_LINE_IMAGEDisplays thumbnail images as tall as four
1934 * JSON list in UI STRING_LINKTreats cell as a link (must start with http:// 1914 /// lines of text STRING_JSON_TEXTAllows editing of text as JSON in UI
1935 * or https://) STRING_ONE_LINE_IMAGEDisplays thumbnail images as tall as one 1915 /// STRING_JSON_LISTAllows editing of text as a JSON list in UI
1936 * line of text STRING_VIDEO_OR_MAPDisplay a video or map thumbnail 1916 /// STRING_LINKTreats cell as a link (must start with http:// or https://)
1937 */ 1917 /// STRING_ONE_LINE_IMAGEDisplays thumbnail images as tall as one line of
1918 /// text STRING_VIDEO_OR_MAPDisplay a video or map thumbnail
1938 core.String formatPattern; 1919 core.String formatPattern;
1939 /** 1920
1940 * Column graph predicate. 1921 /// Column graph predicate.
1941 * Used to map table to graph data model (subject,predicate,object) 1922 /// Used to map table to graph data model (subject,predicate,object)
1942 * See W3C Graph-based Data Model. 1923 /// See W3C Graph-based Data Model.
1943 */
1944 core.String graphPredicate; 1924 core.String graphPredicate;
1945 /** 1925
1946 * The kind of item this is. For a column, this is always fusiontables#column. 1926 /// The kind of item this is. For a column, this is always
1947 */ 1927 /// fusiontables#column.
1948 core.String kind; 1928 core.String kind;
1949 /** Name of the column. */ 1929
1930 /// Name of the column.
1950 core.String name; 1931 core.String name;
1951 /** Type of the column. */ 1932
1933 /// Type of the column.
1952 core.String type; 1934 core.String type;
1953 /** 1935
1954 * List of valid values used to validate data and supply a drop-down list of 1936 /// List of valid values used to validate data and supply a drop-down list of
1955 * values in the web application. 1937 /// values in the web application.
1956 */
1957 core.List<core.String> validValues; 1938 core.List<core.String> validValues;
1958 /** If true, data entered via the web application is validated. */ 1939
1940 /// If true, data entered via the web application is validated.
1959 core.bool validateData; 1941 core.bool validateData;
1960 1942
1961 Column(); 1943 Column();
1962 1944
1963 Column.fromJson(core.Map _json) { 1945 Column.fromJson(core.Map _json) {
1964 if (_json.containsKey("baseColumn")) { 1946 if (_json.containsKey("baseColumn")) {
1965 baseColumn = new ColumnBaseColumn.fromJson(_json["baseColumn"]); 1947 baseColumn = new ColumnBaseColumn.fromJson(_json["baseColumn"]);
1966 } 1948 }
1967 if (_json.containsKey("columnId")) { 1949 if (_json.containsKey("columnId")) {
1968 columnId = _json["columnId"]; 1950 columnId = _json["columnId"];
(...skipping 24 matching lines...) Expand all
1993 } 1975 }
1994 if (_json.containsKey("validValues")) { 1976 if (_json.containsKey("validValues")) {
1995 validValues = _json["validValues"]; 1977 validValues = _json["validValues"];
1996 } 1978 }
1997 if (_json.containsKey("validateData")) { 1979 if (_json.containsKey("validateData")) {
1998 validateData = _json["validateData"]; 1980 validateData = _json["validateData"];
1999 } 1981 }
2000 } 1982 }
2001 1983
2002 core.Map<core.String, core.Object> toJson() { 1984 core.Map<core.String, core.Object> toJson() {
2003 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 1985 final core.Map<core.String, core.Object> _json =
1986 new core.Map<core.String, core.Object>();
2004 if (baseColumn != null) { 1987 if (baseColumn != null) {
2005 _json["baseColumn"] = (baseColumn).toJson(); 1988 _json["baseColumn"] = (baseColumn).toJson();
2006 } 1989 }
2007 if (columnId != null) { 1990 if (columnId != null) {
2008 _json["columnId"] = columnId; 1991 _json["columnId"] = columnId;
2009 } 1992 }
2010 if (columnJsonSchema != null) { 1993 if (columnJsonSchema != null) {
2011 _json["columnJsonSchema"] = columnJsonSchema; 1994 _json["columnJsonSchema"] = columnJsonSchema;
2012 } 1995 }
2013 if (columnPropertiesJson != null) { 1996 if (columnPropertiesJson != null) {
(...skipping 20 matching lines...) Expand all
2034 if (validValues != null) { 2017 if (validValues != null) {
2035 _json["validValues"] = validValues; 2018 _json["validValues"] = validValues;
2036 } 2019 }
2037 if (validateData != null) { 2020 if (validateData != null) {
2038 _json["validateData"] = validateData; 2021 _json["validateData"] = validateData;
2039 } 2022 }
2040 return _json; 2023 return _json;
2041 } 2024 }
2042 } 2025 }
2043 2026
2044 /** Represents a list of columns in a table. */ 2027 /// Represents a list of columns in a table.
2045 class ColumnList { 2028 class ColumnList {
2046 /** List of all requested columns. */ 2029 /// List of all requested columns.
2047 core.List<Column> items; 2030 core.List<Column> items;
2048 /** 2031
2049 * The kind of item this is. For a column list, this is always 2032 /// The kind of item this is. For a column list, this is always
2050 * fusiontables#columnList. 2033 /// fusiontables#columnList.
2051 */
2052 core.String kind; 2034 core.String kind;
2053 /** 2035
2054 * Token used to access the next page of this result. No token is displayed if 2036 /// Token used to access the next page of this result. No token is displayed
2055 * there are no more pages left. 2037 /// if there are no more pages left.
2056 */
2057 core.String nextPageToken; 2038 core.String nextPageToken;
2058 /** Total number of columns for the table. */ 2039
2040 /// Total number of columns for the table.
2059 core.int totalItems; 2041 core.int totalItems;
2060 2042
2061 ColumnList(); 2043 ColumnList();
2062 2044
2063 ColumnList.fromJson(core.Map _json) { 2045 ColumnList.fromJson(core.Map _json) {
2064 if (_json.containsKey("items")) { 2046 if (_json.containsKey("items")) {
2065 items = _json["items"].map((value) => new Column.fromJson(value)).toList() ; 2047 items =
2048 _json["items"].map((value) => new Column.fromJson(value)).toList();
2066 } 2049 }
2067 if (_json.containsKey("kind")) { 2050 if (_json.containsKey("kind")) {
2068 kind = _json["kind"]; 2051 kind = _json["kind"];
2069 } 2052 }
2070 if (_json.containsKey("nextPageToken")) { 2053 if (_json.containsKey("nextPageToken")) {
2071 nextPageToken = _json["nextPageToken"]; 2054 nextPageToken = _json["nextPageToken"];
2072 } 2055 }
2073 if (_json.containsKey("totalItems")) { 2056 if (_json.containsKey("totalItems")) {
2074 totalItems = _json["totalItems"]; 2057 totalItems = _json["totalItems"];
2075 } 2058 }
2076 } 2059 }
2077 2060
2078 core.Map<core.String, core.Object> toJson() { 2061 core.Map<core.String, core.Object> toJson() {
2079 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2062 final core.Map<core.String, core.Object> _json =
2063 new core.Map<core.String, core.Object>();
2080 if (items != null) { 2064 if (items != null) {
2081 _json["items"] = items.map((value) => (value).toJson()).toList(); 2065 _json["items"] = items.map((value) => (value).toJson()).toList();
2082 } 2066 }
2083 if (kind != null) { 2067 if (kind != null) {
2084 _json["kind"] = kind; 2068 _json["kind"] = kind;
2085 } 2069 }
2086 if (nextPageToken != null) { 2070 if (nextPageToken != null) {
2087 _json["nextPageToken"] = nextPageToken; 2071 _json["nextPageToken"] = nextPageToken;
2088 } 2072 }
2089 if (totalItems != null) { 2073 if (totalItems != null) {
2090 _json["totalItems"] = totalItems; 2074 _json["totalItems"] = totalItems;
2091 } 2075 }
2092 return _json; 2076 return _json;
2093 } 2077 }
2094 } 2078 }
2095 2079
2096 /** Represents a Geometry object. */ 2080 /// Represents a Geometry object.
2097 class Geometry { 2081 class Geometry {
2098 /** 2082 /// The list of geometries in this geometry collection.
2099 * The list of geometries in this geometry collection. 2083 ///
2100 * 2084 /// The values for Object must be JSON objects. It can consist of `num`,
2101 * The values for Object must be JSON objects. It can consist of `num`, 2085 /// `String`, `bool` and `null` as well as `Map` and `List` values.
2102 * `String`, `bool` and `null` as well as `Map` and `List` values.
2103 */
2104 core.List<core.Object> geometries; 2086 core.List<core.Object> geometries;
2105 /** 2087
2106 * 2088 ///
2107 * 2089 ///
2108 * The values for Object must be JSON objects. It can consist of `num`, 2090 /// The values for Object must be JSON objects. It can consist of `num`,
2109 * `String`, `bool` and `null` as well as `Map` and `List` values. 2091 /// `String`, `bool` and `null` as well as `Map` and `List` values.
2110 */
2111 core.Object geometry; 2092 core.Object geometry;
2112 /** Type: A collection of geometries. */ 2093
2094 /// Type: A collection of geometries.
2113 core.String type; 2095 core.String type;
2114 2096
2115 Geometry(); 2097 Geometry();
2116 2098
2117 Geometry.fromJson(core.Map _json) { 2099 Geometry.fromJson(core.Map _json) {
2118 if (_json.containsKey("geometries")) { 2100 if (_json.containsKey("geometries")) {
2119 geometries = _json["geometries"]; 2101 geometries = _json["geometries"];
2120 } 2102 }
2121 if (_json.containsKey("geometry")) { 2103 if (_json.containsKey("geometry")) {
2122 geometry = _json["geometry"]; 2104 geometry = _json["geometry"];
2123 } 2105 }
2124 if (_json.containsKey("type")) { 2106 if (_json.containsKey("type")) {
2125 type = _json["type"]; 2107 type = _json["type"];
2126 } 2108 }
2127 } 2109 }
2128 2110
2129 core.Map<core.String, core.Object> toJson() { 2111 core.Map<core.String, core.Object> toJson() {
2130 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2112 final core.Map<core.String, core.Object> _json =
2113 new core.Map<core.String, core.Object>();
2131 if (geometries != null) { 2114 if (geometries != null) {
2132 _json["geometries"] = geometries; 2115 _json["geometries"] = geometries;
2133 } 2116 }
2134 if (geometry != null) { 2117 if (geometry != null) {
2135 _json["geometry"] = geometry; 2118 _json["geometry"] = geometry;
2136 } 2119 }
2137 if (type != null) { 2120 if (type != null) {
2138 _json["type"] = type; 2121 _json["type"] = type;
2139 } 2122 }
2140 return _json; 2123 return _json;
2141 } 2124 }
2142 } 2125 }
2143 2126
2144 /** Represents an import request. */ 2127 /// Represents an import request.
2145 class Import { 2128 class Import {
2146 /** 2129 /// The kind of item this is. For an import, this is always
2147 * The kind of item this is. For an import, this is always 2130 /// fusiontables#import.
2148 * fusiontables#import.
2149 */
2150 core.String kind; 2131 core.String kind;
2151 /** The number of rows received from the import request. */ 2132
2133 /// The number of rows received from the import request.
2152 core.String numRowsReceived; 2134 core.String numRowsReceived;
2153 2135
2154 Import(); 2136 Import();
2155 2137
2156 Import.fromJson(core.Map _json) { 2138 Import.fromJson(core.Map _json) {
2157 if (_json.containsKey("kind")) { 2139 if (_json.containsKey("kind")) {
2158 kind = _json["kind"]; 2140 kind = _json["kind"];
2159 } 2141 }
2160 if (_json.containsKey("numRowsReceived")) { 2142 if (_json.containsKey("numRowsReceived")) {
2161 numRowsReceived = _json["numRowsReceived"]; 2143 numRowsReceived = _json["numRowsReceived"];
2162 } 2144 }
2163 } 2145 }
2164 2146
2165 core.Map<core.String, core.Object> toJson() { 2147 core.Map<core.String, core.Object> toJson() {
2166 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2148 final core.Map<core.String, core.Object> _json =
2149 new core.Map<core.String, core.Object>();
2167 if (kind != null) { 2150 if (kind != null) {
2168 _json["kind"] = kind; 2151 _json["kind"] = kind;
2169 } 2152 }
2170 if (numRowsReceived != null) { 2153 if (numRowsReceived != null) {
2171 _json["numRowsReceived"] = numRowsReceived; 2154 _json["numRowsReceived"] = numRowsReceived;
2172 } 2155 }
2173 return _json; 2156 return _json;
2174 } 2157 }
2175 } 2158 }
2176 2159
2177 /** Represents a line geometry. */ 2160 /// Represents a line geometry.
2178 class Line { 2161 class Line {
2179 /** The coordinates that define the line. */ 2162 /// The coordinates that define the line.
2180 core.List<core.List<core.double>> coordinates; 2163 core.List<core.List<core.double>> coordinates;
2181 /** Type: A line geometry. */ 2164
2165 /// Type: A line geometry.
2182 core.String type; 2166 core.String type;
2183 2167
2184 Line(); 2168 Line();
2185 2169
2186 Line.fromJson(core.Map _json) { 2170 Line.fromJson(core.Map _json) {
2187 if (_json.containsKey("coordinates")) { 2171 if (_json.containsKey("coordinates")) {
2188 coordinates = _json["coordinates"]; 2172 coordinates = _json["coordinates"];
2189 } 2173 }
2190 if (_json.containsKey("type")) { 2174 if (_json.containsKey("type")) {
2191 type = _json["type"]; 2175 type = _json["type"];
2192 } 2176 }
2193 } 2177 }
2194 2178
2195 core.Map<core.String, core.Object> toJson() { 2179 core.Map<core.String, core.Object> toJson() {
2196 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2180 final core.Map<core.String, core.Object> _json =
2181 new core.Map<core.String, core.Object>();
2197 if (coordinates != null) { 2182 if (coordinates != null) {
2198 _json["coordinates"] = coordinates; 2183 _json["coordinates"] = coordinates;
2199 } 2184 }
2200 if (type != null) { 2185 if (type != null) {
2201 _json["type"] = type; 2186 _json["type"] = type;
2202 } 2187 }
2203 return _json; 2188 return _json;
2204 } 2189 }
2205 } 2190 }
2206 2191
2207 /** Represents a LineStyle within a StyleSetting */ 2192 /// Represents a LineStyle within a StyleSetting
2208 class LineStyle { 2193 class LineStyle {
2209 /** Color of the line in #RRGGBB format. */ 2194 /// Color of the line in #RRGGBB format.
2210 core.String strokeColor; 2195 core.String strokeColor;
2211 /** 2196
2212 * Column-value, gradient or buckets styler that is used to determine the line 2197 /// Column-value, gradient or buckets styler that is used to determine the
2213 * color and opacity. 2198 /// line color and opacity.
2214 */
2215 StyleFunction strokeColorStyler; 2199 StyleFunction strokeColorStyler;
2216 /** Opacity of the line : 0.0 (transparent) to 1.0 (opaque). */ 2200
2201 /// Opacity of the line : 0.0 (transparent) to 1.0 (opaque).
2217 core.double strokeOpacity; 2202 core.double strokeOpacity;
2218 /** Width of the line in pixels. */ 2203
2204 /// Width of the line in pixels.
2219 core.int strokeWeight; 2205 core.int strokeWeight;
2220 /** 2206
2221 * Column-value or bucket styler that is used to determine the width of the 2207 /// Column-value or bucket styler that is used to determine the width of the
2222 * line. 2208 /// line.
2223 */
2224 StyleFunction strokeWeightStyler; 2209 StyleFunction strokeWeightStyler;
2225 2210
2226 LineStyle(); 2211 LineStyle();
2227 2212
2228 LineStyle.fromJson(core.Map _json) { 2213 LineStyle.fromJson(core.Map _json) {
2229 if (_json.containsKey("strokeColor")) { 2214 if (_json.containsKey("strokeColor")) {
2230 strokeColor = _json["strokeColor"]; 2215 strokeColor = _json["strokeColor"];
2231 } 2216 }
2232 if (_json.containsKey("strokeColorStyler")) { 2217 if (_json.containsKey("strokeColorStyler")) {
2233 strokeColorStyler = new StyleFunction.fromJson(_json["strokeColorStyler"]) ; 2218 strokeColorStyler =
2219 new StyleFunction.fromJson(_json["strokeColorStyler"]);
2234 } 2220 }
2235 if (_json.containsKey("strokeOpacity")) { 2221 if (_json.containsKey("strokeOpacity")) {
2236 strokeOpacity = _json["strokeOpacity"]; 2222 strokeOpacity = _json["strokeOpacity"];
2237 } 2223 }
2238 if (_json.containsKey("strokeWeight")) { 2224 if (_json.containsKey("strokeWeight")) {
2239 strokeWeight = _json["strokeWeight"]; 2225 strokeWeight = _json["strokeWeight"];
2240 } 2226 }
2241 if (_json.containsKey("strokeWeightStyler")) { 2227 if (_json.containsKey("strokeWeightStyler")) {
2242 strokeWeightStyler = new StyleFunction.fromJson(_json["strokeWeightStyler" ]); 2228 strokeWeightStyler =
2229 new StyleFunction.fromJson(_json["strokeWeightStyler"]);
2243 } 2230 }
2244 } 2231 }
2245 2232
2246 core.Map<core.String, core.Object> toJson() { 2233 core.Map<core.String, core.Object> toJson() {
2247 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2234 final core.Map<core.String, core.Object> _json =
2235 new core.Map<core.String, core.Object>();
2248 if (strokeColor != null) { 2236 if (strokeColor != null) {
2249 _json["strokeColor"] = strokeColor; 2237 _json["strokeColor"] = strokeColor;
2250 } 2238 }
2251 if (strokeColorStyler != null) { 2239 if (strokeColorStyler != null) {
2252 _json["strokeColorStyler"] = (strokeColorStyler).toJson(); 2240 _json["strokeColorStyler"] = (strokeColorStyler).toJson();
2253 } 2241 }
2254 if (strokeOpacity != null) { 2242 if (strokeOpacity != null) {
2255 _json["strokeOpacity"] = strokeOpacity; 2243 _json["strokeOpacity"] = strokeOpacity;
2256 } 2244 }
2257 if (strokeWeight != null) { 2245 if (strokeWeight != null) {
2258 _json["strokeWeight"] = strokeWeight; 2246 _json["strokeWeight"] = strokeWeight;
2259 } 2247 }
2260 if (strokeWeightStyler != null) { 2248 if (strokeWeightStyler != null) {
2261 _json["strokeWeightStyler"] = (strokeWeightStyler).toJson(); 2249 _json["strokeWeightStyler"] = (strokeWeightStyler).toJson();
2262 } 2250 }
2263 return _json; 2251 return _json;
2264 } 2252 }
2265 } 2253 }
2266 2254
2267 /** Represents a point object. */ 2255 /// Represents a point object.
2268 class Point { 2256 class Point {
2269 /** The coordinates that define the point. */ 2257 /// The coordinates that define the point.
2270 core.List<core.double> coordinates; 2258 core.List<core.double> coordinates;
2271 /** Point: A point geometry. */ 2259
2260 /// Point: A point geometry.
2272 core.String type; 2261 core.String type;
2273 2262
2274 Point(); 2263 Point();
2275 2264
2276 Point.fromJson(core.Map _json) { 2265 Point.fromJson(core.Map _json) {
2277 if (_json.containsKey("coordinates")) { 2266 if (_json.containsKey("coordinates")) {
2278 coordinates = _json["coordinates"]; 2267 coordinates = _json["coordinates"];
2279 } 2268 }
2280 if (_json.containsKey("type")) { 2269 if (_json.containsKey("type")) {
2281 type = _json["type"]; 2270 type = _json["type"];
2282 } 2271 }
2283 } 2272 }
2284 2273
2285 core.Map<core.String, core.Object> toJson() { 2274 core.Map<core.String, core.Object> toJson() {
2286 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2275 final core.Map<core.String, core.Object> _json =
2276 new core.Map<core.String, core.Object>();
2287 if (coordinates != null) { 2277 if (coordinates != null) {
2288 _json["coordinates"] = coordinates; 2278 _json["coordinates"] = coordinates;
2289 } 2279 }
2290 if (type != null) { 2280 if (type != null) {
2291 _json["type"] = type; 2281 _json["type"] = type;
2292 } 2282 }
2293 return _json; 2283 return _json;
2294 } 2284 }
2295 } 2285 }
2296 2286
2297 /** Represents a PointStyle within a StyleSetting */ 2287 /// Represents a PointStyle within a StyleSetting
2298 class PointStyle { 2288 class PointStyle {
2299 /** 2289 /// Name of the icon. Use values defined in
2300 * Name of the icon. Use values defined in 2290 /// http://www.google.com/fusiontables/DataSource?dsrcid=308519
2301 * http://www.google.com/fusiontables/DataSource?dsrcid=308519
2302 */
2303 core.String iconName; 2291 core.String iconName;
2304 /** Column or a bucket value from which the icon name is to be determined. */ 2292
2293 /// Column or a bucket value from which the icon name is to be determined.
2305 StyleFunction iconStyler; 2294 StyleFunction iconStyler;
2306 2295
2307 PointStyle(); 2296 PointStyle();
2308 2297
2309 PointStyle.fromJson(core.Map _json) { 2298 PointStyle.fromJson(core.Map _json) {
2310 if (_json.containsKey("iconName")) { 2299 if (_json.containsKey("iconName")) {
2311 iconName = _json["iconName"]; 2300 iconName = _json["iconName"];
2312 } 2301 }
2313 if (_json.containsKey("iconStyler")) { 2302 if (_json.containsKey("iconStyler")) {
2314 iconStyler = new StyleFunction.fromJson(_json["iconStyler"]); 2303 iconStyler = new StyleFunction.fromJson(_json["iconStyler"]);
2315 } 2304 }
2316 } 2305 }
2317 2306
2318 core.Map<core.String, core.Object> toJson() { 2307 core.Map<core.String, core.Object> toJson() {
2319 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2308 final core.Map<core.String, core.Object> _json =
2309 new core.Map<core.String, core.Object>();
2320 if (iconName != null) { 2310 if (iconName != null) {
2321 _json["iconName"] = iconName; 2311 _json["iconName"] = iconName;
2322 } 2312 }
2323 if (iconStyler != null) { 2313 if (iconStyler != null) {
2324 _json["iconStyler"] = (iconStyler).toJson(); 2314 _json["iconStyler"] = (iconStyler).toJson();
2325 } 2315 }
2326 return _json; 2316 return _json;
2327 } 2317 }
2328 } 2318 }
2329 2319
2330 /** Represents a polygon object. */ 2320 /// Represents a polygon object.
2331 class Polygon { 2321 class Polygon {
2332 /** The coordinates that define the polygon. */ 2322 /// The coordinates that define the polygon.
2333 core.List<core.List<core.List<core.double>>> coordinates; 2323 core.List<core.List<core.List<core.double>>> coordinates;
2334 /** Type: A polygon geometry. */ 2324
2325 /// Type: A polygon geometry.
2335 core.String type; 2326 core.String type;
2336 2327
2337 Polygon(); 2328 Polygon();
2338 2329
2339 Polygon.fromJson(core.Map _json) { 2330 Polygon.fromJson(core.Map _json) {
2340 if (_json.containsKey("coordinates")) { 2331 if (_json.containsKey("coordinates")) {
2341 coordinates = _json["coordinates"]; 2332 coordinates = _json["coordinates"];
2342 } 2333 }
2343 if (_json.containsKey("type")) { 2334 if (_json.containsKey("type")) {
2344 type = _json["type"]; 2335 type = _json["type"];
2345 } 2336 }
2346 } 2337 }
2347 2338
2348 core.Map<core.String, core.Object> toJson() { 2339 core.Map<core.String, core.Object> toJson() {
2349 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2340 final core.Map<core.String, core.Object> _json =
2341 new core.Map<core.String, core.Object>();
2350 if (coordinates != null) { 2342 if (coordinates != null) {
2351 _json["coordinates"] = coordinates; 2343 _json["coordinates"] = coordinates;
2352 } 2344 }
2353 if (type != null) { 2345 if (type != null) {
2354 _json["type"] = type; 2346 _json["type"] = type;
2355 } 2347 }
2356 return _json; 2348 return _json;
2357 } 2349 }
2358 } 2350 }
2359 2351
2360 /** Represents a PolygonStyle within a StyleSetting */ 2352 /// Represents a PolygonStyle within a StyleSetting
2361 class PolygonStyle { 2353 class PolygonStyle {
2362 /** Color of the interior of the polygon in #RRGGBB format. */ 2354 /// Color of the interior of the polygon in #RRGGBB format.
2363 core.String fillColor; 2355 core.String fillColor;
2364 /** 2356
2365 * Column-value, gradient, or bucket styler that is used to determine the 2357 /// Column-value, gradient, or bucket styler that is used to determine the
2366 * interior color and opacity of the polygon. 2358 /// interior color and opacity of the polygon.
2367 */
2368 StyleFunction fillColorStyler; 2359 StyleFunction fillColorStyler;
2369 /** 2360
2370 * Opacity of the interior of the polygon: 0.0 (transparent) to 1.0 (opaque). 2361 /// Opacity of the interior of the polygon: 0.0 (transparent) to 1.0
2371 */ 2362 /// (opaque).
2372 core.double fillOpacity; 2363 core.double fillOpacity;
2373 /** Color of the polygon border in #RRGGBB format. */ 2364
2365 /// Color of the polygon border in #RRGGBB format.
2374 core.String strokeColor; 2366 core.String strokeColor;
2375 /** 2367
2376 * Column-value, gradient or buckets styler that is used to determine the 2368 /// Column-value, gradient or buckets styler that is used to determine the
2377 * border color and opacity. 2369 /// border color and opacity.
2378 */
2379 StyleFunction strokeColorStyler; 2370 StyleFunction strokeColorStyler;
2380 /** Opacity of the polygon border: 0.0 (transparent) to 1.0 (opaque). */ 2371
2372 /// Opacity of the polygon border: 0.0 (transparent) to 1.0 (opaque).
2381 core.double strokeOpacity; 2373 core.double strokeOpacity;
2382 /** Width of the polyon border in pixels. */ 2374
2375 /// Width of the polyon border in pixels.
2383 core.int strokeWeight; 2376 core.int strokeWeight;
2384 /** 2377
2385 * Column-value or bucket styler that is used to determine the width of the 2378 /// Column-value or bucket styler that is used to determine the width of the
2386 * polygon border. 2379 /// polygon border.
2387 */
2388 StyleFunction strokeWeightStyler; 2380 StyleFunction strokeWeightStyler;
2389 2381
2390 PolygonStyle(); 2382 PolygonStyle();
2391 2383
2392 PolygonStyle.fromJson(core.Map _json) { 2384 PolygonStyle.fromJson(core.Map _json) {
2393 if (_json.containsKey("fillColor")) { 2385 if (_json.containsKey("fillColor")) {
2394 fillColor = _json["fillColor"]; 2386 fillColor = _json["fillColor"];
2395 } 2387 }
2396 if (_json.containsKey("fillColorStyler")) { 2388 if (_json.containsKey("fillColorStyler")) {
2397 fillColorStyler = new StyleFunction.fromJson(_json["fillColorStyler"]); 2389 fillColorStyler = new StyleFunction.fromJson(_json["fillColorStyler"]);
2398 } 2390 }
2399 if (_json.containsKey("fillOpacity")) { 2391 if (_json.containsKey("fillOpacity")) {
2400 fillOpacity = _json["fillOpacity"]; 2392 fillOpacity = _json["fillOpacity"];
2401 } 2393 }
2402 if (_json.containsKey("strokeColor")) { 2394 if (_json.containsKey("strokeColor")) {
2403 strokeColor = _json["strokeColor"]; 2395 strokeColor = _json["strokeColor"];
2404 } 2396 }
2405 if (_json.containsKey("strokeColorStyler")) { 2397 if (_json.containsKey("strokeColorStyler")) {
2406 strokeColorStyler = new StyleFunction.fromJson(_json["strokeColorStyler"]) ; 2398 strokeColorStyler =
2399 new StyleFunction.fromJson(_json["strokeColorStyler"]);
2407 } 2400 }
2408 if (_json.containsKey("strokeOpacity")) { 2401 if (_json.containsKey("strokeOpacity")) {
2409 strokeOpacity = _json["strokeOpacity"]; 2402 strokeOpacity = _json["strokeOpacity"];
2410 } 2403 }
2411 if (_json.containsKey("strokeWeight")) { 2404 if (_json.containsKey("strokeWeight")) {
2412 strokeWeight = _json["strokeWeight"]; 2405 strokeWeight = _json["strokeWeight"];
2413 } 2406 }
2414 if (_json.containsKey("strokeWeightStyler")) { 2407 if (_json.containsKey("strokeWeightStyler")) {
2415 strokeWeightStyler = new StyleFunction.fromJson(_json["strokeWeightStyler" ]); 2408 strokeWeightStyler =
2409 new StyleFunction.fromJson(_json["strokeWeightStyler"]);
2416 } 2410 }
2417 } 2411 }
2418 2412
2419 core.Map<core.String, core.Object> toJson() { 2413 core.Map<core.String, core.Object> toJson() {
2420 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2414 final core.Map<core.String, core.Object> _json =
2415 new core.Map<core.String, core.Object>();
2421 if (fillColor != null) { 2416 if (fillColor != null) {
2422 _json["fillColor"] = fillColor; 2417 _json["fillColor"] = fillColor;
2423 } 2418 }
2424 if (fillColorStyler != null) { 2419 if (fillColorStyler != null) {
2425 _json["fillColorStyler"] = (fillColorStyler).toJson(); 2420 _json["fillColorStyler"] = (fillColorStyler).toJson();
2426 } 2421 }
2427 if (fillOpacity != null) { 2422 if (fillOpacity != null) {
2428 _json["fillOpacity"] = fillOpacity; 2423 _json["fillOpacity"] = fillOpacity;
2429 } 2424 }
2430 if (strokeColor != null) { 2425 if (strokeColor != null) {
2431 _json["strokeColor"] = strokeColor; 2426 _json["strokeColor"] = strokeColor;
2432 } 2427 }
2433 if (strokeColorStyler != null) { 2428 if (strokeColorStyler != null) {
2434 _json["strokeColorStyler"] = (strokeColorStyler).toJson(); 2429 _json["strokeColorStyler"] = (strokeColorStyler).toJson();
2435 } 2430 }
2436 if (strokeOpacity != null) { 2431 if (strokeOpacity != null) {
2437 _json["strokeOpacity"] = strokeOpacity; 2432 _json["strokeOpacity"] = strokeOpacity;
2438 } 2433 }
2439 if (strokeWeight != null) { 2434 if (strokeWeight != null) {
2440 _json["strokeWeight"] = strokeWeight; 2435 _json["strokeWeight"] = strokeWeight;
2441 } 2436 }
2442 if (strokeWeightStyler != null) { 2437 if (strokeWeightStyler != null) {
2443 _json["strokeWeightStyler"] = (strokeWeightStyler).toJson(); 2438 _json["strokeWeightStyler"] = (strokeWeightStyler).toJson();
2444 } 2439 }
2445 return _json; 2440 return _json;
2446 } 2441 }
2447 } 2442 }
2448 2443
2449 /** Represents a response to a SQL statement. */ 2444 /// Represents a response to a SQL statement.
2450 class Sqlresponse { 2445 class Sqlresponse {
2451 /** Columns in the table. */ 2446 /// Columns in the table.
2452 core.List<core.String> columns; 2447 core.List<core.String> columns;
2453 /** 2448
2454 * The kind of item this is. For responses to SQL queries, this is always 2449 /// The kind of item this is. For responses to SQL queries, this is always
2455 * fusiontables#sqlresponse. 2450 /// fusiontables#sqlresponse.
2456 */
2457 core.String kind; 2451 core.String kind;
2458 /** 2452
2459 * The rows in the table. For each cell we print out whatever cell value 2453 /// The rows in the table. For each cell we print out whatever cell value
2460 * (e.g., numeric, string) exists. Thus it is important that each cell 2454 /// (e.g., numeric, string) exists. Thus it is important that each cell
2461 * contains only one value. 2455 /// contains only one value.
2462 * 2456 ///
2463 * The values for Object must be JSON objects. It can consist of `num`, 2457 /// The values for Object must be JSON objects. It can consist of `num`,
2464 * `String`, `bool` and `null` as well as `Map` and `List` values. 2458 /// `String`, `bool` and `null` as well as `Map` and `List` values.
2465 */
2466 core.List<core.List<core.Object>> rows; 2459 core.List<core.List<core.Object>> rows;
2467 2460
2468 Sqlresponse(); 2461 Sqlresponse();
2469 2462
2470 Sqlresponse.fromJson(core.Map _json) { 2463 Sqlresponse.fromJson(core.Map _json) {
2471 if (_json.containsKey("columns")) { 2464 if (_json.containsKey("columns")) {
2472 columns = _json["columns"]; 2465 columns = _json["columns"];
2473 } 2466 }
2474 if (_json.containsKey("kind")) { 2467 if (_json.containsKey("kind")) {
2475 kind = _json["kind"]; 2468 kind = _json["kind"];
2476 } 2469 }
2477 if (_json.containsKey("rows")) { 2470 if (_json.containsKey("rows")) {
2478 rows = _json["rows"]; 2471 rows = _json["rows"];
2479 } 2472 }
2480 } 2473 }
2481 2474
2482 core.Map<core.String, core.Object> toJson() { 2475 core.Map<core.String, core.Object> toJson() {
2483 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2476 final core.Map<core.String, core.Object> _json =
2477 new core.Map<core.String, core.Object>();
2484 if (columns != null) { 2478 if (columns != null) {
2485 _json["columns"] = columns; 2479 _json["columns"] = columns;
2486 } 2480 }
2487 if (kind != null) { 2481 if (kind != null) {
2488 _json["kind"] = kind; 2482 _json["kind"] = kind;
2489 } 2483 }
2490 if (rows != null) { 2484 if (rows != null) {
2491 _json["rows"] = rows; 2485 _json["rows"] = rows;
2492 } 2486 }
2493 return _json; 2487 return _json;
2494 } 2488 }
2495 } 2489 }
2496 2490
2497 class StyleFunctionGradientColors { 2491 class StyleFunctionGradientColors {
2498 /** Color in #RRGGBB format. */ 2492 /// Color in #RRGGBB format.
2499 core.String color; 2493 core.String color;
2500 /** Opacity of the color: 0.0 (transparent) to 1.0 (opaque). */ 2494
2495 /// Opacity of the color: 0.0 (transparent) to 1.0 (opaque).
2501 core.double opacity; 2496 core.double opacity;
2502 2497
2503 StyleFunctionGradientColors(); 2498 StyleFunctionGradientColors();
2504 2499
2505 StyleFunctionGradientColors.fromJson(core.Map _json) { 2500 StyleFunctionGradientColors.fromJson(core.Map _json) {
2506 if (_json.containsKey("color")) { 2501 if (_json.containsKey("color")) {
2507 color = _json["color"]; 2502 color = _json["color"];
2508 } 2503 }
2509 if (_json.containsKey("opacity")) { 2504 if (_json.containsKey("opacity")) {
2510 opacity = _json["opacity"]; 2505 opacity = _json["opacity"];
2511 } 2506 }
2512 } 2507 }
2513 2508
2514 core.Map<core.String, core.Object> toJson() { 2509 core.Map<core.String, core.Object> toJson() {
2515 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2510 final core.Map<core.String, core.Object> _json =
2511 new core.Map<core.String, core.Object>();
2516 if (color != null) { 2512 if (color != null) {
2517 _json["color"] = color; 2513 _json["color"] = color;
2518 } 2514 }
2519 if (opacity != null) { 2515 if (opacity != null) {
2520 _json["opacity"] = opacity; 2516 _json["opacity"] = opacity;
2521 } 2517 }
2522 return _json; 2518 return _json;
2523 } 2519 }
2524 } 2520 }
2525 2521
2526 /** 2522 /// Gradient function that interpolates a range of colors based on column
2527 * Gradient function that interpolates a range of colors based on column value. 2523 /// value.
2528 */
2529 class StyleFunctionGradient { 2524 class StyleFunctionGradient {
2530 /** Array with two or more colors. */ 2525 /// Array with two or more colors.
2531 core.List<StyleFunctionGradientColors> colors; 2526 core.List<StyleFunctionGradientColors> colors;
2532 /** 2527
2533 * Higher-end of the interpolation range: rows with this value will be 2528 /// Higher-end of the interpolation range: rows with this value will be
2534 * assigned to colors[n-1]. 2529 /// assigned to colors[n-1].
2535 */
2536 core.double max; 2530 core.double max;
2537 /** 2531
2538 * Lower-end of the interpolation range: rows with this value will be assigned 2532 /// Lower-end of the interpolation range: rows with this value will be
2539 * to colors[0]. 2533 /// assigned to colors[0].
2540 */
2541 core.double min; 2534 core.double min;
2542 2535
2543 StyleFunctionGradient(); 2536 StyleFunctionGradient();
2544 2537
2545 StyleFunctionGradient.fromJson(core.Map _json) { 2538 StyleFunctionGradient.fromJson(core.Map _json) {
2546 if (_json.containsKey("colors")) { 2539 if (_json.containsKey("colors")) {
2547 colors = _json["colors"].map((value) => new StyleFunctionGradientColors.fr omJson(value)).toList(); 2540 colors = _json["colors"]
2541 .map((value) => new StyleFunctionGradientColors.fromJson(value))
2542 .toList();
2548 } 2543 }
2549 if (_json.containsKey("max")) { 2544 if (_json.containsKey("max")) {
2550 max = _json["max"]; 2545 max = _json["max"];
2551 } 2546 }
2552 if (_json.containsKey("min")) { 2547 if (_json.containsKey("min")) {
2553 min = _json["min"]; 2548 min = _json["min"];
2554 } 2549 }
2555 } 2550 }
2556 2551
2557 core.Map<core.String, core.Object> toJson() { 2552 core.Map<core.String, core.Object> toJson() {
2558 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2553 final core.Map<core.String, core.Object> _json =
2554 new core.Map<core.String, core.Object>();
2559 if (colors != null) { 2555 if (colors != null) {
2560 _json["colors"] = colors.map((value) => (value).toJson()).toList(); 2556 _json["colors"] = colors.map((value) => (value).toJson()).toList();
2561 } 2557 }
2562 if (max != null) { 2558 if (max != null) {
2563 _json["max"] = max; 2559 _json["max"] = max;
2564 } 2560 }
2565 if (min != null) { 2561 if (min != null) {
2566 _json["min"] = min; 2562 _json["min"] = min;
2567 } 2563 }
2568 return _json; 2564 return _json;
2569 } 2565 }
2570 } 2566 }
2571 2567
2572 /** Represents a StyleFunction within a StyleSetting */ 2568 /// Represents a StyleFunction within a StyleSetting
2573 class StyleFunction { 2569 class StyleFunction {
2574 /** 2570 /// Bucket function that assigns a style based on the range a column value
2575 * Bucket function that assigns a style based on the range a column value 2571 /// falls into.
2576 * falls into.
2577 */
2578 core.List<Bucket> buckets; 2572 core.List<Bucket> buckets;
2579 /** Name of the column whose value is used in the style. */ 2573
2574 /// Name of the column whose value is used in the style.
2580 core.String columnName; 2575 core.String columnName;
2581 /** 2576
2582 * Gradient function that interpolates a range of colors based on column 2577 /// Gradient function that interpolates a range of colors based on column
2583 * value. 2578 /// value.
2584 */
2585 StyleFunctionGradient gradient; 2579 StyleFunctionGradient gradient;
2586 /** 2580
2587 * Stylers can be one of three kinds: "fusiontables#fromColumn if the column 2581 /// Stylers can be one of three kinds: "fusiontables#fromColumn if the column
2588 * value is to be used as is, i.e., the column values can have colors in 2582 /// value is to be used as is, i.e., the column values can have colors in
2589 * #RRGGBBAA format or integer line widths or icon names; 2583 /// #RRGGBBAA format or integer line widths or icon names;
2590 * fusiontables#gradient if the styling of the row is to be based on applying 2584 /// fusiontables#gradient if the styling of the row is to be based on
2591 * the gradient function on the column value; or fusiontables#buckets if the 2585 /// applying the gradient function on the column value; or
2592 * styling is to based on the bucket into which the the column value falls. 2586 /// fusiontables#buckets if the styling is to based on the bucket into which
2593 */ 2587 /// the the column value falls.
2594 core.String kind; 2588 core.String kind;
2595 2589
2596 StyleFunction(); 2590 StyleFunction();
2597 2591
2598 StyleFunction.fromJson(core.Map _json) { 2592 StyleFunction.fromJson(core.Map _json) {
2599 if (_json.containsKey("buckets")) { 2593 if (_json.containsKey("buckets")) {
2600 buckets = _json["buckets"].map((value) => new Bucket.fromJson(value)).toLi st(); 2594 buckets =
2595 _json["buckets"].map((value) => new Bucket.fromJson(value)).toList();
2601 } 2596 }
2602 if (_json.containsKey("columnName")) { 2597 if (_json.containsKey("columnName")) {
2603 columnName = _json["columnName"]; 2598 columnName = _json["columnName"];
2604 } 2599 }
2605 if (_json.containsKey("gradient")) { 2600 if (_json.containsKey("gradient")) {
2606 gradient = new StyleFunctionGradient.fromJson(_json["gradient"]); 2601 gradient = new StyleFunctionGradient.fromJson(_json["gradient"]);
2607 } 2602 }
2608 if (_json.containsKey("kind")) { 2603 if (_json.containsKey("kind")) {
2609 kind = _json["kind"]; 2604 kind = _json["kind"];
2610 } 2605 }
2611 } 2606 }
2612 2607
2613 core.Map<core.String, core.Object> toJson() { 2608 core.Map<core.String, core.Object> toJson() {
2614 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2609 final core.Map<core.String, core.Object> _json =
2610 new core.Map<core.String, core.Object>();
2615 if (buckets != null) { 2611 if (buckets != null) {
2616 _json["buckets"] = buckets.map((value) => (value).toJson()).toList(); 2612 _json["buckets"] = buckets.map((value) => (value).toJson()).toList();
2617 } 2613 }
2618 if (columnName != null) { 2614 if (columnName != null) {
2619 _json["columnName"] = columnName; 2615 _json["columnName"] = columnName;
2620 } 2616 }
2621 if (gradient != null) { 2617 if (gradient != null) {
2622 _json["gradient"] = (gradient).toJson(); 2618 _json["gradient"] = (gradient).toJson();
2623 } 2619 }
2624 if (kind != null) { 2620 if (kind != null) {
2625 _json["kind"] = kind; 2621 _json["kind"] = kind;
2626 } 2622 }
2627 return _json; 2623 return _json;
2628 } 2624 }
2629 } 2625 }
2630 2626
2631 /** 2627 /// Represents a complete StyleSettings object. The primary key is a
2632 * Represents a complete StyleSettings object. The primary key is a combination 2628 /// combination of the tableId and a styleId.
2633 * of the tableId and a styleId.
2634 */
2635 class StyleSetting { 2629 class StyleSetting {
2636 /** 2630 /// The kind of item this is. A StyleSetting contains the style definitions
2637 * The kind of item this is. A StyleSetting contains the style definitions for 2631 /// for points, lines, and polygons in a table. Since a table can have any
2638 * points, lines, and polygons in a table. Since a table can have any one or 2632 /// one or all of them, a style definition can have point, line and polygon
2639 * all of them, a style definition can have point, line and polygon style 2633 /// style definitions.
2640 * definitions.
2641 */
2642 core.String kind; 2634 core.String kind;
2643 /** Style definition for points in the table. */ 2635
2636 /// Style definition for points in the table.
2644 PointStyle markerOptions; 2637 PointStyle markerOptions;
2645 /** Optional name for the style setting. */ 2638
2639 /// Optional name for the style setting.
2646 core.String name; 2640 core.String name;
2647 /** Style definition for polygons in the table. */ 2641
2642 /// Style definition for polygons in the table.
2648 PolygonStyle polygonOptions; 2643 PolygonStyle polygonOptions;
2649 /** Style definition for lines in the table. */ 2644
2645 /// Style definition for lines in the table.
2650 LineStyle polylineOptions; 2646 LineStyle polylineOptions;
2651 /** Identifier for the style setting (unique only within tables). */ 2647
2648 /// Identifier for the style setting (unique only within tables).
2652 core.int styleId; 2649 core.int styleId;
2653 /** Identifier for the table. */ 2650
2651 /// Identifier for the table.
2654 core.String tableId; 2652 core.String tableId;
2655 2653
2656 StyleSetting(); 2654 StyleSetting();
2657 2655
2658 StyleSetting.fromJson(core.Map _json) { 2656 StyleSetting.fromJson(core.Map _json) {
2659 if (_json.containsKey("kind")) { 2657 if (_json.containsKey("kind")) {
2660 kind = _json["kind"]; 2658 kind = _json["kind"];
2661 } 2659 }
2662 if (_json.containsKey("markerOptions")) { 2660 if (_json.containsKey("markerOptions")) {
2663 markerOptions = new PointStyle.fromJson(_json["markerOptions"]); 2661 markerOptions = new PointStyle.fromJson(_json["markerOptions"]);
2664 } 2662 }
2665 if (_json.containsKey("name")) { 2663 if (_json.containsKey("name")) {
2666 name = _json["name"]; 2664 name = _json["name"];
2667 } 2665 }
2668 if (_json.containsKey("polygonOptions")) { 2666 if (_json.containsKey("polygonOptions")) {
2669 polygonOptions = new PolygonStyle.fromJson(_json["polygonOptions"]); 2667 polygonOptions = new PolygonStyle.fromJson(_json["polygonOptions"]);
2670 } 2668 }
2671 if (_json.containsKey("polylineOptions")) { 2669 if (_json.containsKey("polylineOptions")) {
2672 polylineOptions = new LineStyle.fromJson(_json["polylineOptions"]); 2670 polylineOptions = new LineStyle.fromJson(_json["polylineOptions"]);
2673 } 2671 }
2674 if (_json.containsKey("styleId")) { 2672 if (_json.containsKey("styleId")) {
2675 styleId = _json["styleId"]; 2673 styleId = _json["styleId"];
2676 } 2674 }
2677 if (_json.containsKey("tableId")) { 2675 if (_json.containsKey("tableId")) {
2678 tableId = _json["tableId"]; 2676 tableId = _json["tableId"];
2679 } 2677 }
2680 } 2678 }
2681 2679
2682 core.Map<core.String, core.Object> toJson() { 2680 core.Map<core.String, core.Object> toJson() {
2683 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2681 final core.Map<core.String, core.Object> _json =
2682 new core.Map<core.String, core.Object>();
2684 if (kind != null) { 2683 if (kind != null) {
2685 _json["kind"] = kind; 2684 _json["kind"] = kind;
2686 } 2685 }
2687 if (markerOptions != null) { 2686 if (markerOptions != null) {
2688 _json["markerOptions"] = (markerOptions).toJson(); 2687 _json["markerOptions"] = (markerOptions).toJson();
2689 } 2688 }
2690 if (name != null) { 2689 if (name != null) {
2691 _json["name"] = name; 2690 _json["name"] = name;
2692 } 2691 }
2693 if (polygonOptions != null) { 2692 if (polygonOptions != null) {
2694 _json["polygonOptions"] = (polygonOptions).toJson(); 2693 _json["polygonOptions"] = (polygonOptions).toJson();
2695 } 2694 }
2696 if (polylineOptions != null) { 2695 if (polylineOptions != null) {
2697 _json["polylineOptions"] = (polylineOptions).toJson(); 2696 _json["polylineOptions"] = (polylineOptions).toJson();
2698 } 2697 }
2699 if (styleId != null) { 2698 if (styleId != null) {
2700 _json["styleId"] = styleId; 2699 _json["styleId"] = styleId;
2701 } 2700 }
2702 if (tableId != null) { 2701 if (tableId != null) {
2703 _json["tableId"] = tableId; 2702 _json["tableId"] = tableId;
2704 } 2703 }
2705 return _json; 2704 return _json;
2706 } 2705 }
2707 } 2706 }
2708 2707
2709 /** Represents a list of styles for a given table. */ 2708 /// Represents a list of styles for a given table.
2710 class StyleSettingList { 2709 class StyleSettingList {
2711 /** All requested style settings. */ 2710 /// All requested style settings.
2712 core.List<StyleSetting> items; 2711 core.List<StyleSetting> items;
2713 /** 2712
2714 * The kind of item this is. For a style list, this is always 2713 /// The kind of item this is. For a style list, this is always
2715 * fusiontables#styleSettingList . 2714 /// fusiontables#styleSettingList .
2716 */
2717 core.String kind; 2715 core.String kind;
2718 /** 2716
2719 * Token used to access the next page of this result. No token is displayed if 2717 /// Token used to access the next page of this result. No token is displayed
2720 * there are no more styles left. 2718 /// if there are no more styles left.
2721 */
2722 core.String nextPageToken; 2719 core.String nextPageToken;
2723 /** Total number of styles for the table. */ 2720
2721 /// Total number of styles for the table.
2724 core.int totalItems; 2722 core.int totalItems;
2725 2723
2726 StyleSettingList(); 2724 StyleSettingList();
2727 2725
2728 StyleSettingList.fromJson(core.Map _json) { 2726 StyleSettingList.fromJson(core.Map _json) {
2729 if (_json.containsKey("items")) { 2727 if (_json.containsKey("items")) {
2730 items = _json["items"].map((value) => new StyleSetting.fromJson(value)).to List(); 2728 items = _json["items"]
2729 .map((value) => new StyleSetting.fromJson(value))
2730 .toList();
2731 } 2731 }
2732 if (_json.containsKey("kind")) { 2732 if (_json.containsKey("kind")) {
2733 kind = _json["kind"]; 2733 kind = _json["kind"];
2734 } 2734 }
2735 if (_json.containsKey("nextPageToken")) { 2735 if (_json.containsKey("nextPageToken")) {
2736 nextPageToken = _json["nextPageToken"]; 2736 nextPageToken = _json["nextPageToken"];
2737 } 2737 }
2738 if (_json.containsKey("totalItems")) { 2738 if (_json.containsKey("totalItems")) {
2739 totalItems = _json["totalItems"]; 2739 totalItems = _json["totalItems"];
2740 } 2740 }
2741 } 2741 }
2742 2742
2743 core.Map<core.String, core.Object> toJson() { 2743 core.Map<core.String, core.Object> toJson() {
2744 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2744 final core.Map<core.String, core.Object> _json =
2745 new core.Map<core.String, core.Object>();
2745 if (items != null) { 2746 if (items != null) {
2746 _json["items"] = items.map((value) => (value).toJson()).toList(); 2747 _json["items"] = items.map((value) => (value).toJson()).toList();
2747 } 2748 }
2748 if (kind != null) { 2749 if (kind != null) {
2749 _json["kind"] = kind; 2750 _json["kind"] = kind;
2750 } 2751 }
2751 if (nextPageToken != null) { 2752 if (nextPageToken != null) {
2752 _json["nextPageToken"] = nextPageToken; 2753 _json["nextPageToken"] = nextPageToken;
2753 } 2754 }
2754 if (totalItems != null) { 2755 if (totalItems != null) {
2755 _json["totalItems"] = totalItems; 2756 _json["totalItems"] = totalItems;
2756 } 2757 }
2757 return _json; 2758 return _json;
2758 } 2759 }
2759 } 2760 }
2760 2761
2761 /** Represents a table. */ 2762 /// Represents a table.
2762 class Table { 2763 class Table {
2763 /** Attribution assigned to the table. */ 2764 /// Attribution assigned to the table.
2764 core.String attribution; 2765 core.String attribution;
2765 /** Optional link for attribution. */ 2766
2767 /// Optional link for attribution.
2766 core.String attributionLink; 2768 core.String attributionLink;
2767 /** Base table identifier if this table is a view or merged table. */ 2769
2770 /// Base table identifier if this table is a view or merged table.
2768 core.List<core.String> baseTableIds; 2771 core.List<core.String> baseTableIds;
2769 /** Default JSON schema for validating all JSON column properties. */ 2772
2773 /// Default JSON schema for validating all JSON column properties.
2770 core.String columnPropertiesJsonSchema; 2774 core.String columnPropertiesJsonSchema;
2771 /** Columns in the table. */ 2775
2776 /// Columns in the table.
2772 core.List<Column> columns; 2777 core.List<Column> columns;
2773 /** Description assigned to the table. */ 2778
2779 /// Description assigned to the table.
2774 core.String description; 2780 core.String description;
2775 /** Variable for whether table is exportable. */ 2781
2782 /// Variable for whether table is exportable.
2776 core.bool isExportable; 2783 core.bool isExportable;
2777 /** 2784
2778 * The kind of item this is. For a table, this is always fusiontables#table. 2785 /// The kind of item this is. For a table, this is always fusiontables#table.
2779 */
2780 core.String kind; 2786 core.String kind;
2781 /** Name assigned to a table. */ 2787
2788 /// Name assigned to a table.
2782 core.String name; 2789 core.String name;
2783 /** SQL that encodes the table definition for derived tables. */ 2790
2791 /// SQL that encodes the table definition for derived tables.
2784 core.String sql; 2792 core.String sql;
2785 /** Encrypted unique alphanumeric identifier for the table. */ 2793
2794 /// Encrypted unique alphanumeric identifier for the table.
2786 core.String tableId; 2795 core.String tableId;
2787 /** JSON object containing custom table properties. */ 2796
2797 /// JSON object containing custom table properties.
2788 core.String tablePropertiesJson; 2798 core.String tablePropertiesJson;
2789 /** JSON schema for validating the JSON table properties. */ 2799
2800 /// JSON schema for validating the JSON table properties.
2790 core.String tablePropertiesJsonSchema; 2801 core.String tablePropertiesJsonSchema;
2791 2802
2792 Table(); 2803 Table();
2793 2804
2794 Table.fromJson(core.Map _json) { 2805 Table.fromJson(core.Map _json) {
2795 if (_json.containsKey("attribution")) { 2806 if (_json.containsKey("attribution")) {
2796 attribution = _json["attribution"]; 2807 attribution = _json["attribution"];
2797 } 2808 }
2798 if (_json.containsKey("attributionLink")) { 2809 if (_json.containsKey("attributionLink")) {
2799 attributionLink = _json["attributionLink"]; 2810 attributionLink = _json["attributionLink"];
2800 } 2811 }
2801 if (_json.containsKey("baseTableIds")) { 2812 if (_json.containsKey("baseTableIds")) {
2802 baseTableIds = _json["baseTableIds"]; 2813 baseTableIds = _json["baseTableIds"];
2803 } 2814 }
2804 if (_json.containsKey("columnPropertiesJsonSchema")) { 2815 if (_json.containsKey("columnPropertiesJsonSchema")) {
2805 columnPropertiesJsonSchema = _json["columnPropertiesJsonSchema"]; 2816 columnPropertiesJsonSchema = _json["columnPropertiesJsonSchema"];
2806 } 2817 }
2807 if (_json.containsKey("columns")) { 2818 if (_json.containsKey("columns")) {
2808 columns = _json["columns"].map((value) => new Column.fromJson(value)).toLi st(); 2819 columns =
2820 _json["columns"].map((value) => new Column.fromJson(value)).toList();
2809 } 2821 }
2810 if (_json.containsKey("description")) { 2822 if (_json.containsKey("description")) {
2811 description = _json["description"]; 2823 description = _json["description"];
2812 } 2824 }
2813 if (_json.containsKey("isExportable")) { 2825 if (_json.containsKey("isExportable")) {
2814 isExportable = _json["isExportable"]; 2826 isExportable = _json["isExportable"];
2815 } 2827 }
2816 if (_json.containsKey("kind")) { 2828 if (_json.containsKey("kind")) {
2817 kind = _json["kind"]; 2829 kind = _json["kind"];
2818 } 2830 }
2819 if (_json.containsKey("name")) { 2831 if (_json.containsKey("name")) {
2820 name = _json["name"]; 2832 name = _json["name"];
2821 } 2833 }
2822 if (_json.containsKey("sql")) { 2834 if (_json.containsKey("sql")) {
2823 sql = _json["sql"]; 2835 sql = _json["sql"];
2824 } 2836 }
2825 if (_json.containsKey("tableId")) { 2837 if (_json.containsKey("tableId")) {
2826 tableId = _json["tableId"]; 2838 tableId = _json["tableId"];
2827 } 2839 }
2828 if (_json.containsKey("tablePropertiesJson")) { 2840 if (_json.containsKey("tablePropertiesJson")) {
2829 tablePropertiesJson = _json["tablePropertiesJson"]; 2841 tablePropertiesJson = _json["tablePropertiesJson"];
2830 } 2842 }
2831 if (_json.containsKey("tablePropertiesJsonSchema")) { 2843 if (_json.containsKey("tablePropertiesJsonSchema")) {
2832 tablePropertiesJsonSchema = _json["tablePropertiesJsonSchema"]; 2844 tablePropertiesJsonSchema = _json["tablePropertiesJsonSchema"];
2833 } 2845 }
2834 } 2846 }
2835 2847
2836 core.Map<core.String, core.Object> toJson() { 2848 core.Map<core.String, core.Object> toJson() {
2837 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2849 final core.Map<core.String, core.Object> _json =
2850 new core.Map<core.String, core.Object>();
2838 if (attribution != null) { 2851 if (attribution != null) {
2839 _json["attribution"] = attribution; 2852 _json["attribution"] = attribution;
2840 } 2853 }
2841 if (attributionLink != null) { 2854 if (attributionLink != null) {
2842 _json["attributionLink"] = attributionLink; 2855 _json["attributionLink"] = attributionLink;
2843 } 2856 }
2844 if (baseTableIds != null) { 2857 if (baseTableIds != null) {
2845 _json["baseTableIds"] = baseTableIds; 2858 _json["baseTableIds"] = baseTableIds;
2846 } 2859 }
2847 if (columnPropertiesJsonSchema != null) { 2860 if (columnPropertiesJsonSchema != null) {
(...skipping 23 matching lines...) Expand all
2871 if (tablePropertiesJson != null) { 2884 if (tablePropertiesJson != null) {
2872 _json["tablePropertiesJson"] = tablePropertiesJson; 2885 _json["tablePropertiesJson"] = tablePropertiesJson;
2873 } 2886 }
2874 if (tablePropertiesJsonSchema != null) { 2887 if (tablePropertiesJsonSchema != null) {
2875 _json["tablePropertiesJsonSchema"] = tablePropertiesJsonSchema; 2888 _json["tablePropertiesJsonSchema"] = tablePropertiesJsonSchema;
2876 } 2889 }
2877 return _json; 2890 return _json;
2878 } 2891 }
2879 } 2892 }
2880 2893
2881 /** Represents a list of tables. */ 2894 /// Represents a list of tables.
2882 class TableList { 2895 class TableList {
2883 /** List of all requested tables. */ 2896 /// List of all requested tables.
2884 core.List<Table> items; 2897 core.List<Table> items;
2885 /** 2898
2886 * The kind of item this is. For table list, this is always 2899 /// The kind of item this is. For table list, this is always
2887 * fusiontables#tableList. 2900 /// fusiontables#tableList.
2888 */
2889 core.String kind; 2901 core.String kind;
2890 /** 2902
2891 * Token used to access the next page of this result. No token is displayed if 2903 /// Token used to access the next page of this result. No token is displayed
2892 * there are no more pages left. 2904 /// if there are no more pages left.
2893 */
2894 core.String nextPageToken; 2905 core.String nextPageToken;
2895 2906
2896 TableList(); 2907 TableList();
2897 2908
2898 TableList.fromJson(core.Map _json) { 2909 TableList.fromJson(core.Map _json) {
2899 if (_json.containsKey("items")) { 2910 if (_json.containsKey("items")) {
2900 items = _json["items"].map((value) => new Table.fromJson(value)).toList(); 2911 items = _json["items"].map((value) => new Table.fromJson(value)).toList();
2901 } 2912 }
2902 if (_json.containsKey("kind")) { 2913 if (_json.containsKey("kind")) {
2903 kind = _json["kind"]; 2914 kind = _json["kind"];
2904 } 2915 }
2905 if (_json.containsKey("nextPageToken")) { 2916 if (_json.containsKey("nextPageToken")) {
2906 nextPageToken = _json["nextPageToken"]; 2917 nextPageToken = _json["nextPageToken"];
2907 } 2918 }
2908 } 2919 }
2909 2920
2910 core.Map<core.String, core.Object> toJson() { 2921 core.Map<core.String, core.Object> toJson() {
2911 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2922 final core.Map<core.String, core.Object> _json =
2923 new core.Map<core.String, core.Object>();
2912 if (items != null) { 2924 if (items != null) {
2913 _json["items"] = items.map((value) => (value).toJson()).toList(); 2925 _json["items"] = items.map((value) => (value).toJson()).toList();
2914 } 2926 }
2915 if (kind != null) { 2927 if (kind != null) {
2916 _json["kind"] = kind; 2928 _json["kind"] = kind;
2917 } 2929 }
2918 if (nextPageToken != null) { 2930 if (nextPageToken != null) {
2919 _json["nextPageToken"] = nextPageToken; 2931 _json["nextPageToken"] = nextPageToken;
2920 } 2932 }
2921 return _json; 2933 return _json;
2922 } 2934 }
2923 } 2935 }
2924 2936
2925 /** 2937 /// A background task on a table, initiated for time- or resource-consuming
2926 * A background task on a table, initiated for time- or resource-consuming 2938 /// operations such as changing column types or deleting all rows.
2927 * operations such as changing column types or deleting all rows.
2928 */
2929 class Task { 2939 class Task {
2930 /** Type of the resource. This is always "fusiontables#task". */ 2940 /// Type of the resource. This is always "fusiontables#task".
2931 core.String kind; 2941 core.String kind;
2932 /** Task percentage completion. */ 2942
2943 /// Task percentage completion.
2933 core.String progress; 2944 core.String progress;
2934 /** 2945
2935 * false while the table is busy with some other task. true if this background 2946 /// false while the table is busy with some other task. true if this
2936 * task is currently running. 2947 /// background task is currently running.
2937 */
2938 core.bool started; 2948 core.bool started;
2939 /** Identifier for the task. */ 2949
2950 /// Identifier for the task.
2940 core.String taskId; 2951 core.String taskId;
2941 /** Type of background task. */ 2952
2953 /// Type of background task.
2942 core.String type; 2954 core.String type;
2943 2955
2944 Task(); 2956 Task();
2945 2957
2946 Task.fromJson(core.Map _json) { 2958 Task.fromJson(core.Map _json) {
2947 if (_json.containsKey("kind")) { 2959 if (_json.containsKey("kind")) {
2948 kind = _json["kind"]; 2960 kind = _json["kind"];
2949 } 2961 }
2950 if (_json.containsKey("progress")) { 2962 if (_json.containsKey("progress")) {
2951 progress = _json["progress"]; 2963 progress = _json["progress"];
2952 } 2964 }
2953 if (_json.containsKey("started")) { 2965 if (_json.containsKey("started")) {
2954 started = _json["started"]; 2966 started = _json["started"];
2955 } 2967 }
2956 if (_json.containsKey("taskId")) { 2968 if (_json.containsKey("taskId")) {
2957 taskId = _json["taskId"]; 2969 taskId = _json["taskId"];
2958 } 2970 }
2959 if (_json.containsKey("type")) { 2971 if (_json.containsKey("type")) {
2960 type = _json["type"]; 2972 type = _json["type"];
2961 } 2973 }
2962 } 2974 }
2963 2975
2964 core.Map<core.String, core.Object> toJson() { 2976 core.Map<core.String, core.Object> toJson() {
2965 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 2977 final core.Map<core.String, core.Object> _json =
2978 new core.Map<core.String, core.Object>();
2966 if (kind != null) { 2979 if (kind != null) {
2967 _json["kind"] = kind; 2980 _json["kind"] = kind;
2968 } 2981 }
2969 if (progress != null) { 2982 if (progress != null) {
2970 _json["progress"] = progress; 2983 _json["progress"] = progress;
2971 } 2984 }
2972 if (started != null) { 2985 if (started != null) {
2973 _json["started"] = started; 2986 _json["started"] = started;
2974 } 2987 }
2975 if (taskId != null) { 2988 if (taskId != null) {
2976 _json["taskId"] = taskId; 2989 _json["taskId"] = taskId;
2977 } 2990 }
2978 if (type != null) { 2991 if (type != null) {
2979 _json["type"] = type; 2992 _json["type"] = type;
2980 } 2993 }
2981 return _json; 2994 return _json;
2982 } 2995 }
2983 } 2996 }
2984 2997
2985 /** Represents a list of tasks for a table. */ 2998 /// Represents a list of tasks for a table.
2986 class TaskList { 2999 class TaskList {
2987 /** List of all requested tasks. */ 3000 /// List of all requested tasks.
2988 core.List<Task> items; 3001 core.List<Task> items;
2989 /** Type of the resource. This is always "fusiontables#taskList". */ 3002
3003 /// Type of the resource. This is always "fusiontables#taskList".
2990 core.String kind; 3004 core.String kind;
2991 /** 3005
2992 * Token used to access the next page of this result. No token is displayed if 3006 /// Token used to access the next page of this result. No token is displayed
2993 * there are no more pages left. 3007 /// if there are no more pages left.
2994 */
2995 core.String nextPageToken; 3008 core.String nextPageToken;
2996 /** Total number of tasks for the table. */ 3009
3010 /// Total number of tasks for the table.
2997 core.int totalItems; 3011 core.int totalItems;
2998 3012
2999 TaskList(); 3013 TaskList();
3000 3014
3001 TaskList.fromJson(core.Map _json) { 3015 TaskList.fromJson(core.Map _json) {
3002 if (_json.containsKey("items")) { 3016 if (_json.containsKey("items")) {
3003 items = _json["items"].map((value) => new Task.fromJson(value)).toList(); 3017 items = _json["items"].map((value) => new Task.fromJson(value)).toList();
3004 } 3018 }
3005 if (_json.containsKey("kind")) { 3019 if (_json.containsKey("kind")) {
3006 kind = _json["kind"]; 3020 kind = _json["kind"];
3007 } 3021 }
3008 if (_json.containsKey("nextPageToken")) { 3022 if (_json.containsKey("nextPageToken")) {
3009 nextPageToken = _json["nextPageToken"]; 3023 nextPageToken = _json["nextPageToken"];
3010 } 3024 }
3011 if (_json.containsKey("totalItems")) { 3025 if (_json.containsKey("totalItems")) {
3012 totalItems = _json["totalItems"]; 3026 totalItems = _json["totalItems"];
3013 } 3027 }
3014 } 3028 }
3015 3029
3016 core.Map<core.String, core.Object> toJson() { 3030 core.Map<core.String, core.Object> toJson() {
3017 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 3031 final core.Map<core.String, core.Object> _json =
3032 new core.Map<core.String, core.Object>();
3018 if (items != null) { 3033 if (items != null) {
3019 _json["items"] = items.map((value) => (value).toJson()).toList(); 3034 _json["items"] = items.map((value) => (value).toJson()).toList();
3020 } 3035 }
3021 if (kind != null) { 3036 if (kind != null) {
3022 _json["kind"] = kind; 3037 _json["kind"] = kind;
3023 } 3038 }
3024 if (nextPageToken != null) { 3039 if (nextPageToken != null) {
3025 _json["nextPageToken"] = nextPageToken; 3040 _json["nextPageToken"] = nextPageToken;
3026 } 3041 }
3027 if (totalItems != null) { 3042 if (totalItems != null) {
3028 _json["totalItems"] = totalItems; 3043 _json["totalItems"] = totalItems;
3029 } 3044 }
3030 return _json; 3045 return _json;
3031 } 3046 }
3032 } 3047 }
3033 3048
3034 /** Represents the contents of InfoWindow templates. */ 3049 /// Represents the contents of InfoWindow templates.
3035 class Template { 3050 class Template {
3036 /** 3051 /// List of columns from which the template is to be automatically
3037 * List of columns from which the template is to be automatically constructed. 3052 /// constructed. Only one of body or automaticColumns can be specified.
3038 * Only one of body or automaticColumns can be specified.
3039 */
3040 core.List<core.String> automaticColumnNames; 3053 core.List<core.String> automaticColumnNames;
3041 /** 3054
3042 * Body of the template. It contains HTML with {column_name} to insert values 3055 /// Body of the template. It contains HTML with {column_name} to insert
3043 * from a particular column. The body is sanitized to remove certain tags, 3056 /// values from a particular column. The body is sanitized to remove certain
3044 * e.g., script. Only one of body or automaticColumns can be specified. 3057 /// tags, e.g., script. Only one of body or automaticColumns can be
3045 */ 3058 /// specified.
3046 core.String body; 3059 core.String body;
3047 /** 3060
3048 * The kind of item this is. For a template, this is always 3061 /// The kind of item this is. For a template, this is always
3049 * fusiontables#template. 3062 /// fusiontables#template.
3050 */
3051 core.String kind; 3063 core.String kind;
3052 /** Optional name assigned to a template. */ 3064
3065 /// Optional name assigned to a template.
3053 core.String name; 3066 core.String name;
3054 /** Identifier for the table for which the template is defined. */ 3067
3068 /// Identifier for the table for which the template is defined.
3055 core.String tableId; 3069 core.String tableId;
3056 /** 3070
3057 * Identifier for the template, unique within the context of a particular 3071 /// Identifier for the template, unique within the context of a particular
3058 * table. 3072 /// table.
3059 */
3060 core.int templateId; 3073 core.int templateId;
3061 3074
3062 Template(); 3075 Template();
3063 3076
3064 Template.fromJson(core.Map _json) { 3077 Template.fromJson(core.Map _json) {
3065 if (_json.containsKey("automaticColumnNames")) { 3078 if (_json.containsKey("automaticColumnNames")) {
3066 automaticColumnNames = _json["automaticColumnNames"]; 3079 automaticColumnNames = _json["automaticColumnNames"];
3067 } 3080 }
3068 if (_json.containsKey("body")) { 3081 if (_json.containsKey("body")) {
3069 body = _json["body"]; 3082 body = _json["body"];
3070 } 3083 }
3071 if (_json.containsKey("kind")) { 3084 if (_json.containsKey("kind")) {
3072 kind = _json["kind"]; 3085 kind = _json["kind"];
3073 } 3086 }
3074 if (_json.containsKey("name")) { 3087 if (_json.containsKey("name")) {
3075 name = _json["name"]; 3088 name = _json["name"];
3076 } 3089 }
3077 if (_json.containsKey("tableId")) { 3090 if (_json.containsKey("tableId")) {
3078 tableId = _json["tableId"]; 3091 tableId = _json["tableId"];
3079 } 3092 }
3080 if (_json.containsKey("templateId")) { 3093 if (_json.containsKey("templateId")) {
3081 templateId = _json["templateId"]; 3094 templateId = _json["templateId"];
3082 } 3095 }
3083 } 3096 }
3084 3097
3085 core.Map<core.String, core.Object> toJson() { 3098 core.Map<core.String, core.Object> toJson() {
3086 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 3099 final core.Map<core.String, core.Object> _json =
3100 new core.Map<core.String, core.Object>();
3087 if (automaticColumnNames != null) { 3101 if (automaticColumnNames != null) {
3088 _json["automaticColumnNames"] = automaticColumnNames; 3102 _json["automaticColumnNames"] = automaticColumnNames;
3089 } 3103 }
3090 if (body != null) { 3104 if (body != null) {
3091 _json["body"] = body; 3105 _json["body"] = body;
3092 } 3106 }
3093 if (kind != null) { 3107 if (kind != null) {
3094 _json["kind"] = kind; 3108 _json["kind"] = kind;
3095 } 3109 }
3096 if (name != null) { 3110 if (name != null) {
3097 _json["name"] = name; 3111 _json["name"] = name;
3098 } 3112 }
3099 if (tableId != null) { 3113 if (tableId != null) {
3100 _json["tableId"] = tableId; 3114 _json["tableId"] = tableId;
3101 } 3115 }
3102 if (templateId != null) { 3116 if (templateId != null) {
3103 _json["templateId"] = templateId; 3117 _json["templateId"] = templateId;
3104 } 3118 }
3105 return _json; 3119 return _json;
3106 } 3120 }
3107 } 3121 }
3108 3122
3109 /** Represents a list of templates for a given table. */ 3123 /// Represents a list of templates for a given table.
3110 class TemplateList { 3124 class TemplateList {
3111 /** List of all requested templates. */ 3125 /// List of all requested templates.
3112 core.List<Template> items; 3126 core.List<Template> items;
3113 /** 3127
3114 * The kind of item this is. For a template list, this is always 3128 /// The kind of item this is. For a template list, this is always
3115 * fusiontables#templateList . 3129 /// fusiontables#templateList .
3116 */
3117 core.String kind; 3130 core.String kind;
3118 /** 3131
3119 * Token used to access the next page of this result. No token is displayed if 3132 /// Token used to access the next page of this result. No token is displayed
3120 * there are no more pages left. 3133 /// if there are no more pages left.
3121 */
3122 core.String nextPageToken; 3134 core.String nextPageToken;
3123 /** Total number of templates for the table. */ 3135
3136 /// Total number of templates for the table.
3124 core.int totalItems; 3137 core.int totalItems;
3125 3138
3126 TemplateList(); 3139 TemplateList();
3127 3140
3128 TemplateList.fromJson(core.Map _json) { 3141 TemplateList.fromJson(core.Map _json) {
3129 if (_json.containsKey("items")) { 3142 if (_json.containsKey("items")) {
3130 items = _json["items"].map((value) => new Template.fromJson(value)).toList (); 3143 items =
3144 _json["items"].map((value) => new Template.fromJson(value)).toList();
3131 } 3145 }
3132 if (_json.containsKey("kind")) { 3146 if (_json.containsKey("kind")) {
3133 kind = _json["kind"]; 3147 kind = _json["kind"];
3134 } 3148 }
3135 if (_json.containsKey("nextPageToken")) { 3149 if (_json.containsKey("nextPageToken")) {
3136 nextPageToken = _json["nextPageToken"]; 3150 nextPageToken = _json["nextPageToken"];
3137 } 3151 }
3138 if (_json.containsKey("totalItems")) { 3152 if (_json.containsKey("totalItems")) {
3139 totalItems = _json["totalItems"]; 3153 totalItems = _json["totalItems"];
3140 } 3154 }
3141 } 3155 }
3142 3156
3143 core.Map<core.String, core.Object> toJson() { 3157 core.Map<core.String, core.Object> toJson() {
3144 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c ore.Object>(); 3158 final core.Map<core.String, core.Object> _json =
3159 new core.Map<core.String, core.Object>();
3145 if (items != null) { 3160 if (items != null) {
3146 _json["items"] = items.map((value) => (value).toJson()).toList(); 3161 _json["items"] = items.map((value) => (value).toJson()).toList();
3147 } 3162 }
3148 if (kind != null) { 3163 if (kind != null) {
3149 _json["kind"] = kind; 3164 _json["kind"] = kind;
3150 } 3165 }
3151 if (nextPageToken != null) { 3166 if (nextPageToken != null) {
3152 _json["nextPageToken"] = nextPageToken; 3167 _json["nextPageToken"] = nextPageToken;
3153 } 3168 }
3154 if (totalItems != null) { 3169 if (totalItems != null) {
3155 _json["totalItems"] = totalItems; 3170 _json["totalItems"] = totalItems;
3156 } 3171 }
3157 return _json; 3172 return _json;
3158 } 3173 }
3159 } 3174 }
OLDNEW
« no previous file with comments | « generated/googleapis/lib/fusiontables/v1.dart ('k') | generated/googleapis/lib/games/v1.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698