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

Side by Side Diff: generated/googleapis/lib/tasks/v1.dart

Issue 1078053002: Roll of googleapis as of 4/7/2015. (Closed) Base URL: https://github.com/dart-lang/googleapis.git@master
Patch Set: Created 5 years, 8 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/tagmanager/v1.dart ('k') | generated/googleapis/lib/translate/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).
2
1 library googleapis.tasks.v1; 3 library googleapis.tasks.v1;
2 4
3 import "dart:core" as core; 5 import 'dart:core' as core;
4 import "dart:collection" as collection; 6 import 'dart:collection' as collection;
5 import "dart:async" as async; 7 import 'dart:async' as async;
6 import "dart:convert" as convert; 8 import 'dart:convert' as convert;
7 9
8 import "package:crypto/crypto.dart" as crypto; 10 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons;
11 import 'package:crypto/crypto.dart' as crypto;
9 import 'package:http/http.dart' as http; 12 import 'package:http/http.dart' as http;
10 import '../src/common_internal.dart' as common_internal;
11 import '../common/common.dart' as common;
12 13
13 export '../common/common.dart' show ApiRequestError; 14 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show
14 export '../common/common.dart' show DetailedApiRequestError; 15 ApiRequestError, DetailedApiRequestError;
16
17 const core.String USER_AGENT = 'dart-api-client tasks/v1';
15 18
16 /** Lets you manage your tasks and task lists. */ 19 /** Lets you manage your tasks and task lists. */
17 class TasksApi { 20 class TasksApi {
18 /** Manage your tasks */ 21 /** Manage your tasks */
19 static const TasksScope = "https://www.googleapis.com/auth/tasks"; 22 static const TasksScope = "https://www.googleapis.com/auth/tasks";
20 23
21 /** View your tasks */ 24 /** View your tasks */
22 static const TasksReadonlyScope = "https://www.googleapis.com/auth/tasks.reado nly"; 25 static const TasksReadonlyScope = "https://www.googleapis.com/auth/tasks.reado nly";
23 26
24 27
25 final common_internal.ApiRequester _requester; 28 final commons.ApiRequester _requester;
26 29
27 TasklistsResourceApi get tasklists => new TasklistsResourceApi(_requester); 30 TasklistsResourceApi get tasklists => new TasklistsResourceApi(_requester);
28 TasksResourceApi get tasks => new TasksResourceApi(_requester); 31 TasksResourceApi get tasks => new TasksResourceApi(_requester);
29 32
30 TasksApi(http.Client client, {core.String rootUrl: "https://www.googleapis.com /", core.String servicePath: "tasks/v1/"}) : 33 TasksApi(http.Client client, {core.String rootUrl: "https://www.googleapis.com /", core.String servicePath: "tasks/v1/"}) :
31 _requester = new common_internal.ApiRequester(client, rootUrl, servicePath ); 34 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A GENT);
32 } 35 }
33 36
34 37
35 /** Not documented yet. */
36 class TasklistsResourceApi { 38 class TasklistsResourceApi {
37 final common_internal.ApiRequester _requester; 39 final commons.ApiRequester _requester;
38 40
39 TasklistsResourceApi(common_internal.ApiRequester client) : 41 TasklistsResourceApi(commons.ApiRequester client) :
40 _requester = client; 42 _requester = client;
41 43
42 /** 44 /**
43 * Deletes the authenticated user's specified task list. 45 * Deletes the authenticated user's specified task list.
44 * 46 *
45 * Request parameters: 47 * Request parameters:
46 * 48 *
47 * [tasklist] - Task list identifier. 49 * [tasklist] - Task list identifier.
48 * 50 *
49 * Completes with a [common.ApiRequestError] if the API endpoint returned an 51 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
50 * error. 52 * error.
51 * 53 *
52 * If the used [http.Client] completes with an error when making a REST call, 54 * If the used [http.Client] completes with an error when making a REST call,
53 * this method will complete with the same error. 55 * this method will complete with the same error.
54 */ 56 */
55 async.Future delete(core.String tasklist) { 57 async.Future delete(core.String tasklist) {
56 var _url = null; 58 var _url = null;
57 var _queryParams = new core.Map(); 59 var _queryParams = new core.Map();
58 var _uploadMedia = null; 60 var _uploadMedia = null;
59 var _uploadOptions = null; 61 var _uploadOptions = null;
60 var _downloadOptions = common.DownloadOptions.Metadata; 62 var _downloadOptions = commons.DownloadOptions.Metadata;
61 var _body = null; 63 var _body = null;
62 64
63 if (tasklist == null) { 65 if (tasklist == null) {
64 throw new core.ArgumentError("Parameter tasklist is required."); 66 throw new core.ArgumentError("Parameter tasklist is required.");
65 } 67 }
66 68
67 _downloadOptions = null; 69 _downloadOptions = null;
68 70
69 _url = 'users/@me/lists/' + common_internal.Escaper.ecapeVariable('$tasklist '); 71 _url = 'users/@me/lists/' + commons.Escaper.ecapeVariable('$tasklist');
70 72
71 var _response = _requester.request(_url, 73 var _response = _requester.request(_url,
72 "DELETE", 74 "DELETE",
73 body: _body, 75 body: _body,
74 queryParams: _queryParams, 76 queryParams: _queryParams,
75 uploadOptions: _uploadOptions, 77 uploadOptions: _uploadOptions,
76 uploadMedia: _uploadMedia, 78 uploadMedia: _uploadMedia,
77 downloadOptions: _downloadOptions); 79 downloadOptions: _downloadOptions);
78 return _response.then((data) => null); 80 return _response.then((data) => null);
79 } 81 }
80 82
81 /** 83 /**
82 * Returns the authenticated user's specified task list. 84 * Returns the authenticated user's specified task list.
83 * 85 *
84 * Request parameters: 86 * Request parameters:
85 * 87 *
86 * [tasklist] - Task list identifier. 88 * [tasklist] - Task list identifier.
87 * 89 *
88 * Completes with a [TaskList]. 90 * Completes with a [TaskList].
89 * 91 *
90 * Completes with a [common.ApiRequestError] if the API endpoint returned an 92 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
91 * error. 93 * error.
92 * 94 *
93 * If the used [http.Client] completes with an error when making a REST call, 95 * If the used [http.Client] completes with an error when making a REST call,
94 * this method will complete with the same error. 96 * this method will complete with the same error.
95 */ 97 */
96 async.Future<TaskList> get(core.String tasklist) { 98 async.Future<TaskList> get(core.String tasklist) {
97 var _url = null; 99 var _url = null;
98 var _queryParams = new core.Map(); 100 var _queryParams = new core.Map();
99 var _uploadMedia = null; 101 var _uploadMedia = null;
100 var _uploadOptions = null; 102 var _uploadOptions = null;
101 var _downloadOptions = common.DownloadOptions.Metadata; 103 var _downloadOptions = commons.DownloadOptions.Metadata;
102 var _body = null; 104 var _body = null;
103 105
104 if (tasklist == null) { 106 if (tasklist == null) {
105 throw new core.ArgumentError("Parameter tasklist is required."); 107 throw new core.ArgumentError("Parameter tasklist is required.");
106 } 108 }
107 109
108 110
109 _url = 'users/@me/lists/' + common_internal.Escaper.ecapeVariable('$tasklist '); 111 _url = 'users/@me/lists/' + commons.Escaper.ecapeVariable('$tasklist');
110 112
111 var _response = _requester.request(_url, 113 var _response = _requester.request(_url,
112 "GET", 114 "GET",
113 body: _body, 115 body: _body,
114 queryParams: _queryParams, 116 queryParams: _queryParams,
115 uploadOptions: _uploadOptions, 117 uploadOptions: _uploadOptions,
116 uploadMedia: _uploadMedia, 118 uploadMedia: _uploadMedia,
117 downloadOptions: _downloadOptions); 119 downloadOptions: _downloadOptions);
118 return _response.then((data) => new TaskList.fromJson(data)); 120 return _response.then((data) => new TaskList.fromJson(data));
119 } 121 }
120 122
121 /** 123 /**
122 * Creates a new task list and adds it to the authenticated user's task lists. 124 * Creates a new task list and adds it to the authenticated user's task lists.
123 * 125 *
124 * [request] - The metadata request object. 126 * [request] - The metadata request object.
125 * 127 *
126 * Request parameters: 128 * Request parameters:
127 * 129 *
128 * Completes with a [TaskList]. 130 * Completes with a [TaskList].
129 * 131 *
130 * Completes with a [common.ApiRequestError] if the API endpoint returned an 132 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
131 * error. 133 * error.
132 * 134 *
133 * If the used [http.Client] completes with an error when making a REST call, 135 * If the used [http.Client] completes with an error when making a REST call,
134 * this method will complete with the same error. 136 * this method will complete with the same error.
135 */ 137 */
136 async.Future<TaskList> insert(TaskList request) { 138 async.Future<TaskList> insert(TaskList request) {
137 var _url = null; 139 var _url = null;
138 var _queryParams = new core.Map(); 140 var _queryParams = new core.Map();
139 var _uploadMedia = null; 141 var _uploadMedia = null;
140 var _uploadOptions = null; 142 var _uploadOptions = null;
141 var _downloadOptions = common.DownloadOptions.Metadata; 143 var _downloadOptions = commons.DownloadOptions.Metadata;
142 var _body = null; 144 var _body = null;
143 145
144 if (request != null) { 146 if (request != null) {
145 _body = convert.JSON.encode((request).toJson()); 147 _body = convert.JSON.encode((request).toJson());
146 } 148 }
147 149
148 150
149 _url = 'users/@me/lists'; 151 _url = 'users/@me/lists';
150 152
151 var _response = _requester.request(_url, 153 var _response = _requester.request(_url,
(...skipping 11 matching lines...) Expand all
163 * 165 *
164 * Request parameters: 166 * Request parameters:
165 * 167 *
166 * [maxResults] - Maximum number of task lists returned on one page. Optional. 168 * [maxResults] - Maximum number of task lists returned on one page. Optional.
167 * The default is 100. 169 * The default is 100.
168 * 170 *
169 * [pageToken] - Token specifying the result page to return. Optional. 171 * [pageToken] - Token specifying the result page to return. Optional.
170 * 172 *
171 * Completes with a [TaskLists]. 173 * Completes with a [TaskLists].
172 * 174 *
173 * Completes with a [common.ApiRequestError] if the API endpoint returned an 175 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
174 * error. 176 * error.
175 * 177 *
176 * If the used [http.Client] completes with an error when making a REST call, 178 * If the used [http.Client] completes with an error when making a REST call,
177 * this method will complete with the same error. 179 * this method will complete with the same error.
178 */ 180 */
179 async.Future<TaskLists> list({core.String maxResults, core.String pageToken}) { 181 async.Future<TaskLists> list({core.String maxResults, core.String pageToken}) {
180 var _url = null; 182 var _url = null;
181 var _queryParams = new core.Map(); 183 var _queryParams = new core.Map();
182 var _uploadMedia = null; 184 var _uploadMedia = null;
183 var _uploadOptions = null; 185 var _uploadOptions = null;
184 var _downloadOptions = common.DownloadOptions.Metadata; 186 var _downloadOptions = commons.DownloadOptions.Metadata;
185 var _body = null; 187 var _body = null;
186 188
187 if (maxResults != null) { 189 if (maxResults != null) {
188 _queryParams["maxResults"] = [maxResults]; 190 _queryParams["maxResults"] = [maxResults];
189 } 191 }
190 if (pageToken != null) { 192 if (pageToken != null) {
191 _queryParams["pageToken"] = [pageToken]; 193 _queryParams["pageToken"] = [pageToken];
192 } 194 }
193 195
194 196
(...skipping 14 matching lines...) Expand all
209 * patch semantics. 211 * patch semantics.
210 * 212 *
211 * [request] - The metadata request object. 213 * [request] - The metadata request object.
212 * 214 *
213 * Request parameters: 215 * Request parameters:
214 * 216 *
215 * [tasklist] - Task list identifier. 217 * [tasklist] - Task list identifier.
216 * 218 *
217 * Completes with a [TaskList]. 219 * Completes with a [TaskList].
218 * 220 *
219 * Completes with a [common.ApiRequestError] if the API endpoint returned an 221 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
220 * error. 222 * error.
221 * 223 *
222 * If the used [http.Client] completes with an error when making a REST call, 224 * If the used [http.Client] completes with an error when making a REST call,
223 * this method will complete with the same error. 225 * this method will complete with the same error.
224 */ 226 */
225 async.Future<TaskList> patch(TaskList request, core.String tasklist) { 227 async.Future<TaskList> patch(TaskList request, core.String tasklist) {
226 var _url = null; 228 var _url = null;
227 var _queryParams = new core.Map(); 229 var _queryParams = new core.Map();
228 var _uploadMedia = null; 230 var _uploadMedia = null;
229 var _uploadOptions = null; 231 var _uploadOptions = null;
230 var _downloadOptions = common.DownloadOptions.Metadata; 232 var _downloadOptions = commons.DownloadOptions.Metadata;
231 var _body = null; 233 var _body = null;
232 234
233 if (request != null) { 235 if (request != null) {
234 _body = convert.JSON.encode((request).toJson()); 236 _body = convert.JSON.encode((request).toJson());
235 } 237 }
236 if (tasklist == null) { 238 if (tasklist == null) {
237 throw new core.ArgumentError("Parameter tasklist is required."); 239 throw new core.ArgumentError("Parameter tasklist is required.");
238 } 240 }
239 241
240 242
241 _url = 'users/@me/lists/' + common_internal.Escaper.ecapeVariable('$tasklist '); 243 _url = 'users/@me/lists/' + commons.Escaper.ecapeVariable('$tasklist');
242 244
243 var _response = _requester.request(_url, 245 var _response = _requester.request(_url,
244 "PATCH", 246 "PATCH",
245 body: _body, 247 body: _body,
246 queryParams: _queryParams, 248 queryParams: _queryParams,
247 uploadOptions: _uploadOptions, 249 uploadOptions: _uploadOptions,
248 uploadMedia: _uploadMedia, 250 uploadMedia: _uploadMedia,
249 downloadOptions: _downloadOptions); 251 downloadOptions: _downloadOptions);
250 return _response.then((data) => new TaskList.fromJson(data)); 252 return _response.then((data) => new TaskList.fromJson(data));
251 } 253 }
252 254
253 /** 255 /**
254 * Updates the authenticated user's specified task list. 256 * Updates the authenticated user's specified task list.
255 * 257 *
256 * [request] - The metadata request object. 258 * [request] - The metadata request object.
257 * 259 *
258 * Request parameters: 260 * Request parameters:
259 * 261 *
260 * [tasklist] - Task list identifier. 262 * [tasklist] - Task list identifier.
261 * 263 *
262 * Completes with a [TaskList]. 264 * Completes with a [TaskList].
263 * 265 *
264 * Completes with a [common.ApiRequestError] if the API endpoint returned an 266 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
265 * error. 267 * error.
266 * 268 *
267 * If the used [http.Client] completes with an error when making a REST call, 269 * If the used [http.Client] completes with an error when making a REST call,
268 * this method will complete with the same error. 270 * this method will complete with the same error.
269 */ 271 */
270 async.Future<TaskList> update(TaskList request, core.String tasklist) { 272 async.Future<TaskList> update(TaskList request, core.String tasklist) {
271 var _url = null; 273 var _url = null;
272 var _queryParams = new core.Map(); 274 var _queryParams = new core.Map();
273 var _uploadMedia = null; 275 var _uploadMedia = null;
274 var _uploadOptions = null; 276 var _uploadOptions = null;
275 var _downloadOptions = common.DownloadOptions.Metadata; 277 var _downloadOptions = commons.DownloadOptions.Metadata;
276 var _body = null; 278 var _body = null;
277 279
278 if (request != null) { 280 if (request != null) {
279 _body = convert.JSON.encode((request).toJson()); 281 _body = convert.JSON.encode((request).toJson());
280 } 282 }
281 if (tasklist == null) { 283 if (tasklist == null) {
282 throw new core.ArgumentError("Parameter tasklist is required."); 284 throw new core.ArgumentError("Parameter tasklist is required.");
283 } 285 }
284 286
285 287
286 _url = 'users/@me/lists/' + common_internal.Escaper.ecapeVariable('$tasklist '); 288 _url = 'users/@me/lists/' + commons.Escaper.ecapeVariable('$tasklist');
287 289
288 var _response = _requester.request(_url, 290 var _response = _requester.request(_url,
289 "PUT", 291 "PUT",
290 body: _body, 292 body: _body,
291 queryParams: _queryParams, 293 queryParams: _queryParams,
292 uploadOptions: _uploadOptions, 294 uploadOptions: _uploadOptions,
293 uploadMedia: _uploadMedia, 295 uploadMedia: _uploadMedia,
294 downloadOptions: _downloadOptions); 296 downloadOptions: _downloadOptions);
295 return _response.then((data) => new TaskList.fromJson(data)); 297 return _response.then((data) => new TaskList.fromJson(data));
296 } 298 }
297 299
298 } 300 }
299 301
300 302
301 /** Not documented yet. */
302 class TasksResourceApi { 303 class TasksResourceApi {
303 final common_internal.ApiRequester _requester; 304 final commons.ApiRequester _requester;
304 305
305 TasksResourceApi(common_internal.ApiRequester client) : 306 TasksResourceApi(commons.ApiRequester client) :
306 _requester = client; 307 _requester = client;
307 308
308 /** 309 /**
309 * Clears all completed tasks from the specified task list. The affected tasks 310 * Clears all completed tasks from the specified task list. The affected tasks
310 * will be marked as 'hidden' and no longer be returned by default when 311 * will be marked as 'hidden' and no longer be returned by default when
311 * retrieving all tasks for a task list. 312 * retrieving all tasks for a task list.
312 * 313 *
313 * Request parameters: 314 * Request parameters:
314 * 315 *
315 * [tasklist] - Task list identifier. 316 * [tasklist] - Task list identifier.
316 * 317 *
317 * Completes with a [common.ApiRequestError] if the API endpoint returned an 318 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
318 * error. 319 * error.
319 * 320 *
320 * If the used [http.Client] completes with an error when making a REST call, 321 * If the used [http.Client] completes with an error when making a REST call,
321 * this method will complete with the same error. 322 * this method will complete with the same error.
322 */ 323 */
323 async.Future clear(core.String tasklist) { 324 async.Future clear(core.String tasklist) {
324 var _url = null; 325 var _url = null;
325 var _queryParams = new core.Map(); 326 var _queryParams = new core.Map();
326 var _uploadMedia = null; 327 var _uploadMedia = null;
327 var _uploadOptions = null; 328 var _uploadOptions = null;
328 var _downloadOptions = common.DownloadOptions.Metadata; 329 var _downloadOptions = commons.DownloadOptions.Metadata;
329 var _body = null; 330 var _body = null;
330 331
331 if (tasklist == null) { 332 if (tasklist == null) {
332 throw new core.ArgumentError("Parameter tasklist is required."); 333 throw new core.ArgumentError("Parameter tasklist is required.");
333 } 334 }
334 335
335 _downloadOptions = null; 336 _downloadOptions = null;
336 337
337 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/cle ar'; 338 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/clear';
338 339
339 var _response = _requester.request(_url, 340 var _response = _requester.request(_url,
340 "POST", 341 "POST",
341 body: _body, 342 body: _body,
342 queryParams: _queryParams, 343 queryParams: _queryParams,
343 uploadOptions: _uploadOptions, 344 uploadOptions: _uploadOptions,
344 uploadMedia: _uploadMedia, 345 uploadMedia: _uploadMedia,
345 downloadOptions: _downloadOptions); 346 downloadOptions: _downloadOptions);
346 return _response.then((data) => null); 347 return _response.then((data) => null);
347 } 348 }
348 349
349 /** 350 /**
350 * Deletes the specified task from the task list. 351 * Deletes the specified task from the task list.
351 * 352 *
352 * Request parameters: 353 * Request parameters:
353 * 354 *
354 * [tasklist] - Task list identifier. 355 * [tasklist] - Task list identifier.
355 * 356 *
356 * [task] - Task identifier. 357 * [task] - Task identifier.
357 * 358 *
358 * Completes with a [common.ApiRequestError] if the API endpoint returned an 359 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
359 * error. 360 * error.
360 * 361 *
361 * If the used [http.Client] completes with an error when making a REST call, 362 * If the used [http.Client] completes with an error when making a REST call,
362 * this method will complete with the same error. 363 * this method will complete with the same error.
363 */ 364 */
364 async.Future delete(core.String tasklist, core.String task) { 365 async.Future delete(core.String tasklist, core.String task) {
365 var _url = null; 366 var _url = null;
366 var _queryParams = new core.Map(); 367 var _queryParams = new core.Map();
367 var _uploadMedia = null; 368 var _uploadMedia = null;
368 var _uploadOptions = null; 369 var _uploadOptions = null;
369 var _downloadOptions = common.DownloadOptions.Metadata; 370 var _downloadOptions = commons.DownloadOptions.Metadata;
370 var _body = null; 371 var _body = null;
371 372
372 if (tasklist == null) { 373 if (tasklist == null) {
373 throw new core.ArgumentError("Parameter tasklist is required."); 374 throw new core.ArgumentError("Parameter tasklist is required.");
374 } 375 }
375 if (task == null) { 376 if (task == null) {
376 throw new core.ArgumentError("Parameter task is required."); 377 throw new core.ArgumentError("Parameter task is required.");
377 } 378 }
378 379
379 _downloadOptions = null; 380 _downloadOptions = null;
380 381
381 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/tas ks/' + common_internal.Escaper.ecapeVariable('$task'); 382 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/tasks/' + c ommons.Escaper.ecapeVariable('$task');
382 383
383 var _response = _requester.request(_url, 384 var _response = _requester.request(_url,
384 "DELETE", 385 "DELETE",
385 body: _body, 386 body: _body,
386 queryParams: _queryParams, 387 queryParams: _queryParams,
387 uploadOptions: _uploadOptions, 388 uploadOptions: _uploadOptions,
388 uploadMedia: _uploadMedia, 389 uploadMedia: _uploadMedia,
389 downloadOptions: _downloadOptions); 390 downloadOptions: _downloadOptions);
390 return _response.then((data) => null); 391 return _response.then((data) => null);
391 } 392 }
392 393
393 /** 394 /**
394 * Returns the specified task. 395 * Returns the specified task.
395 * 396 *
396 * Request parameters: 397 * Request parameters:
397 * 398 *
398 * [tasklist] - Task list identifier. 399 * [tasklist] - Task list identifier.
399 * 400 *
400 * [task] - Task identifier. 401 * [task] - Task identifier.
401 * 402 *
402 * Completes with a [Task]. 403 * Completes with a [Task].
403 * 404 *
404 * Completes with a [common.ApiRequestError] if the API endpoint returned an 405 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
405 * error. 406 * error.
406 * 407 *
407 * If the used [http.Client] completes with an error when making a REST call, 408 * If the used [http.Client] completes with an error when making a REST call,
408 * this method will complete with the same error. 409 * this method will complete with the same error.
409 */ 410 */
410 async.Future<Task> get(core.String tasklist, core.String task) { 411 async.Future<Task> get(core.String tasklist, core.String task) {
411 var _url = null; 412 var _url = null;
412 var _queryParams = new core.Map(); 413 var _queryParams = new core.Map();
413 var _uploadMedia = null; 414 var _uploadMedia = null;
414 var _uploadOptions = null; 415 var _uploadOptions = null;
415 var _downloadOptions = common.DownloadOptions.Metadata; 416 var _downloadOptions = commons.DownloadOptions.Metadata;
416 var _body = null; 417 var _body = null;
417 418
418 if (tasklist == null) { 419 if (tasklist == null) {
419 throw new core.ArgumentError("Parameter tasklist is required."); 420 throw new core.ArgumentError("Parameter tasklist is required.");
420 } 421 }
421 if (task == null) { 422 if (task == null) {
422 throw new core.ArgumentError("Parameter task is required."); 423 throw new core.ArgumentError("Parameter task is required.");
423 } 424 }
424 425
425 426
426 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/tas ks/' + common_internal.Escaper.ecapeVariable('$task'); 427 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/tasks/' + c ommons.Escaper.ecapeVariable('$task');
427 428
428 var _response = _requester.request(_url, 429 var _response = _requester.request(_url,
429 "GET", 430 "GET",
430 body: _body, 431 body: _body,
431 queryParams: _queryParams, 432 queryParams: _queryParams,
432 uploadOptions: _uploadOptions, 433 uploadOptions: _uploadOptions,
433 uploadMedia: _uploadMedia, 434 uploadMedia: _uploadMedia,
434 downloadOptions: _downloadOptions); 435 downloadOptions: _downloadOptions);
435 return _response.then((data) => new Task.fromJson(data)); 436 return _response.then((data) => new Task.fromJson(data));
436 } 437 }
437 438
438 /** 439 /**
439 * Creates a new task on the specified task list. 440 * Creates a new task on the specified task list.
440 * 441 *
441 * [request] - The metadata request object. 442 * [request] - The metadata request object.
442 * 443 *
443 * Request parameters: 444 * Request parameters:
444 * 445 *
445 * [tasklist] - Task list identifier. 446 * [tasklist] - Task list identifier.
446 * 447 *
447 * [parent] - Parent task identifier. If the task is created at the top level, 448 * [parent] - Parent task identifier. If the task is created at the top level,
448 * this parameter is omitted. Optional. 449 * this parameter is omitted. Optional.
449 * 450 *
450 * [previous] - Previous sibling task identifier. If the task is created at 451 * [previous] - Previous sibling task identifier. If the task is created at
451 * the first position among its siblings, this parameter is omitted. Optional. 452 * the first position among its siblings, this parameter is omitted. Optional.
452 * 453 *
453 * Completes with a [Task]. 454 * Completes with a [Task].
454 * 455 *
455 * Completes with a [common.ApiRequestError] if the API endpoint returned an 456 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
456 * error. 457 * error.
457 * 458 *
458 * If the used [http.Client] completes with an error when making a REST call, 459 * If the used [http.Client] completes with an error when making a REST call,
459 * this method will complete with the same error. 460 * this method will complete with the same error.
460 */ 461 */
461 async.Future<Task> insert(Task request, core.String tasklist, {core.String par ent, core.String previous}) { 462 async.Future<Task> insert(Task request, core.String tasklist, {core.String par ent, core.String previous}) {
462 var _url = null; 463 var _url = null;
463 var _queryParams = new core.Map(); 464 var _queryParams = new core.Map();
464 var _uploadMedia = null; 465 var _uploadMedia = null;
465 var _uploadOptions = null; 466 var _uploadOptions = null;
466 var _downloadOptions = common.DownloadOptions.Metadata; 467 var _downloadOptions = commons.DownloadOptions.Metadata;
467 var _body = null; 468 var _body = null;
468 469
469 if (request != null) { 470 if (request != null) {
470 _body = convert.JSON.encode((request).toJson()); 471 _body = convert.JSON.encode((request).toJson());
471 } 472 }
472 if (tasklist == null) { 473 if (tasklist == null) {
473 throw new core.ArgumentError("Parameter tasklist is required."); 474 throw new core.ArgumentError("Parameter tasklist is required.");
474 } 475 }
475 if (parent != null) { 476 if (parent != null) {
476 _queryParams["parent"] = [parent]; 477 _queryParams["parent"] = [parent];
477 } 478 }
478 if (previous != null) { 479 if (previous != null) {
479 _queryParams["previous"] = [previous]; 480 _queryParams["previous"] = [previous];
480 } 481 }
481 482
482 483
483 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/tas ks'; 484 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/tasks';
484 485
485 var _response = _requester.request(_url, 486 var _response = _requester.request(_url,
486 "POST", 487 "POST",
487 body: _body, 488 body: _body,
488 queryParams: _queryParams, 489 queryParams: _queryParams,
489 uploadOptions: _uploadOptions, 490 uploadOptions: _uploadOptions,
490 uploadMedia: _uploadMedia, 491 uploadMedia: _uploadMedia,
491 downloadOptions: _downloadOptions); 492 downloadOptions: _downloadOptions);
492 return _response.then((data) => new Task.fromJson(data)); 493 return _response.then((data) => new Task.fromJson(data));
493 } 494 }
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
526 * 527 *
527 * [showHidden] - Flag indicating whether hidden tasks are returned in the 528 * [showHidden] - Flag indicating whether hidden tasks are returned in the
528 * result. Optional. The default is False. 529 * result. Optional. The default is False.
529 * 530 *
530 * [updatedMin] - Lower bound for a task's last modification time (as a RFC 531 * [updatedMin] - Lower bound for a task's last modification time (as a RFC
531 * 3339 timestamp) to filter by. Optional. The default is not to filter by 532 * 3339 timestamp) to filter by. Optional. The default is not to filter by
532 * last modification time. 533 * last modification time.
533 * 534 *
534 * Completes with a [Tasks]. 535 * Completes with a [Tasks].
535 * 536 *
536 * Completes with a [common.ApiRequestError] if the API endpoint returned an 537 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
537 * error. 538 * error.
538 * 539 *
539 * If the used [http.Client] completes with an error when making a REST call, 540 * If the used [http.Client] completes with an error when making a REST call,
540 * this method will complete with the same error. 541 * this method will complete with the same error.
541 */ 542 */
542 async.Future<Tasks> list(core.String tasklist, {core.String completedMax, core .String completedMin, core.String dueMax, core.String dueMin, core.String maxRes ults, core.String pageToken, core.bool showCompleted, core.bool showDeleted, cor e.bool showHidden, core.String updatedMin}) { 543 async.Future<Tasks> list(core.String tasklist, {core.String completedMax, core .String completedMin, core.String dueMax, core.String dueMin, core.String maxRes ults, core.String pageToken, core.bool showCompleted, core.bool showDeleted, cor e.bool showHidden, core.String updatedMin}) {
543 var _url = null; 544 var _url = null;
544 var _queryParams = new core.Map(); 545 var _queryParams = new core.Map();
545 var _uploadMedia = null; 546 var _uploadMedia = null;
546 var _uploadOptions = null; 547 var _uploadOptions = null;
547 var _downloadOptions = common.DownloadOptions.Metadata; 548 var _downloadOptions = commons.DownloadOptions.Metadata;
548 var _body = null; 549 var _body = null;
549 550
550 if (tasklist == null) { 551 if (tasklist == null) {
551 throw new core.ArgumentError("Parameter tasklist is required."); 552 throw new core.ArgumentError("Parameter tasklist is required.");
552 } 553 }
553 if (completedMax != null) { 554 if (completedMax != null) {
554 _queryParams["completedMax"] = [completedMax]; 555 _queryParams["completedMax"] = [completedMax];
555 } 556 }
556 if (completedMin != null) { 557 if (completedMin != null) {
557 _queryParams["completedMin"] = [completedMin]; 558 _queryParams["completedMin"] = [completedMin];
(...skipping 17 matching lines...) Expand all
575 _queryParams["showDeleted"] = ["${showDeleted}"]; 576 _queryParams["showDeleted"] = ["${showDeleted}"];
576 } 577 }
577 if (showHidden != null) { 578 if (showHidden != null) {
578 _queryParams["showHidden"] = ["${showHidden}"]; 579 _queryParams["showHidden"] = ["${showHidden}"];
579 } 580 }
580 if (updatedMin != null) { 581 if (updatedMin != null) {
581 _queryParams["updatedMin"] = [updatedMin]; 582 _queryParams["updatedMin"] = [updatedMin];
582 } 583 }
583 584
584 585
585 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/tas ks'; 586 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/tasks';
586 587
587 var _response = _requester.request(_url, 588 var _response = _requester.request(_url,
588 "GET", 589 "GET",
589 body: _body, 590 body: _body,
590 queryParams: _queryParams, 591 queryParams: _queryParams,
591 uploadOptions: _uploadOptions, 592 uploadOptions: _uploadOptions,
592 uploadMedia: _uploadMedia, 593 uploadMedia: _uploadMedia,
593 downloadOptions: _downloadOptions); 594 downloadOptions: _downloadOptions);
594 return _response.then((data) => new Tasks.fromJson(data)); 595 return _response.then((data) => new Tasks.fromJson(data));
595 } 596 }
(...skipping 10 matching lines...) Expand all
606 * [task] - Task identifier. 607 * [task] - Task identifier.
607 * 608 *
608 * [parent] - New parent task identifier. If the task is moved to the top 609 * [parent] - New parent task identifier. If the task is moved to the top
609 * level, this parameter is omitted. Optional. 610 * level, this parameter is omitted. Optional.
610 * 611 *
611 * [previous] - New previous sibling task identifier. If the task is moved to 612 * [previous] - New previous sibling task identifier. If the task is moved to
612 * the first position among its siblings, this parameter is omitted. Optional. 613 * the first position among its siblings, this parameter is omitted. Optional.
613 * 614 *
614 * Completes with a [Task]. 615 * Completes with a [Task].
615 * 616 *
616 * Completes with a [common.ApiRequestError] if the API endpoint returned an 617 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
617 * error. 618 * error.
618 * 619 *
619 * If the used [http.Client] completes with an error when making a REST call, 620 * If the used [http.Client] completes with an error when making a REST call,
620 * this method will complete with the same error. 621 * this method will complete with the same error.
621 */ 622 */
622 async.Future<Task> move(core.String tasklist, core.String task, {core.String p arent, core.String previous}) { 623 async.Future<Task> move(core.String tasklist, core.String task, {core.String p arent, core.String previous}) {
623 var _url = null; 624 var _url = null;
624 var _queryParams = new core.Map(); 625 var _queryParams = new core.Map();
625 var _uploadMedia = null; 626 var _uploadMedia = null;
626 var _uploadOptions = null; 627 var _uploadOptions = null;
627 var _downloadOptions = common.DownloadOptions.Metadata; 628 var _downloadOptions = commons.DownloadOptions.Metadata;
628 var _body = null; 629 var _body = null;
629 630
630 if (tasklist == null) { 631 if (tasklist == null) {
631 throw new core.ArgumentError("Parameter tasklist is required."); 632 throw new core.ArgumentError("Parameter tasklist is required.");
632 } 633 }
633 if (task == null) { 634 if (task == null) {
634 throw new core.ArgumentError("Parameter task is required."); 635 throw new core.ArgumentError("Parameter task is required.");
635 } 636 }
636 if (parent != null) { 637 if (parent != null) {
637 _queryParams["parent"] = [parent]; 638 _queryParams["parent"] = [parent];
638 } 639 }
639 if (previous != null) { 640 if (previous != null) {
640 _queryParams["previous"] = [previous]; 641 _queryParams["previous"] = [previous];
641 } 642 }
642 643
643 644
644 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/tas ks/' + common_internal.Escaper.ecapeVariable('$task') + '/move'; 645 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/tasks/' + c ommons.Escaper.ecapeVariable('$task') + '/move';
645 646
646 var _response = _requester.request(_url, 647 var _response = _requester.request(_url,
647 "POST", 648 "POST",
648 body: _body, 649 body: _body,
649 queryParams: _queryParams, 650 queryParams: _queryParams,
650 uploadOptions: _uploadOptions, 651 uploadOptions: _uploadOptions,
651 uploadMedia: _uploadMedia, 652 uploadMedia: _uploadMedia,
652 downloadOptions: _downloadOptions); 653 downloadOptions: _downloadOptions);
653 return _response.then((data) => new Task.fromJson(data)); 654 return _response.then((data) => new Task.fromJson(data));
654 } 655 }
655 656
656 /** 657 /**
657 * Updates the specified task. This method supports patch semantics. 658 * Updates the specified task. This method supports patch semantics.
658 * 659 *
659 * [request] - The metadata request object. 660 * [request] - The metadata request object.
660 * 661 *
661 * Request parameters: 662 * Request parameters:
662 * 663 *
663 * [tasklist] - Task list identifier. 664 * [tasklist] - Task list identifier.
664 * 665 *
665 * [task] - Task identifier. 666 * [task] - Task identifier.
666 * 667 *
667 * Completes with a [Task]. 668 * Completes with a [Task].
668 * 669 *
669 * Completes with a [common.ApiRequestError] if the API endpoint returned an 670 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
670 * error. 671 * error.
671 * 672 *
672 * If the used [http.Client] completes with an error when making a REST call, 673 * If the used [http.Client] completes with an error when making a REST call,
673 * this method will complete with the same error. 674 * this method will complete with the same error.
674 */ 675 */
675 async.Future<Task> patch(Task request, core.String tasklist, core.String task) { 676 async.Future<Task> patch(Task request, core.String tasklist, core.String task) {
676 var _url = null; 677 var _url = null;
677 var _queryParams = new core.Map(); 678 var _queryParams = new core.Map();
678 var _uploadMedia = null; 679 var _uploadMedia = null;
679 var _uploadOptions = null; 680 var _uploadOptions = null;
680 var _downloadOptions = common.DownloadOptions.Metadata; 681 var _downloadOptions = commons.DownloadOptions.Metadata;
681 var _body = null; 682 var _body = null;
682 683
683 if (request != null) { 684 if (request != null) {
684 _body = convert.JSON.encode((request).toJson()); 685 _body = convert.JSON.encode((request).toJson());
685 } 686 }
686 if (tasklist == null) { 687 if (tasklist == null) {
687 throw new core.ArgumentError("Parameter tasklist is required."); 688 throw new core.ArgumentError("Parameter tasklist is required.");
688 } 689 }
689 if (task == null) { 690 if (task == null) {
690 throw new core.ArgumentError("Parameter task is required."); 691 throw new core.ArgumentError("Parameter task is required.");
691 } 692 }
692 693
693 694
694 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/tas ks/' + common_internal.Escaper.ecapeVariable('$task'); 695 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/tasks/' + c ommons.Escaper.ecapeVariable('$task');
695 696
696 var _response = _requester.request(_url, 697 var _response = _requester.request(_url,
697 "PATCH", 698 "PATCH",
698 body: _body, 699 body: _body,
699 queryParams: _queryParams, 700 queryParams: _queryParams,
700 uploadOptions: _uploadOptions, 701 uploadOptions: _uploadOptions,
701 uploadMedia: _uploadMedia, 702 uploadMedia: _uploadMedia,
702 downloadOptions: _downloadOptions); 703 downloadOptions: _downloadOptions);
703 return _response.then((data) => new Task.fromJson(data)); 704 return _response.then((data) => new Task.fromJson(data));
704 } 705 }
705 706
706 /** 707 /**
707 * Updates the specified task. 708 * Updates the specified task.
708 * 709 *
709 * [request] - The metadata request object. 710 * [request] - The metadata request object.
710 * 711 *
711 * Request parameters: 712 * Request parameters:
712 * 713 *
713 * [tasklist] - Task list identifier. 714 * [tasklist] - Task list identifier.
714 * 715 *
715 * [task] - Task identifier. 716 * [task] - Task identifier.
716 * 717 *
717 * Completes with a [Task]. 718 * Completes with a [Task].
718 * 719 *
719 * Completes with a [common.ApiRequestError] if the API endpoint returned an 720 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
720 * error. 721 * error.
721 * 722 *
722 * If the used [http.Client] completes with an error when making a REST call, 723 * If the used [http.Client] completes with an error when making a REST call,
723 * this method will complete with the same error. 724 * this method will complete with the same error.
724 */ 725 */
725 async.Future<Task> update(Task request, core.String tasklist, core.String task ) { 726 async.Future<Task> update(Task request, core.String tasklist, core.String task ) {
726 var _url = null; 727 var _url = null;
727 var _queryParams = new core.Map(); 728 var _queryParams = new core.Map();
728 var _uploadMedia = null; 729 var _uploadMedia = null;
729 var _uploadOptions = null; 730 var _uploadOptions = null;
730 var _downloadOptions = common.DownloadOptions.Metadata; 731 var _downloadOptions = commons.DownloadOptions.Metadata;
731 var _body = null; 732 var _body = null;
732 733
733 if (request != null) { 734 if (request != null) {
734 _body = convert.JSON.encode((request).toJson()); 735 _body = convert.JSON.encode((request).toJson());
735 } 736 }
736 if (tasklist == null) { 737 if (tasklist == null) {
737 throw new core.ArgumentError("Parameter tasklist is required."); 738 throw new core.ArgumentError("Parameter tasklist is required.");
738 } 739 }
739 if (task == null) { 740 if (task == null) {
740 throw new core.ArgumentError("Parameter task is required."); 741 throw new core.ArgumentError("Parameter task is required.");
741 } 742 }
742 743
743 744
744 _url = 'lists/' + common_internal.Escaper.ecapeVariable('$tasklist') + '/tas ks/' + common_internal.Escaper.ecapeVariable('$task'); 745 _url = 'lists/' + commons.Escaper.ecapeVariable('$tasklist') + '/tasks/' + c ommons.Escaper.ecapeVariable('$task');
745 746
746 var _response = _requester.request(_url, 747 var _response = _requester.request(_url,
747 "PUT", 748 "PUT",
748 body: _body, 749 body: _body,
749 queryParams: _queryParams, 750 queryParams: _queryParams,
750 uploadOptions: _uploadOptions, 751 uploadOptions: _uploadOptions,
751 uploadMedia: _uploadMedia, 752 uploadMedia: _uploadMedia,
752 downloadOptions: _downloadOptions); 753 downloadOptions: _downloadOptions);
753 return _response.then((data) => new Task.fromJson(data)); 754 return _response.then((data) => new Task.fromJson(data));
754 } 755 }
755 756
756 } 757 }
757 758
758 759
759 760
760 /** Not documented yet. */
761 class TaskLinks { 761 class TaskLinks {
762 /** The description. In HTML speak: Everything between <a> and </a>. */ 762 /** The description. In HTML speak: Everything between <a> and </a>. */
763 core.String description; 763 core.String description;
764 764
765 /** The URL. */ 765 /** The URL. */
766 core.String link; 766 core.String link;
767 767
768 /** Type of the link, e.g. "email". */ 768 /** Type of the link, e.g. "email". */
769 core.String type; 769 core.String type;
770 770
(...skipping 21 matching lines...) Expand all
792 _json["link"] = link; 792 _json["link"] = link;
793 } 793 }
794 if (type != null) { 794 if (type != null) {
795 _json["type"] = type; 795 _json["type"] = type;
796 } 796 }
797 return _json; 797 return _json;
798 } 798 }
799 } 799 }
800 800
801 801
802 /** Not documented yet. */
803 class Task { 802 class Task {
804 /** 803 /**
805 * Completion date of the task (as a RFC 3339 timestamp). This field is 804 * Completion date of the task (as a RFC 3339 timestamp). This field is
806 * omitted if the task has not been completed. 805 * omitted if the task has not been completed.
807 */ 806 */
808 core.DateTime completed; 807 core.DateTime completed;
809 808
810 /** 809 /**
811 * Flag indicating whether the task has been deleted. The default if False. 810 * Flag indicating whether the task has been deleted. The default if False.
812 */ 811 */
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
964 _json["title"] = title; 963 _json["title"] = title;
965 } 964 }
966 if (updated != null) { 965 if (updated != null) {
967 _json["updated"] = (updated).toIso8601String(); 966 _json["updated"] = (updated).toIso8601String();
968 } 967 }
969 return _json; 968 return _json;
970 } 969 }
971 } 970 }
972 971
973 972
974 /** Not documented yet. */
975 class TaskList { 973 class TaskList {
976 /** ETag of the resource. */ 974 /** ETag of the resource. */
977 core.String etag; 975 core.String etag;
978 976
979 /** Task list identifier. */ 977 /** Task list identifier. */
980 core.String id; 978 core.String id;
981 979
982 /** Type of the resource. This is always "tasks#taskList". */ 980 /** Type of the resource. This is always "tasks#taskList". */
983 core.String kind; 981 core.String kind;
984 982
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
1036 _json["title"] = title; 1034 _json["title"] = title;
1037 } 1035 }
1038 if (updated != null) { 1036 if (updated != null) {
1039 _json["updated"] = (updated).toIso8601String(); 1037 _json["updated"] = (updated).toIso8601String();
1040 } 1038 }
1041 return _json; 1039 return _json;
1042 } 1040 }
1043 } 1041 }
1044 1042
1045 1043
1046 /** Not documented yet. */
1047 class TaskLists { 1044 class TaskLists {
1048 /** ETag of the resource. */ 1045 /** ETag of the resource. */
1049 core.String etag; 1046 core.String etag;
1050 1047
1051 /** Collection of task lists. */ 1048 /** Collection of task lists. */
1052 core.List<TaskList> items; 1049 core.List<TaskList> items;
1053 1050
1054 /** Type of the resource. This is always "tasks#taskLists". */ 1051 /** Type of the resource. This is always "tasks#taskLists". */
1055 core.String kind; 1052 core.String kind;
1056 1053
(...skipping 30 matching lines...) Expand all
1087 _json["kind"] = kind; 1084 _json["kind"] = kind;
1088 } 1085 }
1089 if (nextPageToken != null) { 1086 if (nextPageToken != null) {
1090 _json["nextPageToken"] = nextPageToken; 1087 _json["nextPageToken"] = nextPageToken;
1091 } 1088 }
1092 return _json; 1089 return _json;
1093 } 1090 }
1094 } 1091 }
1095 1092
1096 1093
1097 /** Not documented yet. */
1098 class Tasks { 1094 class Tasks {
1099 /** ETag of the resource. */ 1095 /** ETag of the resource. */
1100 core.String etag; 1096 core.String etag;
1101 1097
1102 /** Collection of tasks. */ 1098 /** Collection of tasks. */
1103 core.List<Task> items; 1099 core.List<Task> items;
1104 1100
1105 /** Type of the resource. This is always "tasks#tasks". */ 1101 /** Type of the resource. This is always "tasks#tasks". */
1106 core.String kind; 1102 core.String kind;
1107 1103
(...skipping 28 matching lines...) Expand all
1136 } 1132 }
1137 if (kind != null) { 1133 if (kind != null) {
1138 _json["kind"] = kind; 1134 _json["kind"] = kind;
1139 } 1135 }
1140 if (nextPageToken != null) { 1136 if (nextPageToken != null) {
1141 _json["nextPageToken"] = nextPageToken; 1137 _json["nextPageToken"] = nextPageToken;
1142 } 1138 }
1143 return _json; 1139 return _json;
1144 } 1140 }
1145 } 1141 }
1146
1147
OLDNEW
« no previous file with comments | « generated/googleapis/lib/tagmanager/v1.dart ('k') | generated/googleapis/lib/translate/v2.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698