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

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

Powered by Google App Engine
This is Rietveld 408576698