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

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

Issue 2695743002: Api-roll 45: 2017-02-13 (Closed)
Patch Set: reverted local changes to pubspec file Created 3 years, 10 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
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.kgsearch.v1; 3 library googleapis.kgsearch.v1;
4 4
5 import 'dart:core' as core; 5 import 'dart:core' as core;
6 import 'dart:async' as async; 6 import 'dart:async' as async;
7 import 'dart:convert' as convert; 7 import 'dart:convert' as convert;
8 8
9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons;
10 import 'package:http/http.dart' as http; 10 import 'package:http/http.dart' as http;
(...skipping 21 matching lines...) Expand all
32 EntitiesResourceApi(commons.ApiRequester client) : 32 EntitiesResourceApi(commons.ApiRequester client) :
33 _requester = client; 33 _requester = client;
34 34
35 /** 35 /**
36 * Searches Knowledge Graph for entities that match the constraints. 36 * Searches Knowledge Graph for entities that match the constraints.
37 * A list of matched entities will be returned in response, which will be in 37 * A list of matched entities will be returned in response, which will be in
38 * JSON-LD format and compatible with http://schema.org 38 * JSON-LD format and compatible with http://schema.org
39 * 39 *
40 * Request parameters: 40 * Request parameters:
41 * 41 *
42 * [limit] - Limits the number of entities to be returned.
43 *
44 * [ids] - The list of entity id to be used for search instead of query 42 * [ids] - The list of entity id to be used for search instead of query
45 * string. 43 * string.
46 * To specify multiple ids in the HTTP request, repeat the parameter in the 44 * To specify multiple ids in the HTTP request, repeat the parameter in the
47 * URL as in ...?ids=A&ids=B 45 * URL as in ...?ids=A&ids=B
48 * 46 *
47 * [limit] - Limits the number of entities to be returned.
48 *
49 * [prefix] - Enables prefix match against names and aliases of entities 49 * [prefix] - Enables prefix match against names and aliases of entities
50 * 50 *
51 * [query] - The literal query string for search. 51 * [query] - The literal query string for search.
52 * 52 *
53 * [indent] - Enables indenting of json results.
54 *
55 * [types] - Restricts returned entities with these types, e.g. Person 53 * [types] - Restricts returned entities with these types, e.g. Person
56 * (as defined in http://schema.org/Person). If multiple types are specified, 54 * (as defined in http://schema.org/Person). If multiple types are specified,
57 * returned entities will contain one or more of these types. 55 * returned entities will contain one or more of these types.
58 * 56 *
57 * [indent] - Enables indenting of json results.
58 *
59 * [languages] - The list of language codes (defined in ISO 693) to run the 59 * [languages] - The list of language codes (defined in ISO 693) to run the
60 * query with, 60 * query with,
61 * e.g. 'en'. 61 * e.g. 'en'.
62 * 62 *
63 * Completes with a [SearchResponse]. 63 * Completes with a [SearchResponse].
64 * 64 *
65 * Completes with a [commons.ApiRequestError] if the API endpoint returned an 65 * Completes with a [commons.ApiRequestError] if the API endpoint returned an
66 * error. 66 * error.
67 * 67 *
68 * If the used [http.Client] completes with an error when making a REST call, 68 * If the used [http.Client] completes with an error when making a REST call,
69 * this method will complete with the same error. 69 * this method will complete with the same error.
70 */ 70 */
71 async.Future<SearchResponse> search({core.int limit, core.List<core.String> id s, core.bool prefix, core.String query, core.bool indent, core.List<core.String> types, core.List<core.String> languages}) { 71 async.Future<SearchResponse> search({core.List<core.String> ids, core.int limi t, core.bool prefix, core.String query, core.List<core.String> types, core.bool indent, core.List<core.String> languages}) {
72 var _url = null; 72 var _url = null;
73 var _queryParams = new core.Map(); 73 var _queryParams = new core.Map();
74 var _uploadMedia = null; 74 var _uploadMedia = null;
75 var _uploadOptions = null; 75 var _uploadOptions = null;
76 var _downloadOptions = commons.DownloadOptions.Metadata; 76 var _downloadOptions = commons.DownloadOptions.Metadata;
77 var _body = null; 77 var _body = null;
78 78
79 if (ids != null) {
80 _queryParams["ids"] = ids;
81 }
79 if (limit != null) { 82 if (limit != null) {
80 _queryParams["limit"] = ["${limit}"]; 83 _queryParams["limit"] = ["${limit}"];
81 } 84 }
82 if (ids != null) {
83 _queryParams["ids"] = ids;
84 }
85 if (prefix != null) { 85 if (prefix != null) {
86 _queryParams["prefix"] = ["${prefix}"]; 86 _queryParams["prefix"] = ["${prefix}"];
87 } 87 }
88 if (query != null) { 88 if (query != null) {
89 _queryParams["query"] = [query]; 89 _queryParams["query"] = [query];
90 } 90 }
91 if (types != null) {
92 _queryParams["types"] = types;
93 }
91 if (indent != null) { 94 if (indent != null) {
92 _queryParams["indent"] = ["${indent}"]; 95 _queryParams["indent"] = ["${indent}"];
93 } 96 }
94 if (types != null) {
95 _queryParams["types"] = types;
96 }
97 if (languages != null) { 97 if (languages != null) {
98 _queryParams["languages"] = languages; 98 _queryParams["languages"] = languages;
99 } 99 }
100 100
101 _url = 'v1/entities:search'; 101 _url = 'v1/entities:search';
102 102
103 var _response = _requester.request(_url, 103 var _response = _requester.request(_url,
104 "GET", 104 "GET",
105 body: _body, 105 body: _body,
106 queryParams: _queryParams, 106 queryParams: _queryParams,
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 } 163 }
164 if (P_type != null) { 164 if (P_type != null) {
165 _json["@type"] = P_type; 165 _json["@type"] = P_type;
166 } 166 }
167 if (itemListElement != null) { 167 if (itemListElement != null) {
168 _json["itemListElement"] = itemListElement; 168 _json["itemListElement"] = itemListElement;
169 } 169 }
170 return _json; 170 return _json;
171 } 171 }
172 } 172 }
OLDNEW
« no previous file with comments | « generated/googleapis/lib/identitytoolkit/v3.dart ('k') | generated/googleapis/lib/logging/v2.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698