| OLD | NEW |
| 1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 | 2 |
| 3 library googleapis.androidmanagement.v1; | 3 library googleapis.androidmanagement.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; | 13 show ApiRequestError, DetailedApiRequestError; |
| 14 | 14 |
| 15 const core.String USER_AGENT = 'dart-api-client androidmanagement/v1'; | 15 const core.String USER_AGENT = 'dart-api-client androidmanagement/v1'; |
| 16 | 16 |
| 17 /** | 17 /// The Android Management API provides remote enterprise management of Android |
| 18 * The Android Management API provides remote enterprise management of Android | 18 /// devices and apps. |
| 19 * devices and apps. | |
| 20 */ | |
| 21 class AndroidmanagementApi { | 19 class AndroidmanagementApi { |
| 22 /** Manage Android devices and apps for your customers */ | 20 /// Manage Android devices and apps for your customers |
| 23 static const AndroidmanagementScope = "https://www.googleapis.com/auth/android
management"; | 21 static const AndroidmanagementScope = |
| 24 | 22 "https://www.googleapis.com/auth/androidmanagement"; |
| 25 | 23 |
| 26 final commons.ApiRequester _requester; | 24 final commons.ApiRequester _requester; |
| 27 | 25 |
| 28 EnterprisesResourceApi get enterprises => new EnterprisesResourceApi(_requeste
r); | 26 EnterprisesResourceApi get enterprises => |
| 27 new EnterprisesResourceApi(_requester); |
| 29 SignupUrlsResourceApi get signupUrls => new SignupUrlsResourceApi(_requester); | 28 SignupUrlsResourceApi get signupUrls => new SignupUrlsResourceApi(_requester); |
| 30 | 29 |
| 31 AndroidmanagementApi(http.Client client, {core.String rootUrl: "https://androi
dmanagement.googleapis.com/", core.String servicePath: ""}) : | 30 AndroidmanagementApi(http.Client client, |
| 32 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); | 31 {core.String rootUrl: "https://androidmanagement.googleapis.com/", |
| 32 core.String servicePath: ""}) |
| 33 : _requester = |
| 34 new commons.ApiRequester(client, rootUrl, servicePath, USER_AGENT); |
| 33 } | 35 } |
| 34 | 36 |
| 35 | |
| 36 class EnterprisesResourceApi { | 37 class EnterprisesResourceApi { |
| 37 final commons.ApiRequester _requester; | 38 final commons.ApiRequester _requester; |
| 38 | 39 |
| 39 EnterprisesApplicationsResourceApi get applications => new EnterprisesApplicat
ionsResourceApi(_requester); | 40 EnterprisesApplicationsResourceApi get applications => |
| 40 EnterprisesDevicesResourceApi get devices => new EnterprisesDevicesResourceApi
(_requester); | 41 new EnterprisesApplicationsResourceApi(_requester); |
| 41 EnterprisesEnrollmentTokensResourceApi get enrollmentTokens => new Enterprises
EnrollmentTokensResourceApi(_requester); | 42 EnterprisesDevicesResourceApi get devices => |
| 42 EnterprisesPoliciesResourceApi get policies => new EnterprisesPoliciesResource
Api(_requester); | 43 new EnterprisesDevicesResourceApi(_requester); |
| 43 EnterprisesWebTokensResourceApi get webTokens => new EnterprisesWebTokensResou
rceApi(_requester); | 44 EnterprisesEnrollmentTokensResourceApi get enrollmentTokens => |
| 45 new EnterprisesEnrollmentTokensResourceApi(_requester); |
| 46 EnterprisesPoliciesResourceApi get policies => |
| 47 new EnterprisesPoliciesResourceApi(_requester); |
| 48 EnterprisesWebTokensResourceApi get webTokens => |
| 49 new EnterprisesWebTokensResourceApi(_requester); |
| 44 | 50 |
| 45 EnterprisesResourceApi(commons.ApiRequester client) : | 51 EnterprisesResourceApi(commons.ApiRequester client) : _requester = client; |
| 46 _requester = client; | |
| 47 | 52 |
| 48 /** | 53 /// Creates an enterprise by completing the enterprise signup flow. |
| 49 * Creates an enterprise by completing the enterprise signup flow. | 54 /// |
| 50 * | 55 /// [request] - The metadata request object. |
| 51 * [request] - The metadata request object. | 56 /// |
| 52 * | 57 /// Request parameters: |
| 53 * Request parameters: | 58 /// |
| 54 * | 59 /// [signupUrlName] - The name of the SignupUrl used to sign up for the |
| 55 * [signupUrlName] - The name of the SignupUrl used to sign up for the | 60 /// enterprise. |
| 56 * enterprise. | 61 /// |
| 57 * | 62 /// [enterpriseToken] - The enterprise token appended to the callback URL. |
| 58 * [enterpriseToken] - The enterprise token appended to the callback URL. | 63 /// |
| 59 * | 64 /// [projectId] - The id of the Google Cloud Platform project which will own |
| 60 * [projectId] - The id of the Google Cloud Platform project which will own | 65 /// the enterprise. |
| 61 * the enterprise. | 66 /// |
| 62 * | 67 /// Completes with a [Enterprise]. |
| 63 * Completes with a [Enterprise]. | 68 /// |
| 64 * | 69 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 65 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 70 /// an error. |
| 66 * error. | 71 /// |
| 67 * | 72 /// If the used [http.Client] completes with an error when making a REST |
| 68 * If the used [http.Client] completes with an error when making a REST call, | 73 /// call, this method will complete with the same error. |
| 69 * this method will complete with the same error. | 74 async.Future<Enterprise> create(Enterprise request, |
| 70 */ | 75 {core.String signupUrlName, |
| 71 async.Future<Enterprise> create(Enterprise request, {core.String signupUrlName
, core.String enterpriseToken, core.String projectId}) { | 76 core.String enterpriseToken, |
| 77 core.String projectId}) { |
| 72 var _url = null; | 78 var _url = null; |
| 73 var _queryParams = new core.Map(); | 79 var _queryParams = new core.Map(); |
| 74 var _uploadMedia = null; | 80 var _uploadMedia = null; |
| 75 var _uploadOptions = null; | 81 var _uploadOptions = null; |
| 76 var _downloadOptions = commons.DownloadOptions.Metadata; | 82 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 77 var _body = null; | 83 var _body = null; |
| 78 | 84 |
| 79 if (request != null) { | 85 if (request != null) { |
| 80 _body = convert.JSON.encode((request).toJson()); | 86 _body = convert.JSON.encode((request).toJson()); |
| 81 } | 87 } |
| 82 if (signupUrlName != null) { | 88 if (signupUrlName != null) { |
| 83 _queryParams["signupUrlName"] = [signupUrlName]; | 89 _queryParams["signupUrlName"] = [signupUrlName]; |
| 84 } | 90 } |
| 85 if (enterpriseToken != null) { | 91 if (enterpriseToken != null) { |
| 86 _queryParams["enterpriseToken"] = [enterpriseToken]; | 92 _queryParams["enterpriseToken"] = [enterpriseToken]; |
| 87 } | 93 } |
| 88 if (projectId != null) { | 94 if (projectId != null) { |
| 89 _queryParams["projectId"] = [projectId]; | 95 _queryParams["projectId"] = [projectId]; |
| 90 } | 96 } |
| 91 | 97 |
| 92 _url = 'v1/enterprises'; | 98 _url = 'v1/enterprises'; |
| 93 | 99 |
| 94 var _response = _requester.request(_url, | 100 var _response = _requester.request(_url, "POST", |
| 95 "POST", | 101 body: _body, |
| 96 body: _body, | 102 queryParams: _queryParams, |
| 97 queryParams: _queryParams, | 103 uploadOptions: _uploadOptions, |
| 98 uploadOptions: _uploadOptions, | 104 uploadMedia: _uploadMedia, |
| 99 uploadMedia: _uploadMedia, | 105 downloadOptions: _downloadOptions); |
| 100 downloadOptions: _downloadOptions); | |
| 101 return _response.then((data) => new Enterprise.fromJson(data)); | 106 return _response.then((data) => new Enterprise.fromJson(data)); |
| 102 } | 107 } |
| 103 | 108 |
| 104 /** | 109 /// Gets an enterprise. |
| 105 * Gets an enterprise. | 110 /// |
| 106 * | 111 /// Request parameters: |
| 107 * Request parameters: | 112 /// |
| 108 * | 113 /// [name] - The name of the enterprise in the form |
| 109 * [name] - The name of the enterprise in the form enterprises/{enterpriseId} | 114 /// enterprises/{enterpriseId} |
| 110 * Value must have pattern "^enterprises/[^/]+$". | 115 /// Value must have pattern "^enterprises/[^/]+$". |
| 111 * | 116 /// |
| 112 * Completes with a [Enterprise]. | 117 /// Completes with a [Enterprise]. |
| 113 * | 118 /// |
| 114 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 119 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 115 * error. | 120 /// an error. |
| 116 * | 121 /// |
| 117 * If the used [http.Client] completes with an error when making a REST call, | 122 /// If the used [http.Client] completes with an error when making a REST |
| 118 * this method will complete with the same error. | 123 /// call, this method will complete with the same error. |
| 119 */ | |
| 120 async.Future<Enterprise> get(core.String name) { | 124 async.Future<Enterprise> get(core.String name) { |
| 121 var _url = null; | 125 var _url = null; |
| 122 var _queryParams = new core.Map(); | 126 var _queryParams = new core.Map(); |
| 123 var _uploadMedia = null; | 127 var _uploadMedia = null; |
| 124 var _uploadOptions = null; | 128 var _uploadOptions = null; |
| 125 var _downloadOptions = commons.DownloadOptions.Metadata; | 129 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 126 var _body = null; | 130 var _body = null; |
| 127 | 131 |
| 128 if (name == null) { | 132 if (name == null) { |
| 129 throw new core.ArgumentError("Parameter name is required."); | 133 throw new core.ArgumentError("Parameter name is required."); |
| 130 } | 134 } |
| 131 | 135 |
| 132 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 136 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 133 | 137 |
| 134 var _response = _requester.request(_url, | 138 var _response = _requester.request(_url, "GET", |
| 135 "GET", | 139 body: _body, |
| 136 body: _body, | 140 queryParams: _queryParams, |
| 137 queryParams: _queryParams, | 141 uploadOptions: _uploadOptions, |
| 138 uploadOptions: _uploadOptions, | 142 uploadMedia: _uploadMedia, |
| 139 uploadMedia: _uploadMedia, | 143 downloadOptions: _downloadOptions); |
| 140 downloadOptions: _downloadOptions); | |
| 141 return _response.then((data) => new Enterprise.fromJson(data)); | 144 return _response.then((data) => new Enterprise.fromJson(data)); |
| 142 } | 145 } |
| 143 | 146 |
| 144 /** | 147 /// Updates an enterprise. |
| 145 * Updates an enterprise. | 148 /// |
| 146 * | 149 /// [request] - The metadata request object. |
| 147 * [request] - The metadata request object. | 150 /// |
| 148 * | 151 /// Request parameters: |
| 149 * Request parameters: | 152 /// |
| 150 * | 153 /// [name] - The name of the enterprise in the form |
| 151 * [name] - The name of the enterprise in the form enterprises/{enterpriseId} | 154 /// enterprises/{enterpriseId} |
| 152 * Value must have pattern "^enterprises/[^/]+$". | 155 /// Value must have pattern "^enterprises/[^/]+$". |
| 153 * | 156 /// |
| 154 * [updateMask] - The field mask indicating the fields to update. If not set, | 157 /// [updateMask] - The field mask indicating the fields to update. If not |
| 155 * all modifiable fields will be modified. | 158 /// set, all modifiable fields will be modified. |
| 156 * | 159 /// |
| 157 * Completes with a [Enterprise]. | 160 /// Completes with a [Enterprise]. |
| 158 * | 161 /// |
| 159 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 162 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 160 * error. | 163 /// an error. |
| 161 * | 164 /// |
| 162 * If the used [http.Client] completes with an error when making a REST call, | 165 /// If the used [http.Client] completes with an error when making a REST |
| 163 * this method will complete with the same error. | 166 /// call, this method will complete with the same error. |
| 164 */ | 167 async.Future<Enterprise> patch(Enterprise request, core.String name, |
| 165 async.Future<Enterprise> patch(Enterprise request, core.String name, {core.Str
ing updateMask}) { | 168 {core.String updateMask}) { |
| 166 var _url = null; | 169 var _url = null; |
| 167 var _queryParams = new core.Map(); | 170 var _queryParams = new core.Map(); |
| 168 var _uploadMedia = null; | 171 var _uploadMedia = null; |
| 169 var _uploadOptions = null; | 172 var _uploadOptions = null; |
| 170 var _downloadOptions = commons.DownloadOptions.Metadata; | 173 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 171 var _body = null; | 174 var _body = null; |
| 172 | 175 |
| 173 if (request != null) { | 176 if (request != null) { |
| 174 _body = convert.JSON.encode((request).toJson()); | 177 _body = convert.JSON.encode((request).toJson()); |
| 175 } | 178 } |
| 176 if (name == null) { | 179 if (name == null) { |
| 177 throw new core.ArgumentError("Parameter name is required."); | 180 throw new core.ArgumentError("Parameter name is required."); |
| 178 } | 181 } |
| 179 if (updateMask != null) { | 182 if (updateMask != null) { |
| 180 _queryParams["updateMask"] = [updateMask]; | 183 _queryParams["updateMask"] = [updateMask]; |
| 181 } | 184 } |
| 182 | 185 |
| 183 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 186 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 184 | 187 |
| 185 var _response = _requester.request(_url, | 188 var _response = _requester.request(_url, "PATCH", |
| 186 "PATCH", | 189 body: _body, |
| 187 body: _body, | 190 queryParams: _queryParams, |
| 188 queryParams: _queryParams, | 191 uploadOptions: _uploadOptions, |
| 189 uploadOptions: _uploadOptions, | 192 uploadMedia: _uploadMedia, |
| 190 uploadMedia: _uploadMedia, | 193 downloadOptions: _downloadOptions); |
| 191 downloadOptions: _downloadOptions); | |
| 192 return _response.then((data) => new Enterprise.fromJson(data)); | 194 return _response.then((data) => new Enterprise.fromJson(data)); |
| 193 } | 195 } |
| 194 | |
| 195 } | 196 } |
| 196 | 197 |
| 197 | |
| 198 class EnterprisesApplicationsResourceApi { | 198 class EnterprisesApplicationsResourceApi { |
| 199 final commons.ApiRequester _requester; | 199 final commons.ApiRequester _requester; |
| 200 | 200 |
| 201 EnterprisesApplicationsResourceApi(commons.ApiRequester client) : | 201 EnterprisesApplicationsResourceApi(commons.ApiRequester client) |
| 202 _requester = client; | 202 : _requester = client; |
| 203 | 203 |
| 204 /** | 204 /// Gets info about an application. |
| 205 * Gets info about an application. | 205 /// |
| 206 * | 206 /// Request parameters: |
| 207 * Request parameters: | 207 /// |
| 208 * | 208 /// [name] - The name of the application in the form |
| 209 * [name] - The name of the application in the form | 209 /// enterprises/{enterpriseId}/applications/{package_name} |
| 210 * enterprises/{enterpriseId}/applications/{package_name} | 210 /// Value must have pattern "^enterprises/[^/]+/applications/[^/]+$". |
| 211 * Value must have pattern "^enterprises/[^/]+/applications/[^/]+$". | 211 /// |
| 212 * | 212 /// [languageCode] - The preferred language for localized application info, |
| 213 * [languageCode] - The preferred language for localized application info, as | 213 /// as a BCP47 tag (e.g. "en-US", "de"). If not specified the default |
| 214 * a BCP47 tag (e.g. "en-US", "de"). If not specified the default language of | 214 /// language of the application will be used. |
| 215 * the application will be used. | 215 /// |
| 216 * | 216 /// Completes with a [Application]. |
| 217 * Completes with a [Application]. | 217 /// |
| 218 * | 218 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 219 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 219 /// an error. |
| 220 * error. | 220 /// |
| 221 * | 221 /// If the used [http.Client] completes with an error when making a REST |
| 222 * If the used [http.Client] completes with an error when making a REST call, | 222 /// call, this method will complete with the same error. |
| 223 * this method will complete with the same error. | |
| 224 */ | |
| 225 async.Future<Application> get(core.String name, {core.String languageCode}) { | 223 async.Future<Application> get(core.String name, {core.String languageCode}) { |
| 226 var _url = null; | 224 var _url = null; |
| 227 var _queryParams = new core.Map(); | 225 var _queryParams = new core.Map(); |
| 228 var _uploadMedia = null; | 226 var _uploadMedia = null; |
| 229 var _uploadOptions = null; | 227 var _uploadOptions = null; |
| 230 var _downloadOptions = commons.DownloadOptions.Metadata; | 228 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 231 var _body = null; | 229 var _body = null; |
| 232 | 230 |
| 233 if (name == null) { | 231 if (name == null) { |
| 234 throw new core.ArgumentError("Parameter name is required."); | 232 throw new core.ArgumentError("Parameter name is required."); |
| 235 } | 233 } |
| 236 if (languageCode != null) { | 234 if (languageCode != null) { |
| 237 _queryParams["languageCode"] = [languageCode]; | 235 _queryParams["languageCode"] = [languageCode]; |
| 238 } | 236 } |
| 239 | 237 |
| 240 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 238 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 241 | 239 |
| 242 var _response = _requester.request(_url, | 240 var _response = _requester.request(_url, "GET", |
| 243 "GET", | 241 body: _body, |
| 244 body: _body, | 242 queryParams: _queryParams, |
| 245 queryParams: _queryParams, | 243 uploadOptions: _uploadOptions, |
| 246 uploadOptions: _uploadOptions, | 244 uploadMedia: _uploadMedia, |
| 247 uploadMedia: _uploadMedia, | 245 downloadOptions: _downloadOptions); |
| 248 downloadOptions: _downloadOptions); | |
| 249 return _response.then((data) => new Application.fromJson(data)); | 246 return _response.then((data) => new Application.fromJson(data)); |
| 250 } | 247 } |
| 251 | |
| 252 } | 248 } |
| 253 | 249 |
| 254 | |
| 255 class EnterprisesDevicesResourceApi { | 250 class EnterprisesDevicesResourceApi { |
| 256 final commons.ApiRequester _requester; | 251 final commons.ApiRequester _requester; |
| 257 | 252 |
| 258 EnterprisesDevicesOperationsResourceApi get operations => new EnterprisesDevic
esOperationsResourceApi(_requester); | 253 EnterprisesDevicesOperationsResourceApi get operations => |
| 254 new EnterprisesDevicesOperationsResourceApi(_requester); |
| 259 | 255 |
| 260 EnterprisesDevicesResourceApi(commons.ApiRequester client) : | 256 EnterprisesDevicesResourceApi(commons.ApiRequester client) |
| 261 _requester = client; | 257 : _requester = client; |
| 262 | 258 |
| 263 /** | 259 /// Deletes a device, which causes the device to be wiped. |
| 264 * Deletes a device, which causes the device to be wiped. | 260 /// |
| 265 * | 261 /// Request parameters: |
| 266 * Request parameters: | 262 /// |
| 267 * | 263 /// [name] - The name of the device in the form |
| 268 * [name] - The name of the device in the form | 264 /// enterprises/{enterpriseId}/devices/{deviceId} |
| 269 * enterprises/{enterpriseId}/devices/{deviceId} | 265 /// Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". |
| 270 * Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". | 266 /// |
| 271 * | 267 /// Completes with a [Empty]. |
| 272 * Completes with a [Empty]. | 268 /// |
| 273 * | 269 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 274 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 270 /// an error. |
| 275 * error. | 271 /// |
| 276 * | 272 /// If the used [http.Client] completes with an error when making a REST |
| 277 * If the used [http.Client] completes with an error when making a REST call, | 273 /// call, this method will complete with the same error. |
| 278 * this method will complete with the same error. | |
| 279 */ | |
| 280 async.Future<Empty> delete(core.String name) { | 274 async.Future<Empty> delete(core.String name) { |
| 281 var _url = null; | 275 var _url = null; |
| 282 var _queryParams = new core.Map(); | 276 var _queryParams = new core.Map(); |
| 283 var _uploadMedia = null; | 277 var _uploadMedia = null; |
| 284 var _uploadOptions = null; | 278 var _uploadOptions = null; |
| 285 var _downloadOptions = commons.DownloadOptions.Metadata; | 279 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 286 var _body = null; | 280 var _body = null; |
| 287 | 281 |
| 288 if (name == null) { | 282 if (name == null) { |
| 289 throw new core.ArgumentError("Parameter name is required."); | 283 throw new core.ArgumentError("Parameter name is required."); |
| 290 } | 284 } |
| 291 | 285 |
| 292 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 286 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 293 | 287 |
| 294 var _response = _requester.request(_url, | 288 var _response = _requester.request(_url, "DELETE", |
| 295 "DELETE", | 289 body: _body, |
| 296 body: _body, | 290 queryParams: _queryParams, |
| 297 queryParams: _queryParams, | 291 uploadOptions: _uploadOptions, |
| 298 uploadOptions: _uploadOptions, | 292 uploadMedia: _uploadMedia, |
| 299 uploadMedia: _uploadMedia, | 293 downloadOptions: _downloadOptions); |
| 300 downloadOptions: _downloadOptions); | |
| 301 return _response.then((data) => new Empty.fromJson(data)); | 294 return _response.then((data) => new Empty.fromJson(data)); |
| 302 } | 295 } |
| 303 | 296 |
| 304 /** | 297 /// Gets a device. |
| 305 * Gets a device. | 298 /// |
| 306 * | 299 /// Request parameters: |
| 307 * Request parameters: | 300 /// |
| 308 * | 301 /// [name] - The name of the device in the form |
| 309 * [name] - The name of the device in the form | 302 /// enterprises/{enterpriseId}/devices/{deviceId} |
| 310 * enterprises/{enterpriseId}/devices/{deviceId} | 303 /// Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". |
| 311 * Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". | 304 /// |
| 312 * | 305 /// Completes with a [Device]. |
| 313 * Completes with a [Device]. | 306 /// |
| 314 * | 307 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 315 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 308 /// an error. |
| 316 * error. | 309 /// |
| 317 * | 310 /// If the used [http.Client] completes with an error when making a REST |
| 318 * If the used [http.Client] completes with an error when making a REST call, | 311 /// call, this method will complete with the same error. |
| 319 * this method will complete with the same error. | |
| 320 */ | |
| 321 async.Future<Device> get(core.String name) { | 312 async.Future<Device> get(core.String name) { |
| 322 var _url = null; | 313 var _url = null; |
| 323 var _queryParams = new core.Map(); | 314 var _queryParams = new core.Map(); |
| 324 var _uploadMedia = null; | 315 var _uploadMedia = null; |
| 325 var _uploadOptions = null; | 316 var _uploadOptions = null; |
| 326 var _downloadOptions = commons.DownloadOptions.Metadata; | 317 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 327 var _body = null; | 318 var _body = null; |
| 328 | 319 |
| 329 if (name == null) { | 320 if (name == null) { |
| 330 throw new core.ArgumentError("Parameter name is required."); | 321 throw new core.ArgumentError("Parameter name is required."); |
| 331 } | 322 } |
| 332 | 323 |
| 333 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 324 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 334 | 325 |
| 335 var _response = _requester.request(_url, | 326 var _response = _requester.request(_url, "GET", |
| 336 "GET", | 327 body: _body, |
| 337 body: _body, | 328 queryParams: _queryParams, |
| 338 queryParams: _queryParams, | 329 uploadOptions: _uploadOptions, |
| 339 uploadOptions: _uploadOptions, | 330 uploadMedia: _uploadMedia, |
| 340 uploadMedia: _uploadMedia, | 331 downloadOptions: _downloadOptions); |
| 341 downloadOptions: _downloadOptions); | |
| 342 return _response.then((data) => new Device.fromJson(data)); | 332 return _response.then((data) => new Device.fromJson(data)); |
| 343 } | 333 } |
| 344 | 334 |
| 345 /** | 335 /// Issues a command to a device. The Operation resource returned contains a |
| 346 * Issues a command to a device. The Operation resource returned contains a | 336 /// Command in its metadata field. Use the get operation method to get the |
| 347 * Command in its metadata field. Use the get operation method to get the | 337 /// status of the command. |
| 348 * status of the command. | 338 /// |
| 349 * | 339 /// [request] - The metadata request object. |
| 350 * [request] - The metadata request object. | 340 /// |
| 351 * | 341 /// Request parameters: |
| 352 * Request parameters: | 342 /// |
| 353 * | 343 /// [name] - The name of the device in the form |
| 354 * [name] - The name of the device in the form | 344 /// enterprises/{enterpriseId}/devices/{deviceId} |
| 355 * enterprises/{enterpriseId}/devices/{deviceId} | 345 /// Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". |
| 356 * Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". | 346 /// |
| 357 * | 347 /// Completes with a [Operation]. |
| 358 * Completes with a [Operation]. | 348 /// |
| 359 * | 349 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 360 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 350 /// an error. |
| 361 * error. | 351 /// |
| 362 * | 352 /// If the used [http.Client] completes with an error when making a REST |
| 363 * If the used [http.Client] completes with an error when making a REST call, | 353 /// call, this method will complete with the same error. |
| 364 * this method will complete with the same error. | |
| 365 */ | |
| 366 async.Future<Operation> issueCommand(Command request, core.String name) { | 354 async.Future<Operation> issueCommand(Command request, core.String name) { |
| 367 var _url = null; | 355 var _url = null; |
| 368 var _queryParams = new core.Map(); | 356 var _queryParams = new core.Map(); |
| 369 var _uploadMedia = null; | 357 var _uploadMedia = null; |
| 370 var _uploadOptions = null; | 358 var _uploadOptions = null; |
| 371 var _downloadOptions = commons.DownloadOptions.Metadata; | 359 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 372 var _body = null; | 360 var _body = null; |
| 373 | 361 |
| 374 if (request != null) { | 362 if (request != null) { |
| 375 _body = convert.JSON.encode((request).toJson()); | 363 _body = convert.JSON.encode((request).toJson()); |
| 376 } | 364 } |
| 377 if (name == null) { | 365 if (name == null) { |
| 378 throw new core.ArgumentError("Parameter name is required."); | 366 throw new core.ArgumentError("Parameter name is required."); |
| 379 } | 367 } |
| 380 | 368 |
| 381 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name') + ':issueComma
nd'; | 369 _url = 'v1/' + |
| 370 commons.Escaper.ecapeVariableReserved('$name') + |
| 371 ':issueCommand'; |
| 382 | 372 |
| 383 var _response = _requester.request(_url, | 373 var _response = _requester.request(_url, "POST", |
| 384 "POST", | 374 body: _body, |
| 385 body: _body, | 375 queryParams: _queryParams, |
| 386 queryParams: _queryParams, | 376 uploadOptions: _uploadOptions, |
| 387 uploadOptions: _uploadOptions, | 377 uploadMedia: _uploadMedia, |
| 388 uploadMedia: _uploadMedia, | 378 downloadOptions: _downloadOptions); |
| 389 downloadOptions: _downloadOptions); | |
| 390 return _response.then((data) => new Operation.fromJson(data)); | 379 return _response.then((data) => new Operation.fromJson(data)); |
| 391 } | 380 } |
| 392 | 381 |
| 393 /** | 382 /// Lists devices for a given enterprise. |
| 394 * Lists devices for a given enterprise. | 383 /// |
| 395 * | 384 /// Request parameters: |
| 396 * Request parameters: | 385 /// |
| 397 * | 386 /// [parent] - The name of the enterprise in the form |
| 398 * [parent] - The name of the enterprise in the form | 387 /// enterprises/{enterpriseId} |
| 399 * enterprises/{enterpriseId} | 388 /// Value must have pattern "^enterprises/[^/]+$". |
| 400 * Value must have pattern "^enterprises/[^/]+$". | 389 /// |
| 401 * | 390 /// [pageSize] - The requested page size. The actual page size may be fixed |
| 402 * [pageSize] - The requested page size. The actual page size may be fixed to | 391 /// to a min or max value. |
| 403 * a min or max value. | 392 /// |
| 404 * | 393 /// [pageToken] - A token identifying a page of results the server should |
| 405 * [pageToken] - A token identifying a page of results the server should | 394 /// return. |
| 406 * return. | 395 /// |
| 407 * | 396 /// Completes with a [ListDevicesResponse]. |
| 408 * Completes with a [ListDevicesResponse]. | 397 /// |
| 409 * | 398 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 410 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 399 /// an error. |
| 411 * error. | 400 /// |
| 412 * | 401 /// If the used [http.Client] completes with an error when making a REST |
| 413 * If the used [http.Client] completes with an error when making a REST call, | 402 /// call, this method will complete with the same error. |
| 414 * this method will complete with the same error. | 403 async.Future<ListDevicesResponse> list(core.String parent, |
| 415 */ | 404 {core.int pageSize, core.String pageToken}) { |
| 416 async.Future<ListDevicesResponse> list(core.String parent, {core.int pageSize,
core.String pageToken}) { | |
| 417 var _url = null; | 405 var _url = null; |
| 418 var _queryParams = new core.Map(); | 406 var _queryParams = new core.Map(); |
| 419 var _uploadMedia = null; | 407 var _uploadMedia = null; |
| 420 var _uploadOptions = null; | 408 var _uploadOptions = null; |
| 421 var _downloadOptions = commons.DownloadOptions.Metadata; | 409 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 422 var _body = null; | 410 var _body = null; |
| 423 | 411 |
| 424 if (parent == null) { | 412 if (parent == null) { |
| 425 throw new core.ArgumentError("Parameter parent is required."); | 413 throw new core.ArgumentError("Parameter parent is required."); |
| 426 } | 414 } |
| 427 if (pageSize != null) { | 415 if (pageSize != null) { |
| 428 _queryParams["pageSize"] = ["${pageSize}"]; | 416 _queryParams["pageSize"] = ["${pageSize}"]; |
| 429 } | 417 } |
| 430 if (pageToken != null) { | 418 if (pageToken != null) { |
| 431 _queryParams["pageToken"] = [pageToken]; | 419 _queryParams["pageToken"] = [pageToken]; |
| 432 } | 420 } |
| 433 | 421 |
| 434 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/devices'
; | 422 _url = |
| 423 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/devices'; |
| 435 | 424 |
| 436 var _response = _requester.request(_url, | 425 var _response = _requester.request(_url, "GET", |
| 437 "GET", | 426 body: _body, |
| 438 body: _body, | 427 queryParams: _queryParams, |
| 439 queryParams: _queryParams, | 428 uploadOptions: _uploadOptions, |
| 440 uploadOptions: _uploadOptions, | 429 uploadMedia: _uploadMedia, |
| 441 uploadMedia: _uploadMedia, | 430 downloadOptions: _downloadOptions); |
| 442 downloadOptions: _downloadOptions); | |
| 443 return _response.then((data) => new ListDevicesResponse.fromJson(data)); | 431 return _response.then((data) => new ListDevicesResponse.fromJson(data)); |
| 444 } | 432 } |
| 445 | 433 |
| 446 /** | 434 /// Updates a device. |
| 447 * Updates a device. | 435 /// |
| 448 * | 436 /// [request] - The metadata request object. |
| 449 * [request] - The metadata request object. | 437 /// |
| 450 * | 438 /// Request parameters: |
| 451 * Request parameters: | 439 /// |
| 452 * | 440 /// [name] - The name of the device in the form |
| 453 * [name] - The name of the device in the form | 441 /// enterprises/{enterpriseId}/devices/{deviceId} |
| 454 * enterprises/{enterpriseId}/devices/{deviceId} | 442 /// Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". |
| 455 * Value must have pattern "^enterprises/[^/]+/devices/[^/]+$". | 443 /// |
| 456 * | 444 /// [updateMask] - The field mask indicating the fields to update. If not |
| 457 * [updateMask] - The field mask indicating the fields to update. If not set, | 445 /// set, all modifiable fields will be modified. |
| 458 * all modifiable fields will be modified. | 446 /// |
| 459 * | 447 /// Completes with a [Device]. |
| 460 * Completes with a [Device]. | 448 /// |
| 461 * | 449 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 462 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 450 /// an error. |
| 463 * error. | 451 /// |
| 464 * | 452 /// If the used [http.Client] completes with an error when making a REST |
| 465 * If the used [http.Client] completes with an error when making a REST call, | 453 /// call, this method will complete with the same error. |
| 466 * this method will complete with the same error. | 454 async.Future<Device> patch(Device request, core.String name, |
| 467 */ | 455 {core.String updateMask}) { |
| 468 async.Future<Device> patch(Device request, core.String name, {core.String upda
teMask}) { | |
| 469 var _url = null; | 456 var _url = null; |
| 470 var _queryParams = new core.Map(); | 457 var _queryParams = new core.Map(); |
| 471 var _uploadMedia = null; | 458 var _uploadMedia = null; |
| 472 var _uploadOptions = null; | 459 var _uploadOptions = null; |
| 473 var _downloadOptions = commons.DownloadOptions.Metadata; | 460 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 474 var _body = null; | 461 var _body = null; |
| 475 | 462 |
| 476 if (request != null) { | 463 if (request != null) { |
| 477 _body = convert.JSON.encode((request).toJson()); | 464 _body = convert.JSON.encode((request).toJson()); |
| 478 } | 465 } |
| 479 if (name == null) { | 466 if (name == null) { |
| 480 throw new core.ArgumentError("Parameter name is required."); | 467 throw new core.ArgumentError("Parameter name is required."); |
| 481 } | 468 } |
| 482 if (updateMask != null) { | 469 if (updateMask != null) { |
| 483 _queryParams["updateMask"] = [updateMask]; | 470 _queryParams["updateMask"] = [updateMask]; |
| 484 } | 471 } |
| 485 | 472 |
| 486 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 473 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 487 | 474 |
| 488 var _response = _requester.request(_url, | 475 var _response = _requester.request(_url, "PATCH", |
| 489 "PATCH", | 476 body: _body, |
| 490 body: _body, | 477 queryParams: _queryParams, |
| 491 queryParams: _queryParams, | 478 uploadOptions: _uploadOptions, |
| 492 uploadOptions: _uploadOptions, | 479 uploadMedia: _uploadMedia, |
| 493 uploadMedia: _uploadMedia, | 480 downloadOptions: _downloadOptions); |
| 494 downloadOptions: _downloadOptions); | |
| 495 return _response.then((data) => new Device.fromJson(data)); | 481 return _response.then((data) => new Device.fromJson(data)); |
| 496 } | 482 } |
| 497 | |
| 498 } | 483 } |
| 499 | 484 |
| 500 | |
| 501 class EnterprisesDevicesOperationsResourceApi { | 485 class EnterprisesDevicesOperationsResourceApi { |
| 502 final commons.ApiRequester _requester; | 486 final commons.ApiRequester _requester; |
| 503 | 487 |
| 504 EnterprisesDevicesOperationsResourceApi(commons.ApiRequester client) : | 488 EnterprisesDevicesOperationsResourceApi(commons.ApiRequester client) |
| 505 _requester = client; | 489 : _requester = client; |
| 506 | 490 |
| 507 /** | 491 /// Starts asynchronous cancellation on a long-running operation. The server |
| 508 * Starts asynchronous cancellation on a long-running operation. The server | 492 /// makes a best effort to cancel the operation, but success is not |
| 509 * makes a best effort to cancel the operation, but success is not guaranteed. | 493 /// guaranteed. If the server doesn't support this method, it returns |
| 510 * If the server doesn't support this method, it returns | 494 /// google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or |
| 511 * google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or | 495 /// other methods to check whether the cancellation succeeded or whether the |
| 512 * other methods to check whether the cancellation succeeded or whether the | 496 /// operation completed despite cancellation. On successful cancellation, the |
| 513 * operation completed despite cancellation. On successful cancellation, the | 497 /// operation is not deleted; instead, it becomes an operation with an |
| 514 * operation is not deleted; instead, it becomes an operation with an | 498 /// Operation.error value with a google.rpc.Status.code of 1, corresponding |
| 515 * Operation.error value with a google.rpc.Status.code of 1, corresponding to | 499 /// to Code.CANCELLED. |
| 516 * Code.CANCELLED. | 500 /// |
| 517 * | 501 /// Request parameters: |
| 518 * Request parameters: | 502 /// |
| 519 * | 503 /// [name] - The name of the operation resource to be cancelled. |
| 520 * [name] - The name of the operation resource to be cancelled. | 504 /// Value must have pattern |
| 521 * Value must have pattern | 505 /// "^enterprises/[^/]+/devices/[^/]+/operations/[^/]+$". |
| 522 * "^enterprises/[^/]+/devices/[^/]+/operations/[^/]+$". | 506 /// |
| 523 * | 507 /// Completes with a [Empty]. |
| 524 * Completes with a [Empty]. | 508 /// |
| 525 * | 509 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 526 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 510 /// an error. |
| 527 * error. | 511 /// |
| 528 * | 512 /// If the used [http.Client] completes with an error when making a REST |
| 529 * If the used [http.Client] completes with an error when making a REST call, | 513 /// call, this method will complete with the same error. |
| 530 * this method will complete with the same error. | |
| 531 */ | |
| 532 async.Future<Empty> cancel(core.String name) { | 514 async.Future<Empty> cancel(core.String name) { |
| 533 var _url = null; | 515 var _url = null; |
| 534 var _queryParams = new core.Map(); | 516 var _queryParams = new core.Map(); |
| 535 var _uploadMedia = null; | 517 var _uploadMedia = null; |
| 536 var _uploadOptions = null; | 518 var _uploadOptions = null; |
| 537 var _downloadOptions = commons.DownloadOptions.Metadata; | 519 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 538 var _body = null; | 520 var _body = null; |
| 539 | 521 |
| 540 if (name == null) { | 522 if (name == null) { |
| 541 throw new core.ArgumentError("Parameter name is required."); | 523 throw new core.ArgumentError("Parameter name is required."); |
| 542 } | 524 } |
| 543 | 525 |
| 544 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name') + ':cancel'; | 526 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name') + ':cancel'; |
| 545 | 527 |
| 546 var _response = _requester.request(_url, | 528 var _response = _requester.request(_url, "POST", |
| 547 "POST", | 529 body: _body, |
| 548 body: _body, | 530 queryParams: _queryParams, |
| 549 queryParams: _queryParams, | 531 uploadOptions: _uploadOptions, |
| 550 uploadOptions: _uploadOptions, | 532 uploadMedia: _uploadMedia, |
| 551 uploadMedia: _uploadMedia, | 533 downloadOptions: _downloadOptions); |
| 552 downloadOptions: _downloadOptions); | |
| 553 return _response.then((data) => new Empty.fromJson(data)); | 534 return _response.then((data) => new Empty.fromJson(data)); |
| 554 } | 535 } |
| 555 | 536 |
| 556 /** | 537 /// Deletes a long-running operation. This method indicates that the client |
| 557 * Deletes a long-running operation. This method indicates that the client is | 538 /// is no longer interested in the operation result. It does not cancel the |
| 558 * no longer interested in the operation result. It does not cancel the | 539 /// operation. If the server doesn't support this method, it returns |
| 559 * operation. If the server doesn't support this method, it returns | 540 /// google.rpc.Code.UNIMPLEMENTED. |
| 560 * google.rpc.Code.UNIMPLEMENTED. | 541 /// |
| 561 * | 542 /// Request parameters: |
| 562 * Request parameters: | 543 /// |
| 563 * | 544 /// [name] - The name of the operation resource to be deleted. |
| 564 * [name] - The name of the operation resource to be deleted. | 545 /// Value must have pattern |
| 565 * Value must have pattern | 546 /// "^enterprises/[^/]+/devices/[^/]+/operations/[^/]+$". |
| 566 * "^enterprises/[^/]+/devices/[^/]+/operations/[^/]+$". | 547 /// |
| 567 * | 548 /// Completes with a [Empty]. |
| 568 * Completes with a [Empty]. | 549 /// |
| 569 * | 550 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 570 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 551 /// an error. |
| 571 * error. | 552 /// |
| 572 * | 553 /// If the used [http.Client] completes with an error when making a REST |
| 573 * If the used [http.Client] completes with an error when making a REST call, | 554 /// call, this method will complete with the same error. |
| 574 * this method will complete with the same error. | |
| 575 */ | |
| 576 async.Future<Empty> delete(core.String name) { | 555 async.Future<Empty> delete(core.String name) { |
| 577 var _url = null; | 556 var _url = null; |
| 578 var _queryParams = new core.Map(); | 557 var _queryParams = new core.Map(); |
| 579 var _uploadMedia = null; | 558 var _uploadMedia = null; |
| 580 var _uploadOptions = null; | 559 var _uploadOptions = null; |
| 581 var _downloadOptions = commons.DownloadOptions.Metadata; | 560 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 582 var _body = null; | 561 var _body = null; |
| 583 | 562 |
| 584 if (name == null) { | 563 if (name == null) { |
| 585 throw new core.ArgumentError("Parameter name is required."); | 564 throw new core.ArgumentError("Parameter name is required."); |
| 586 } | 565 } |
| 587 | 566 |
| 588 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 567 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 589 | 568 |
| 590 var _response = _requester.request(_url, | 569 var _response = _requester.request(_url, "DELETE", |
| 591 "DELETE", | 570 body: _body, |
| 592 body: _body, | 571 queryParams: _queryParams, |
| 593 queryParams: _queryParams, | 572 uploadOptions: _uploadOptions, |
| 594 uploadOptions: _uploadOptions, | 573 uploadMedia: _uploadMedia, |
| 595 uploadMedia: _uploadMedia, | 574 downloadOptions: _downloadOptions); |
| 596 downloadOptions: _downloadOptions); | |
| 597 return _response.then((data) => new Empty.fromJson(data)); | 575 return _response.then((data) => new Empty.fromJson(data)); |
| 598 } | 576 } |
| 599 | 577 |
| 600 /** | 578 /// Gets the latest state of a long-running operation. Clients can use this |
| 601 * Gets the latest state of a long-running operation. Clients can use this | 579 /// method to poll the operation result at intervals as recommended by the |
| 602 * method to poll the operation result at intervals as recommended by the API | 580 /// API service. |
| 603 * service. | 581 /// |
| 604 * | 582 /// Request parameters: |
| 605 * Request parameters: | 583 /// |
| 606 * | 584 /// [name] - The name of the operation resource. |
| 607 * [name] - The name of the operation resource. | 585 /// Value must have pattern |
| 608 * Value must have pattern | 586 /// "^enterprises/[^/]+/devices/[^/]+/operations/[^/]+$". |
| 609 * "^enterprises/[^/]+/devices/[^/]+/operations/[^/]+$". | 587 /// |
| 610 * | 588 /// Completes with a [Operation]. |
| 611 * Completes with a [Operation]. | 589 /// |
| 612 * | 590 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 613 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 591 /// an error. |
| 614 * error. | 592 /// |
| 615 * | 593 /// If the used [http.Client] completes with an error when making a REST |
| 616 * If the used [http.Client] completes with an error when making a REST call, | 594 /// call, this method will complete with the same error. |
| 617 * this method will complete with the same error. | |
| 618 */ | |
| 619 async.Future<Operation> get(core.String name) { | 595 async.Future<Operation> get(core.String name) { |
| 620 var _url = null; | 596 var _url = null; |
| 621 var _queryParams = new core.Map(); | 597 var _queryParams = new core.Map(); |
| 622 var _uploadMedia = null; | 598 var _uploadMedia = null; |
| 623 var _uploadOptions = null; | 599 var _uploadOptions = null; |
| 624 var _downloadOptions = commons.DownloadOptions.Metadata; | 600 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 625 var _body = null; | 601 var _body = null; |
| 626 | 602 |
| 627 if (name == null) { | 603 if (name == null) { |
| 628 throw new core.ArgumentError("Parameter name is required."); | 604 throw new core.ArgumentError("Parameter name is required."); |
| 629 } | 605 } |
| 630 | 606 |
| 631 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 607 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 632 | 608 |
| 633 var _response = _requester.request(_url, | 609 var _response = _requester.request(_url, "GET", |
| 634 "GET", | 610 body: _body, |
| 635 body: _body, | 611 queryParams: _queryParams, |
| 636 queryParams: _queryParams, | 612 uploadOptions: _uploadOptions, |
| 637 uploadOptions: _uploadOptions, | 613 uploadMedia: _uploadMedia, |
| 638 uploadMedia: _uploadMedia, | 614 downloadOptions: _downloadOptions); |
| 639 downloadOptions: _downloadOptions); | |
| 640 return _response.then((data) => new Operation.fromJson(data)); | 615 return _response.then((data) => new Operation.fromJson(data)); |
| 641 } | 616 } |
| 642 | 617 |
| 643 /** | 618 /// Lists operations that match the specified filter in the request. If the |
| 644 * Lists operations that match the specified filter in the request. If the | 619 /// server doesn't support this method, it returns UNIMPLEMENTED.NOTE: the |
| 645 * server doesn't support this method, it returns UNIMPLEMENTED.NOTE: the name | 620 /// name binding allows API services to override the binding to use different |
| 646 * binding allows API services to override the binding to use different | 621 /// resource name schemes, such as users / * /operations. To override the |
| 647 * resource name schemes, such as users / * /operations. To override the | 622 /// binding, API services can add a binding such as "/v1/{name=users / * |
| 648 * binding, API services can add a binding such as "/v1/{name=users / * | 623 /// }/operations" to their service configuration. For backwards |
| 649 * }/operations" to their service configuration. For backwards compatibility, | 624 /// compatibility, the default name includes the operations collection id, |
| 650 * the default name includes the operations collection id, however overriding | 625 /// however overriding users must ensure the name binding is the parent |
| 651 * users must ensure the name binding is the parent resource, without the | 626 /// resource, without the operations collection id. |
| 652 * operations collection id. | 627 /// |
| 653 * | 628 /// Request parameters: |
| 654 * Request parameters: | 629 /// |
| 655 * | 630 /// [name] - The name of the operation's parent resource. |
| 656 * [name] - The name of the operation's parent resource. | 631 /// Value must have pattern "^enterprises/[^/]+/devices/[^/]+/operations$". |
| 657 * Value must have pattern "^enterprises/[^/]+/devices/[^/]+/operations$". | 632 /// |
| 658 * | 633 /// [pageSize] - The standard list page size. |
| 659 * [pageSize] - The standard list page size. | 634 /// |
| 660 * | 635 /// [filter] - The standard list filter. |
| 661 * [filter] - The standard list filter. | 636 /// |
| 662 * | 637 /// [pageToken] - The standard list page token. |
| 663 * [pageToken] - The standard list page token. | 638 /// |
| 664 * | 639 /// Completes with a [ListOperationsResponse]. |
| 665 * Completes with a [ListOperationsResponse]. | 640 /// |
| 666 * | 641 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 667 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 642 /// an error. |
| 668 * error. | 643 /// |
| 669 * | 644 /// If the used [http.Client] completes with an error when making a REST |
| 670 * If the used [http.Client] completes with an error when making a REST call, | 645 /// call, this method will complete with the same error. |
| 671 * this method will complete with the same error. | 646 async.Future<ListOperationsResponse> list(core.String name, |
| 672 */ | 647 {core.int pageSize, core.String filter, core.String pageToken}) { |
| 673 async.Future<ListOperationsResponse> list(core.String name, {core.int pageSize
, core.String filter, core.String pageToken}) { | |
| 674 var _url = null; | 648 var _url = null; |
| 675 var _queryParams = new core.Map(); | 649 var _queryParams = new core.Map(); |
| 676 var _uploadMedia = null; | 650 var _uploadMedia = null; |
| 677 var _uploadOptions = null; | 651 var _uploadOptions = null; |
| 678 var _downloadOptions = commons.DownloadOptions.Metadata; | 652 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 679 var _body = null; | 653 var _body = null; |
| 680 | 654 |
| 681 if (name == null) { | 655 if (name == null) { |
| 682 throw new core.ArgumentError("Parameter name is required."); | 656 throw new core.ArgumentError("Parameter name is required."); |
| 683 } | 657 } |
| 684 if (pageSize != null) { | 658 if (pageSize != null) { |
| 685 _queryParams["pageSize"] = ["${pageSize}"]; | 659 _queryParams["pageSize"] = ["${pageSize}"]; |
| 686 } | 660 } |
| 687 if (filter != null) { | 661 if (filter != null) { |
| 688 _queryParams["filter"] = [filter]; | 662 _queryParams["filter"] = [filter]; |
| 689 } | 663 } |
| 690 if (pageToken != null) { | 664 if (pageToken != null) { |
| 691 _queryParams["pageToken"] = [pageToken]; | 665 _queryParams["pageToken"] = [pageToken]; |
| 692 } | 666 } |
| 693 | 667 |
| 694 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 668 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 695 | 669 |
| 696 var _response = _requester.request(_url, | 670 var _response = _requester.request(_url, "GET", |
| 697 "GET", | 671 body: _body, |
| 698 body: _body, | 672 queryParams: _queryParams, |
| 699 queryParams: _queryParams, | 673 uploadOptions: _uploadOptions, |
| 700 uploadOptions: _uploadOptions, | 674 uploadMedia: _uploadMedia, |
| 701 uploadMedia: _uploadMedia, | 675 downloadOptions: _downloadOptions); |
| 702 downloadOptions: _downloadOptions); | |
| 703 return _response.then((data) => new ListOperationsResponse.fromJson(data)); | 676 return _response.then((data) => new ListOperationsResponse.fromJson(data)); |
| 704 } | 677 } |
| 705 | |
| 706 } | 678 } |
| 707 | 679 |
| 708 | |
| 709 class EnterprisesEnrollmentTokensResourceApi { | 680 class EnterprisesEnrollmentTokensResourceApi { |
| 710 final commons.ApiRequester _requester; | 681 final commons.ApiRequester _requester; |
| 711 | 682 |
| 712 EnterprisesEnrollmentTokensResourceApi(commons.ApiRequester client) : | 683 EnterprisesEnrollmentTokensResourceApi(commons.ApiRequester client) |
| 713 _requester = client; | 684 : _requester = client; |
| 714 | 685 |
| 715 /** | 686 /// Creates an enrollment token for a given enterprise. |
| 716 * Creates an enrollment token for a given enterprise. | 687 /// |
| 717 * | 688 /// [request] - The metadata request object. |
| 718 * [request] - The metadata request object. | 689 /// |
| 719 * | 690 /// Request parameters: |
| 720 * Request parameters: | 691 /// |
| 721 * | 692 /// [parent] - The name of the enterprise in the form |
| 722 * [parent] - The name of the enterprise in the form | 693 /// enterprises/{enterpriseId} |
| 723 * enterprises/{enterpriseId} | 694 /// Value must have pattern "^enterprises/[^/]+$". |
| 724 * Value must have pattern "^enterprises/[^/]+$". | 695 /// |
| 725 * | 696 /// Completes with a [EnrollmentToken]. |
| 726 * Completes with a [EnrollmentToken]. | 697 /// |
| 727 * | 698 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 728 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 699 /// an error. |
| 729 * error. | 700 /// |
| 730 * | 701 /// If the used [http.Client] completes with an error when making a REST |
| 731 * If the used [http.Client] completes with an error when making a REST call, | 702 /// call, this method will complete with the same error. |
| 732 * this method will complete with the same error. | 703 async.Future<EnrollmentToken> create( |
| 733 */ | 704 EnrollmentToken request, core.String parent) { |
| 734 async.Future<EnrollmentToken> create(EnrollmentToken request, core.String pare
nt) { | |
| 735 var _url = null; | 705 var _url = null; |
| 736 var _queryParams = new core.Map(); | 706 var _queryParams = new core.Map(); |
| 737 var _uploadMedia = null; | 707 var _uploadMedia = null; |
| 738 var _uploadOptions = null; | 708 var _uploadOptions = null; |
| 739 var _downloadOptions = commons.DownloadOptions.Metadata; | 709 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 740 var _body = null; | 710 var _body = null; |
| 741 | 711 |
| 742 if (request != null) { | 712 if (request != null) { |
| 743 _body = convert.JSON.encode((request).toJson()); | 713 _body = convert.JSON.encode((request).toJson()); |
| 744 } | 714 } |
| 745 if (parent == null) { | 715 if (parent == null) { |
| 746 throw new core.ArgumentError("Parameter parent is required."); | 716 throw new core.ArgumentError("Parameter parent is required."); |
| 747 } | 717 } |
| 748 | 718 |
| 749 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/enrollme
ntTokens'; | 719 _url = 'v1/' + |
| 720 commons.Escaper.ecapeVariableReserved('$parent') + |
| 721 '/enrollmentTokens'; |
| 750 | 722 |
| 751 var _response = _requester.request(_url, | 723 var _response = _requester.request(_url, "POST", |
| 752 "POST", | 724 body: _body, |
| 753 body: _body, | 725 queryParams: _queryParams, |
| 754 queryParams: _queryParams, | 726 uploadOptions: _uploadOptions, |
| 755 uploadOptions: _uploadOptions, | 727 uploadMedia: _uploadMedia, |
| 756 uploadMedia: _uploadMedia, | 728 downloadOptions: _downloadOptions); |
| 757 downloadOptions: _downloadOptions); | |
| 758 return _response.then((data) => new EnrollmentToken.fromJson(data)); | 729 return _response.then((data) => new EnrollmentToken.fromJson(data)); |
| 759 } | 730 } |
| 760 | 731 |
| 761 /** | 732 /// Deletes an enrollment token, which prevents future use of the token. |
| 762 * Deletes an enrollment token, which prevents future use of the token. | 733 /// |
| 763 * | 734 /// Request parameters: |
| 764 * Request parameters: | 735 /// |
| 765 * | 736 /// [name] - The name of the enrollment token in the form |
| 766 * [name] - The name of the enrollment token in the form | 737 /// enterprises/{enterpriseId}/enrollmentTokens/{enrollmentTokenId} |
| 767 * enterprises/{enterpriseId}/enrollmentTokens/{enrollmentTokenId} | 738 /// Value must have pattern "^enterprises/[^/]+/enrollmentTokens/[^/]+$". |
| 768 * Value must have pattern "^enterprises/[^/]+/enrollmentTokens/[^/]+$". | 739 /// |
| 769 * | 740 /// Completes with a [Empty]. |
| 770 * Completes with a [Empty]. | 741 /// |
| 771 * | 742 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 772 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 743 /// an error. |
| 773 * error. | 744 /// |
| 774 * | 745 /// If the used [http.Client] completes with an error when making a REST |
| 775 * If the used [http.Client] completes with an error when making a REST call, | 746 /// call, this method will complete with the same error. |
| 776 * this method will complete with the same error. | |
| 777 */ | |
| 778 async.Future<Empty> delete(core.String name) { | 747 async.Future<Empty> delete(core.String name) { |
| 779 var _url = null; | 748 var _url = null; |
| 780 var _queryParams = new core.Map(); | 749 var _queryParams = new core.Map(); |
| 781 var _uploadMedia = null; | 750 var _uploadMedia = null; |
| 782 var _uploadOptions = null; | 751 var _uploadOptions = null; |
| 783 var _downloadOptions = commons.DownloadOptions.Metadata; | 752 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 784 var _body = null; | 753 var _body = null; |
| 785 | 754 |
| 786 if (name == null) { | 755 if (name == null) { |
| 787 throw new core.ArgumentError("Parameter name is required."); | 756 throw new core.ArgumentError("Parameter name is required."); |
| 788 } | 757 } |
| 789 | 758 |
| 790 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 759 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 791 | 760 |
| 792 var _response = _requester.request(_url, | 761 var _response = _requester.request(_url, "DELETE", |
| 793 "DELETE", | 762 body: _body, |
| 794 body: _body, | 763 queryParams: _queryParams, |
| 795 queryParams: _queryParams, | 764 uploadOptions: _uploadOptions, |
| 796 uploadOptions: _uploadOptions, | 765 uploadMedia: _uploadMedia, |
| 797 uploadMedia: _uploadMedia, | 766 downloadOptions: _downloadOptions); |
| 798 downloadOptions: _downloadOptions); | |
| 799 return _response.then((data) => new Empty.fromJson(data)); | 767 return _response.then((data) => new Empty.fromJson(data)); |
| 800 } | 768 } |
| 801 | |
| 802 } | 769 } |
| 803 | 770 |
| 804 | |
| 805 class EnterprisesPoliciesResourceApi { | 771 class EnterprisesPoliciesResourceApi { |
| 806 final commons.ApiRequester _requester; | 772 final commons.ApiRequester _requester; |
| 807 | 773 |
| 808 EnterprisesPoliciesResourceApi(commons.ApiRequester client) : | 774 EnterprisesPoliciesResourceApi(commons.ApiRequester client) |
| 809 _requester = client; | 775 : _requester = client; |
| 810 | 776 |
| 811 /** | 777 /// Deletes a policy. This operation is only permitted if no devices are |
| 812 * Deletes a policy. This operation is only permitted if no devices are | 778 /// currently referencing the policy. |
| 813 * currently referencing the policy. | 779 /// |
| 814 * | 780 /// Request parameters: |
| 815 * Request parameters: | 781 /// |
| 816 * | 782 /// [name] - The name of the policy in the form |
| 817 * [name] - The name of the policy in the form | 783 /// enterprises/{enterpriseId}/policies/{policyId} |
| 818 * enterprises/{enterpriseId}/policies/{policyId} | 784 /// Value must have pattern "^enterprises/[^/]+/policies/[^/]+$". |
| 819 * Value must have pattern "^enterprises/[^/]+/policies/[^/]+$". | 785 /// |
| 820 * | 786 /// Completes with a [Empty]. |
| 821 * Completes with a [Empty]. | 787 /// |
| 822 * | 788 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 823 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 789 /// an error. |
| 824 * error. | 790 /// |
| 825 * | 791 /// 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, | 792 /// call, this method will complete with the same error. |
| 827 * this method will complete with the same error. | |
| 828 */ | |
| 829 async.Future<Empty> delete(core.String name) { | 793 async.Future<Empty> delete(core.String name) { |
| 830 var _url = null; | 794 var _url = null; |
| 831 var _queryParams = new core.Map(); | 795 var _queryParams = new core.Map(); |
| 832 var _uploadMedia = null; | 796 var _uploadMedia = null; |
| 833 var _uploadOptions = null; | 797 var _uploadOptions = null; |
| 834 var _downloadOptions = commons.DownloadOptions.Metadata; | 798 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 835 var _body = null; | 799 var _body = null; |
| 836 | 800 |
| 837 if (name == null) { | 801 if (name == null) { |
| 838 throw new core.ArgumentError("Parameter name is required."); | 802 throw new core.ArgumentError("Parameter name is required."); |
| 839 } | 803 } |
| 840 | 804 |
| 841 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 805 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 842 | 806 |
| 843 var _response = _requester.request(_url, | 807 var _response = _requester.request(_url, "DELETE", |
| 844 "DELETE", | 808 body: _body, |
| 845 body: _body, | 809 queryParams: _queryParams, |
| 846 queryParams: _queryParams, | 810 uploadOptions: _uploadOptions, |
| 847 uploadOptions: _uploadOptions, | 811 uploadMedia: _uploadMedia, |
| 848 uploadMedia: _uploadMedia, | 812 downloadOptions: _downloadOptions); |
| 849 downloadOptions: _downloadOptions); | |
| 850 return _response.then((data) => new Empty.fromJson(data)); | 813 return _response.then((data) => new Empty.fromJson(data)); |
| 851 } | 814 } |
| 852 | 815 |
| 853 /** | 816 /// Gets a policy. |
| 854 * Gets a policy. | 817 /// |
| 855 * | 818 /// Request parameters: |
| 856 * Request parameters: | 819 /// |
| 857 * | 820 /// [name] - The name of the policy in the form |
| 858 * [name] - The name of the policy in the form | 821 /// enterprises/{enterpriseId}/policies/{policyId} |
| 859 * enterprises/{enterpriseId}/policies/{policyId} | 822 /// Value must have pattern "^enterprises/[^/]+/policies/[^/]+$". |
| 860 * Value must have pattern "^enterprises/[^/]+/policies/[^/]+$". | 823 /// |
| 861 * | 824 /// Completes with a [Policy]. |
| 862 * Completes with a [Policy]. | 825 /// |
| 863 * | 826 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 864 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 827 /// an error. |
| 865 * error. | 828 /// |
| 866 * | 829 /// 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, | 830 /// call, this method will complete with the same error. |
| 868 * this method will complete with the same error. | |
| 869 */ | |
| 870 async.Future<Policy> get(core.String name) { | 831 async.Future<Policy> get(core.String name) { |
| 871 var _url = null; | 832 var _url = null; |
| 872 var _queryParams = new core.Map(); | 833 var _queryParams = new core.Map(); |
| 873 var _uploadMedia = null; | 834 var _uploadMedia = null; |
| 874 var _uploadOptions = null; | 835 var _uploadOptions = null; |
| 875 var _downloadOptions = commons.DownloadOptions.Metadata; | 836 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 876 var _body = null; | 837 var _body = null; |
| 877 | 838 |
| 878 if (name == null) { | 839 if (name == null) { |
| 879 throw new core.ArgumentError("Parameter name is required."); | 840 throw new core.ArgumentError("Parameter name is required."); |
| 880 } | 841 } |
| 881 | 842 |
| 882 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 843 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 883 | 844 |
| 884 var _response = _requester.request(_url, | 845 var _response = _requester.request(_url, "GET", |
| 885 "GET", | 846 body: _body, |
| 886 body: _body, | 847 queryParams: _queryParams, |
| 887 queryParams: _queryParams, | 848 uploadOptions: _uploadOptions, |
| 888 uploadOptions: _uploadOptions, | 849 uploadMedia: _uploadMedia, |
| 889 uploadMedia: _uploadMedia, | 850 downloadOptions: _downloadOptions); |
| 890 downloadOptions: _downloadOptions); | |
| 891 return _response.then((data) => new Policy.fromJson(data)); | 851 return _response.then((data) => new Policy.fromJson(data)); |
| 892 } | 852 } |
| 893 | 853 |
| 894 /** | 854 /// Lists policies for a given enterprise. |
| 895 * Lists policies for a given enterprise. | 855 /// |
| 896 * | 856 /// Request parameters: |
| 897 * Request parameters: | 857 /// |
| 898 * | 858 /// [parent] - The name of the enterprise in the form |
| 899 * [parent] - The name of the enterprise in the form | 859 /// enterprises/{enterpriseId} |
| 900 * enterprises/{enterpriseId} | 860 /// Value must have pattern "^enterprises/[^/]+$". |
| 901 * Value must have pattern "^enterprises/[^/]+$". | 861 /// |
| 902 * | 862 /// [pageSize] - The requested page size. The actual page size may be fixed |
| 903 * [pageSize] - The requested page size. The actual page size may be fixed to | 863 /// to a min or max value. |
| 904 * a min or max value. | 864 /// |
| 905 * | 865 /// [pageToken] - A token identifying a page of results the server should |
| 906 * [pageToken] - A token identifying a page of results the server should | 866 /// return. |
| 907 * return. | 867 /// |
| 908 * | 868 /// Completes with a [ListPoliciesResponse]. |
| 909 * Completes with a [ListPoliciesResponse]. | 869 /// |
| 910 * | 870 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 911 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 871 /// an error. |
| 912 * error. | 872 /// |
| 913 * | 873 /// If the used [http.Client] completes with an error when making a REST |
| 914 * If the used [http.Client] completes with an error when making a REST call, | 874 /// call, this method will complete with the same error. |
| 915 * this method will complete with the same error. | 875 async.Future<ListPoliciesResponse> list(core.String parent, |
| 916 */ | 876 {core.int pageSize, core.String pageToken}) { |
| 917 async.Future<ListPoliciesResponse> list(core.String parent, {core.int pageSize
, core.String pageToken}) { | |
| 918 var _url = null; | 877 var _url = null; |
| 919 var _queryParams = new core.Map(); | 878 var _queryParams = new core.Map(); |
| 920 var _uploadMedia = null; | 879 var _uploadMedia = null; |
| 921 var _uploadOptions = null; | 880 var _uploadOptions = null; |
| 922 var _downloadOptions = commons.DownloadOptions.Metadata; | 881 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 923 var _body = null; | 882 var _body = null; |
| 924 | 883 |
| 925 if (parent == null) { | 884 if (parent == null) { |
| 926 throw new core.ArgumentError("Parameter parent is required."); | 885 throw new core.ArgumentError("Parameter parent is required."); |
| 927 } | 886 } |
| 928 if (pageSize != null) { | 887 if (pageSize != null) { |
| 929 _queryParams["pageSize"] = ["${pageSize}"]; | 888 _queryParams["pageSize"] = ["${pageSize}"]; |
| 930 } | 889 } |
| 931 if (pageToken != null) { | 890 if (pageToken != null) { |
| 932 _queryParams["pageToken"] = [pageToken]; | 891 _queryParams["pageToken"] = [pageToken]; |
| 933 } | 892 } |
| 934 | 893 |
| 935 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/policies
'; | 894 _url = |
| 895 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/policies'; |
| 936 | 896 |
| 937 var _response = _requester.request(_url, | 897 var _response = _requester.request(_url, "GET", |
| 938 "GET", | 898 body: _body, |
| 939 body: _body, | 899 queryParams: _queryParams, |
| 940 queryParams: _queryParams, | 900 uploadOptions: _uploadOptions, |
| 941 uploadOptions: _uploadOptions, | 901 uploadMedia: _uploadMedia, |
| 942 uploadMedia: _uploadMedia, | 902 downloadOptions: _downloadOptions); |
| 943 downloadOptions: _downloadOptions); | |
| 944 return _response.then((data) => new ListPoliciesResponse.fromJson(data)); | 903 return _response.then((data) => new ListPoliciesResponse.fromJson(data)); |
| 945 } | 904 } |
| 946 | 905 |
| 947 /** | 906 /// Updates or creates a policy. |
| 948 * Updates or creates a policy. | 907 /// |
| 949 * | 908 /// [request] - The metadata request object. |
| 950 * [request] - The metadata request object. | 909 /// |
| 951 * | 910 /// Request parameters: |
| 952 * Request parameters: | 911 /// |
| 953 * | 912 /// [name] - The name of the policy in the form |
| 954 * [name] - The name of the policy in the form | 913 /// enterprises/{enterpriseId}/policies/{policyId} |
| 955 * enterprises/{enterpriseId}/policies/{policyId} | 914 /// Value must have pattern "^enterprises/[^/]+/policies/[^/]+$". |
| 956 * Value must have pattern "^enterprises/[^/]+/policies/[^/]+$". | 915 /// |
| 957 * | 916 /// [updateMask] - The field mask indicating the fields to update. If not |
| 958 * [updateMask] - The field mask indicating the fields to update. If not set, | 917 /// set, all modifiable fields will be modified. |
| 959 * all modifiable fields will be modified. | 918 /// |
| 960 * | 919 /// Completes with a [Policy]. |
| 961 * Completes with a [Policy]. | 920 /// |
| 962 * | 921 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 963 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 922 /// an error. |
| 964 * error. | 923 /// |
| 965 * | 924 /// If the used [http.Client] completes with an error when making a REST |
| 966 * If the used [http.Client] completes with an error when making a REST call, | 925 /// call, this method will complete with the same error. |
| 967 * this method will complete with the same error. | 926 async.Future<Policy> patch(Policy request, core.String name, |
| 968 */ | 927 {core.String updateMask}) { |
| 969 async.Future<Policy> patch(Policy request, core.String name, {core.String upda
teMask}) { | |
| 970 var _url = null; | 928 var _url = null; |
| 971 var _queryParams = new core.Map(); | 929 var _queryParams = new core.Map(); |
| 972 var _uploadMedia = null; | 930 var _uploadMedia = null; |
| 973 var _uploadOptions = null; | 931 var _uploadOptions = null; |
| 974 var _downloadOptions = commons.DownloadOptions.Metadata; | 932 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 975 var _body = null; | 933 var _body = null; |
| 976 | 934 |
| 977 if (request != null) { | 935 if (request != null) { |
| 978 _body = convert.JSON.encode((request).toJson()); | 936 _body = convert.JSON.encode((request).toJson()); |
| 979 } | 937 } |
| 980 if (name == null) { | 938 if (name == null) { |
| 981 throw new core.ArgumentError("Parameter name is required."); | 939 throw new core.ArgumentError("Parameter name is required."); |
| 982 } | 940 } |
| 983 if (updateMask != null) { | 941 if (updateMask != null) { |
| 984 _queryParams["updateMask"] = [updateMask]; | 942 _queryParams["updateMask"] = [updateMask]; |
| 985 } | 943 } |
| 986 | 944 |
| 987 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); | 945 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 988 | 946 |
| 989 var _response = _requester.request(_url, | 947 var _response = _requester.request(_url, "PATCH", |
| 990 "PATCH", | 948 body: _body, |
| 991 body: _body, | 949 queryParams: _queryParams, |
| 992 queryParams: _queryParams, | 950 uploadOptions: _uploadOptions, |
| 993 uploadOptions: _uploadOptions, | 951 uploadMedia: _uploadMedia, |
| 994 uploadMedia: _uploadMedia, | 952 downloadOptions: _downloadOptions); |
| 995 downloadOptions: _downloadOptions); | |
| 996 return _response.then((data) => new Policy.fromJson(data)); | 953 return _response.then((data) => new Policy.fromJson(data)); |
| 997 } | 954 } |
| 998 | |
| 999 } | 955 } |
| 1000 | 956 |
| 1001 | |
| 1002 class EnterprisesWebTokensResourceApi { | 957 class EnterprisesWebTokensResourceApi { |
| 1003 final commons.ApiRequester _requester; | 958 final commons.ApiRequester _requester; |
| 1004 | 959 |
| 1005 EnterprisesWebTokensResourceApi(commons.ApiRequester client) : | 960 EnterprisesWebTokensResourceApi(commons.ApiRequester client) |
| 1006 _requester = client; | 961 : _requester = client; |
| 1007 | 962 |
| 1008 /** | 963 /// Creates a web token to access an embeddable managed Google Play web UI |
| 1009 * Creates a web token to access an embeddable managed Google Play web UI for | 964 /// for a given enterprise. |
| 1010 * a given enterprise. | 965 /// |
| 1011 * | 966 /// [request] - The metadata request object. |
| 1012 * [request] - The metadata request object. | 967 /// |
| 1013 * | 968 /// Request parameters: |
| 1014 * Request parameters: | 969 /// |
| 1015 * | 970 /// [parent] - The name of the enterprise in the form |
| 1016 * [parent] - The name of the enterprise in the form | 971 /// enterprises/{enterpriseId} |
| 1017 * enterprises/{enterpriseId} | 972 /// Value must have pattern "^enterprises/[^/]+$". |
| 1018 * Value must have pattern "^enterprises/[^/]+$". | 973 /// |
| 1019 * | 974 /// Completes with a [WebToken]. |
| 1020 * Completes with a [WebToken]. | 975 /// |
| 1021 * | 976 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 1022 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 977 /// an error. |
| 1023 * error. | 978 /// |
| 1024 * | 979 /// If the used [http.Client] completes with an error when making a REST |
| 1025 * If the used [http.Client] completes with an error when making a REST call, | 980 /// call, this method will complete with the same error. |
| 1026 * this method will complete with the same error. | |
| 1027 */ | |
| 1028 async.Future<WebToken> create(WebToken request, core.String parent) { | 981 async.Future<WebToken> create(WebToken request, core.String parent) { |
| 1029 var _url = null; | 982 var _url = null; |
| 1030 var _queryParams = new core.Map(); | 983 var _queryParams = new core.Map(); |
| 1031 var _uploadMedia = null; | 984 var _uploadMedia = null; |
| 1032 var _uploadOptions = null; | 985 var _uploadOptions = null; |
| 1033 var _downloadOptions = commons.DownloadOptions.Metadata; | 986 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 1034 var _body = null; | 987 var _body = null; |
| 1035 | 988 |
| 1036 if (request != null) { | 989 if (request != null) { |
| 1037 _body = convert.JSON.encode((request).toJson()); | 990 _body = convert.JSON.encode((request).toJson()); |
| 1038 } | 991 } |
| 1039 if (parent == null) { | 992 if (parent == null) { |
| 1040 throw new core.ArgumentError("Parameter parent is required."); | 993 throw new core.ArgumentError("Parameter parent is required."); |
| 1041 } | 994 } |
| 1042 | 995 |
| 1043 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/webToken
s'; | 996 _url = |
| 997 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/webTokens'; |
| 1044 | 998 |
| 1045 var _response = _requester.request(_url, | 999 var _response = _requester.request(_url, "POST", |
| 1046 "POST", | 1000 body: _body, |
| 1047 body: _body, | 1001 queryParams: _queryParams, |
| 1048 queryParams: _queryParams, | 1002 uploadOptions: _uploadOptions, |
| 1049 uploadOptions: _uploadOptions, | 1003 uploadMedia: _uploadMedia, |
| 1050 uploadMedia: _uploadMedia, | 1004 downloadOptions: _downloadOptions); |
| 1051 downloadOptions: _downloadOptions); | |
| 1052 return _response.then((data) => new WebToken.fromJson(data)); | 1005 return _response.then((data) => new WebToken.fromJson(data)); |
| 1053 } | 1006 } |
| 1054 | |
| 1055 } | 1007 } |
| 1056 | 1008 |
| 1057 | |
| 1058 class SignupUrlsResourceApi { | 1009 class SignupUrlsResourceApi { |
| 1059 final commons.ApiRequester _requester; | 1010 final commons.ApiRequester _requester; |
| 1060 | 1011 |
| 1061 SignupUrlsResourceApi(commons.ApiRequester client) : | 1012 SignupUrlsResourceApi(commons.ApiRequester client) : _requester = client; |
| 1062 _requester = client; | |
| 1063 | 1013 |
| 1064 /** | 1014 /// Creates an enterprise signup URL. |
| 1065 * Creates an enterprise signup URL. | 1015 /// |
| 1066 * | 1016 /// Request parameters: |
| 1067 * Request parameters: | 1017 /// |
| 1068 * | 1018 /// [callbackUrl] - The callback URL to which the admin will be redirected |
| 1069 * [callbackUrl] - The callback URL to which the admin will be redirected | 1019 /// after successfully creating an enterprise. Before redirecting there the |
| 1070 * after successfully creating an enterprise. Before redirecting there the | 1020 /// system will add a query parameter to this URL named enterpriseToken which |
| 1071 * system will add a query parameter to this URL named enterpriseToken which | 1021 /// will contain an opaque token to be used for the create enterprise |
| 1072 * will contain an opaque token to be used for the create enterprise request. | 1022 /// request. The URL will be parsed then reformatted in order to add the |
| 1073 * The URL will be parsed then reformatted in order to add the enterpriseToken | 1023 /// enterpriseToken parameter, so there may be some minor formatting changes. |
| 1074 * parameter, so there may be some minor formatting changes. | 1024 /// |
| 1075 * | 1025 /// [projectId] - The id of the Google Cloud Platform project which will own |
| 1076 * [projectId] - The id of the Google Cloud Platform project which will own | 1026 /// the enterprise. |
| 1077 * the enterprise. | 1027 /// |
| 1078 * | 1028 /// Completes with a [SignupUrl]. |
| 1079 * Completes with a [SignupUrl]. | 1029 /// |
| 1080 * | 1030 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 1081 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 1031 /// an error. |
| 1082 * error. | 1032 /// |
| 1083 * | 1033 /// If the used [http.Client] completes with an error when making a REST |
| 1084 * If the used [http.Client] completes with an error when making a REST call, | 1034 /// call, this method will complete with the same error. |
| 1085 * this method will complete with the same error. | 1035 async.Future<SignupUrl> create( |
| 1086 */ | 1036 {core.String callbackUrl, core.String projectId}) { |
| 1087 async.Future<SignupUrl> create({core.String callbackUrl, core.String projectId
}) { | |
| 1088 var _url = null; | 1037 var _url = null; |
| 1089 var _queryParams = new core.Map(); | 1038 var _queryParams = new core.Map(); |
| 1090 var _uploadMedia = null; | 1039 var _uploadMedia = null; |
| 1091 var _uploadOptions = null; | 1040 var _uploadOptions = null; |
| 1092 var _downloadOptions = commons.DownloadOptions.Metadata; | 1041 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 1093 var _body = null; | 1042 var _body = null; |
| 1094 | 1043 |
| 1095 if (callbackUrl != null) { | 1044 if (callbackUrl != null) { |
| 1096 _queryParams["callbackUrl"] = [callbackUrl]; | 1045 _queryParams["callbackUrl"] = [callbackUrl]; |
| 1097 } | 1046 } |
| 1098 if (projectId != null) { | 1047 if (projectId != null) { |
| 1099 _queryParams["projectId"] = [projectId]; | 1048 _queryParams["projectId"] = [projectId]; |
| 1100 } | 1049 } |
| 1101 | 1050 |
| 1102 _url = 'v1/signupUrls'; | 1051 _url = 'v1/signupUrls'; |
| 1103 | 1052 |
| 1104 var _response = _requester.request(_url, | 1053 var _response = _requester.request(_url, "POST", |
| 1105 "POST", | 1054 body: _body, |
| 1106 body: _body, | 1055 queryParams: _queryParams, |
| 1107 queryParams: _queryParams, | 1056 uploadOptions: _uploadOptions, |
| 1108 uploadOptions: _uploadOptions, | 1057 uploadMedia: _uploadMedia, |
| 1109 uploadMedia: _uploadMedia, | 1058 downloadOptions: _downloadOptions); |
| 1110 downloadOptions: _downloadOptions); | |
| 1111 return _response.then((data) => new SignupUrl.fromJson(data)); | 1059 return _response.then((data) => new SignupUrl.fromJson(data)); |
| 1112 } | 1060 } |
| 1113 | |
| 1114 } | 1061 } |
| 1115 | 1062 |
| 1116 | 1063 /// A compliance rule condition which is satisfied if the Android Framework API |
| 1117 | 1064 /// level on the device does not meet a minimum requirement. There can only be |
| 1118 /** | 1065 /// one rule with this type of condition per policy. |
| 1119 * A compliance rule condition which is satisfied if the Android Framework API | |
| 1120 * level on the device does not meet a minimum requirement. There can only be | |
| 1121 * one rule with this type of condition per policy. | |
| 1122 */ | |
| 1123 class ApiLevelCondition { | 1066 class ApiLevelCondition { |
| 1124 /** | 1067 /// The minimum desired Android Framework API level. If the device does not |
| 1125 * The minimum desired Android Framework API level. If the device does not | 1068 /// meet the minimum requirement, this condition is satisfied. Must be |
| 1126 * meet the minimum requirement, this condition is satisfied. Must be greater | 1069 /// greater than zero. |
| 1127 * than zero. | |
| 1128 */ | |
| 1129 core.int minApiLevel; | 1070 core.int minApiLevel; |
| 1130 | 1071 |
| 1131 ApiLevelCondition(); | 1072 ApiLevelCondition(); |
| 1132 | 1073 |
| 1133 ApiLevelCondition.fromJson(core.Map _json) { | 1074 ApiLevelCondition.fromJson(core.Map _json) { |
| 1134 if (_json.containsKey("minApiLevel")) { | 1075 if (_json.containsKey("minApiLevel")) { |
| 1135 minApiLevel = _json["minApiLevel"]; | 1076 minApiLevel = _json["minApiLevel"]; |
| 1136 } | 1077 } |
| 1137 } | 1078 } |
| 1138 | 1079 |
| 1139 core.Map<core.String, core.Object> toJson() { | 1080 core.Map<core.String, core.Object> toJson() { |
| 1140 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1081 final core.Map<core.String, core.Object> _json = |
| 1082 new core.Map<core.String, core.Object>(); |
| 1141 if (minApiLevel != null) { | 1083 if (minApiLevel != null) { |
| 1142 _json["minApiLevel"] = minApiLevel; | 1084 _json["minApiLevel"] = minApiLevel; |
| 1143 } | 1085 } |
| 1144 return _json; | 1086 return _json; |
| 1145 } | 1087 } |
| 1146 } | 1088 } |
| 1147 | 1089 |
| 1148 /** Application information. */ | 1090 /// Application information. |
| 1149 class Application { | 1091 class Application { |
| 1150 /** | 1092 /// The set of managed properties available to be pre-configured for the |
| 1151 * The set of managed properties available to be pre-configured for the | 1093 /// application. |
| 1152 * application. | |
| 1153 */ | |
| 1154 core.List<ManagedProperty> managedProperties; | 1094 core.List<ManagedProperty> managedProperties; |
| 1155 /** | 1095 |
| 1156 * The name of the application in the form | 1096 /// The name of the application in the form |
| 1157 * enterprises/{enterpriseId}/applications/{package_name} | 1097 /// enterprises/{enterpriseId}/applications/{package_name} |
| 1158 */ | |
| 1159 core.String name; | 1098 core.String name; |
| 1160 /** The permissions required by the app. */ | 1099 |
| 1100 /// The permissions required by the app. |
| 1161 core.List<ApplicationPermission> permissions; | 1101 core.List<ApplicationPermission> permissions; |
| 1162 /** The title of the application. Localized. */ | 1102 |
| 1103 /// The title of the application. Localized. |
| 1163 core.String title; | 1104 core.String title; |
| 1164 | 1105 |
| 1165 Application(); | 1106 Application(); |
| 1166 | 1107 |
| 1167 Application.fromJson(core.Map _json) { | 1108 Application.fromJson(core.Map _json) { |
| 1168 if (_json.containsKey("managedProperties")) { | 1109 if (_json.containsKey("managedProperties")) { |
| 1169 managedProperties = _json["managedProperties"].map((value) => new ManagedP
roperty.fromJson(value)).toList(); | 1110 managedProperties = _json["managedProperties"] |
| 1111 .map((value) => new ManagedProperty.fromJson(value)) |
| 1112 .toList(); |
| 1170 } | 1113 } |
| 1171 if (_json.containsKey("name")) { | 1114 if (_json.containsKey("name")) { |
| 1172 name = _json["name"]; | 1115 name = _json["name"]; |
| 1173 } | 1116 } |
| 1174 if (_json.containsKey("permissions")) { | 1117 if (_json.containsKey("permissions")) { |
| 1175 permissions = _json["permissions"].map((value) => new ApplicationPermissio
n.fromJson(value)).toList(); | 1118 permissions = _json["permissions"] |
| 1119 .map((value) => new ApplicationPermission.fromJson(value)) |
| 1120 .toList(); |
| 1176 } | 1121 } |
| 1177 if (_json.containsKey("title")) { | 1122 if (_json.containsKey("title")) { |
| 1178 title = _json["title"]; | 1123 title = _json["title"]; |
| 1179 } | 1124 } |
| 1180 } | 1125 } |
| 1181 | 1126 |
| 1182 core.Map<core.String, core.Object> toJson() { | 1127 core.Map<core.String, core.Object> toJson() { |
| 1183 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1128 final core.Map<core.String, core.Object> _json = |
| 1129 new core.Map<core.String, core.Object>(); |
| 1184 if (managedProperties != null) { | 1130 if (managedProperties != null) { |
| 1185 _json["managedProperties"] = managedProperties.map((value) => (value).toJs
on()).toList(); | 1131 _json["managedProperties"] = |
| 1132 managedProperties.map((value) => (value).toJson()).toList(); |
| 1186 } | 1133 } |
| 1187 if (name != null) { | 1134 if (name != null) { |
| 1188 _json["name"] = name; | 1135 _json["name"] = name; |
| 1189 } | 1136 } |
| 1190 if (permissions != null) { | 1137 if (permissions != null) { |
| 1191 _json["permissions"] = permissions.map((value) => (value).toJson()).toList
(); | 1138 _json["permissions"] = |
| 1139 permissions.map((value) => (value).toJson()).toList(); |
| 1192 } | 1140 } |
| 1193 if (title != null) { | 1141 if (title != null) { |
| 1194 _json["title"] = title; | 1142 _json["title"] = title; |
| 1195 } | 1143 } |
| 1196 return _json; | 1144 return _json; |
| 1197 } | 1145 } |
| 1198 } | 1146 } |
| 1199 | 1147 |
| 1200 /** Application permission. */ | 1148 /// Application permission. |
| 1201 class ApplicationPermission { | 1149 class ApplicationPermission { |
| 1202 /** | 1150 /// A longer description of the permission, giving more details of what it |
| 1203 * A longer description of the permission, giving more details of what it | 1151 /// affects. Localized. |
| 1204 * affects. Localized. | |
| 1205 */ | |
| 1206 core.String description; | 1152 core.String description; |
| 1207 /** The name of the permission. Localized. */ | 1153 |
| 1154 /// The name of the permission. Localized. |
| 1208 core.String name; | 1155 core.String name; |
| 1209 /** An opaque string uniquely identifying the permission. Not localized. */ | 1156 |
| 1157 /// An opaque string uniquely identifying the permission. Not localized. |
| 1210 core.String permissionId; | 1158 core.String permissionId; |
| 1211 | 1159 |
| 1212 ApplicationPermission(); | 1160 ApplicationPermission(); |
| 1213 | 1161 |
| 1214 ApplicationPermission.fromJson(core.Map _json) { | 1162 ApplicationPermission.fromJson(core.Map _json) { |
| 1215 if (_json.containsKey("description")) { | 1163 if (_json.containsKey("description")) { |
| 1216 description = _json["description"]; | 1164 description = _json["description"]; |
| 1217 } | 1165 } |
| 1218 if (_json.containsKey("name")) { | 1166 if (_json.containsKey("name")) { |
| 1219 name = _json["name"]; | 1167 name = _json["name"]; |
| 1220 } | 1168 } |
| 1221 if (_json.containsKey("permissionId")) { | 1169 if (_json.containsKey("permissionId")) { |
| 1222 permissionId = _json["permissionId"]; | 1170 permissionId = _json["permissionId"]; |
| 1223 } | 1171 } |
| 1224 } | 1172 } |
| 1225 | 1173 |
| 1226 core.Map<core.String, core.Object> toJson() { | 1174 core.Map<core.String, core.Object> toJson() { |
| 1227 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1175 final core.Map<core.String, core.Object> _json = |
| 1176 new core.Map<core.String, core.Object>(); |
| 1228 if (description != null) { | 1177 if (description != null) { |
| 1229 _json["description"] = description; | 1178 _json["description"] = description; |
| 1230 } | 1179 } |
| 1231 if (name != null) { | 1180 if (name != null) { |
| 1232 _json["name"] = name; | 1181 _json["name"] = name; |
| 1233 } | 1182 } |
| 1234 if (permissionId != null) { | 1183 if (permissionId != null) { |
| 1235 _json["permissionId"] = permissionId; | 1184 _json["permissionId"] = permissionId; |
| 1236 } | 1185 } |
| 1237 return _json; | 1186 return _json; |
| 1238 } | 1187 } |
| 1239 } | 1188 } |
| 1240 | 1189 |
| 1241 /** Policy for an individual app. */ | 1190 /// Policy for an individual app. |
| 1242 class ApplicationPolicy { | 1191 class ApplicationPolicy { |
| 1243 /** | 1192 /// The default policy for all permissions requested by the app. If |
| 1244 * The default policy for all permissions requested by the app. If specified, | 1193 /// specified, this overrides the policy-level default_permission_policy |
| 1245 * this overrides the policy-level default_permission_policy which applies to | 1194 /// which applies to all apps. |
| 1246 * all apps. | 1195 /// Possible string values are: |
| 1247 * Possible string values are: | 1196 /// - "PERMISSION_POLICY_UNSPECIFIED" : Policy not specified. If no policy is |
| 1248 * - "PERMISSION_POLICY_UNSPECIFIED" : Policy not specified. If no policy is | 1197 /// specified for a permission at any level, then the PROMPT behavior is used |
| 1249 * specified for a permission at any level, then the PROMPT behavior is used | 1198 /// by default. |
| 1250 * by default. | 1199 /// - "PROMPT" : Prompt the user to grant a permission. |
| 1251 * - "PROMPT" : Prompt the user to grant a permission. | 1200 /// - "GRANT" : Automatically grant a permission. |
| 1252 * - "GRANT" : Automatically grant a permission. | 1201 /// - "DENY" : Automatically deny a permission. |
| 1253 * - "DENY" : Automatically deny a permission. | |
| 1254 */ | |
| 1255 core.String defaultPermissionPolicy; | 1202 core.String defaultPermissionPolicy; |
| 1256 /** | 1203 |
| 1257 * The type of installation to perform. | 1204 /// The type of installation to perform. |
| 1258 * Possible string values are: | 1205 /// Possible string values are: |
| 1259 * - "INSTALL_TYPE_UNSPECIFIED" : No automatic installation is performed. Any | 1206 /// - "INSTALL_TYPE_UNSPECIFIED" : No automatic installation is performed. |
| 1260 * other app policies will be applied if the user installs the app. | 1207 /// Any other app policies will be applied if the user installs the app. |
| 1261 * - "PREINSTALLED" : The application is automatically installed and can be | 1208 /// - "PREINSTALLED" : The application is automatically installed and can be |
| 1262 * removed by the user. | 1209 /// removed by the user. |
| 1263 * - "FORCE_INSTALLED" : The application is automatically installed and cannot | 1210 /// - "FORCE_INSTALLED" : The application is automatically installed and |
| 1264 * be removed by the user. | 1211 /// cannot be removed by the user. |
| 1265 */ | |
| 1266 core.String installType; | 1212 core.String installType; |
| 1267 /** Whether the application is allowed to lock itself in full-screen mode. */ | 1213 |
| 1214 /// Whether the application is allowed to lock itself in full-screen mode. |
| 1268 core.bool lockTaskAllowed; | 1215 core.bool lockTaskAllowed; |
| 1269 /** | 1216 |
| 1270 * Managed configuration applied to the app. The format for the configuration | 1217 /// Managed configuration applied to the app. The format for the |
| 1271 * is dictated by the ManagedProperty values supported by the app. Each field | 1218 /// configuration is dictated by the ManagedProperty values supported by the |
| 1272 * name in the managed configuration must match the key field of the | 1219 /// app. Each field name in the managed configuration must match the key |
| 1273 * ManagedProperty. The field value must be compatible with the type of the | 1220 /// field of the ManagedProperty. The field value must be compatible with the |
| 1274 * ManagedProperty: <table> <tr><td><i>type</i></td><td><i>JSON | 1221 /// type of the ManagedProperty: <table> <tr><td><i>type</i></td><td><i>JSON |
| 1275 * value</i></td></tr> <tr><td>BOOL</td><td>true or false</td></tr> | 1222 /// value</i></td></tr> <tr><td>BOOL</td><td>true or false</td></tr> |
| 1276 * <tr><td>STRING</td><td>string</td></tr> | 1223 /// <tr><td>STRING</td><td>string</td></tr> |
| 1277 * <tr><td>INTEGER</td><td>number</td></tr> | 1224 /// <tr><td>INTEGER</td><td>number</td></tr> |
| 1278 * <tr><td>CHOICE</td><td>string</td></tr> <tr><td>MULTISELECT</td><td>array | 1225 /// <tr><td>CHOICE</td><td>string</td></tr> <tr><td>MULTISELECT</td><td>array |
| 1279 * of strings</td></tr> <tr><td>HIDDEN</td><td>string</td></tr> | 1226 /// of strings</td></tr> <tr><td>HIDDEN</td><td>string</td></tr> |
| 1280 * <tr><td>BUNDLE_ARRAY</td><td>array of objects</td></tr> </table> | 1227 /// <tr><td>BUNDLE_ARRAY</td><td>array of objects</td></tr> </table> |
| 1281 * | 1228 /// |
| 1282 * The values for Object must be JSON objects. It can consist of `num`, | 1229 /// The values for Object must be JSON objects. It can consist of `num`, |
| 1283 * `String`, `bool` and `null` as well as `Map` and `List` values. | 1230 /// `String`, `bool` and `null` as well as `Map` and `List` values. |
| 1284 */ | |
| 1285 core.Map<core.String, core.Object> managedConfiguration; | 1231 core.Map<core.String, core.Object> managedConfiguration; |
| 1286 /** | 1232 |
| 1287 * The package name of the app, e.g. com.google.android.youtube for the | 1233 /// The package name of the app, e.g. com.google.android.youtube for the |
| 1288 * YouTube app. | 1234 /// YouTube app. |
| 1289 */ | |
| 1290 core.String packageName; | 1235 core.String packageName; |
| 1291 /** | 1236 |
| 1292 * Explicit permission grants or denials for the app. These values override | 1237 /// Explicit permission grants or denials for the app. These values override |
| 1293 * the default_permission_policy. | 1238 /// the default_permission_policy. |
| 1294 */ | |
| 1295 core.List<PermissionGrant> permissionGrants; | 1239 core.List<PermissionGrant> permissionGrants; |
| 1296 | 1240 |
| 1297 ApplicationPolicy(); | 1241 ApplicationPolicy(); |
| 1298 | 1242 |
| 1299 ApplicationPolicy.fromJson(core.Map _json) { | 1243 ApplicationPolicy.fromJson(core.Map _json) { |
| 1300 if (_json.containsKey("defaultPermissionPolicy")) { | 1244 if (_json.containsKey("defaultPermissionPolicy")) { |
| 1301 defaultPermissionPolicy = _json["defaultPermissionPolicy"]; | 1245 defaultPermissionPolicy = _json["defaultPermissionPolicy"]; |
| 1302 } | 1246 } |
| 1303 if (_json.containsKey("installType")) { | 1247 if (_json.containsKey("installType")) { |
| 1304 installType = _json["installType"]; | 1248 installType = _json["installType"]; |
| 1305 } | 1249 } |
| 1306 if (_json.containsKey("lockTaskAllowed")) { | 1250 if (_json.containsKey("lockTaskAllowed")) { |
| 1307 lockTaskAllowed = _json["lockTaskAllowed"]; | 1251 lockTaskAllowed = _json["lockTaskAllowed"]; |
| 1308 } | 1252 } |
| 1309 if (_json.containsKey("managedConfiguration")) { | 1253 if (_json.containsKey("managedConfiguration")) { |
| 1310 managedConfiguration = _json["managedConfiguration"]; | 1254 managedConfiguration = _json["managedConfiguration"]; |
| 1311 } | 1255 } |
| 1312 if (_json.containsKey("packageName")) { | 1256 if (_json.containsKey("packageName")) { |
| 1313 packageName = _json["packageName"]; | 1257 packageName = _json["packageName"]; |
| 1314 } | 1258 } |
| 1315 if (_json.containsKey("permissionGrants")) { | 1259 if (_json.containsKey("permissionGrants")) { |
| 1316 permissionGrants = _json["permissionGrants"].map((value) => new Permission
Grant.fromJson(value)).toList(); | 1260 permissionGrants = _json["permissionGrants"] |
| 1261 .map((value) => new PermissionGrant.fromJson(value)) |
| 1262 .toList(); |
| 1317 } | 1263 } |
| 1318 } | 1264 } |
| 1319 | 1265 |
| 1320 core.Map<core.String, core.Object> toJson() { | 1266 core.Map<core.String, core.Object> toJson() { |
| 1321 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1267 final core.Map<core.String, core.Object> _json = |
| 1268 new core.Map<core.String, core.Object>(); |
| 1322 if (defaultPermissionPolicy != null) { | 1269 if (defaultPermissionPolicy != null) { |
| 1323 _json["defaultPermissionPolicy"] = defaultPermissionPolicy; | 1270 _json["defaultPermissionPolicy"] = defaultPermissionPolicy; |
| 1324 } | 1271 } |
| 1325 if (installType != null) { | 1272 if (installType != null) { |
| 1326 _json["installType"] = installType; | 1273 _json["installType"] = installType; |
| 1327 } | 1274 } |
| 1328 if (lockTaskAllowed != null) { | 1275 if (lockTaskAllowed != null) { |
| 1329 _json["lockTaskAllowed"] = lockTaskAllowed; | 1276 _json["lockTaskAllowed"] = lockTaskAllowed; |
| 1330 } | 1277 } |
| 1331 if (managedConfiguration != null) { | 1278 if (managedConfiguration != null) { |
| 1332 _json["managedConfiguration"] = managedConfiguration; | 1279 _json["managedConfiguration"] = managedConfiguration; |
| 1333 } | 1280 } |
| 1334 if (packageName != null) { | 1281 if (packageName != null) { |
| 1335 _json["packageName"] = packageName; | 1282 _json["packageName"] = packageName; |
| 1336 } | 1283 } |
| 1337 if (permissionGrants != null) { | 1284 if (permissionGrants != null) { |
| 1338 _json["permissionGrants"] = permissionGrants.map((value) => (value).toJson
()).toList(); | 1285 _json["permissionGrants"] = |
| 1286 permissionGrants.map((value) => (value).toJson()).toList(); |
| 1339 } | 1287 } |
| 1340 return _json; | 1288 return _json; |
| 1341 } | 1289 } |
| 1342 } | 1290 } |
| 1343 | 1291 |
| 1344 /** A command. */ | 1292 /// A command. |
| 1345 class Command { | 1293 class Command { |
| 1346 /** | 1294 /// The timestamp at which the command was created. The timestamp is |
| 1347 * The timestamp at which the command was created. The timestamp is | 1295 /// automatically generated by the server. |
| 1348 * automatically generated by the server. | |
| 1349 */ | |
| 1350 core.String createTime; | 1296 core.String createTime; |
| 1351 /** | 1297 |
| 1352 * The duration for which the command is valid. The command will expire if not | 1298 /// The duration for which the command is valid. The command will expire if |
| 1353 * executed by the device during this time. The default duration if | 1299 /// not executed by the device during this time. The default duration if |
| 1354 * unspecified is ten minutes. There is no maximum duration. | 1300 /// unspecified is ten minutes. There is no maximum duration. |
| 1355 */ | |
| 1356 core.String duration; | 1301 core.String duration; |
| 1357 /** | 1302 |
| 1358 * For commands of type RESET_PASSWORD, optionally specifies the new password. | 1303 /// For commands of type RESET_PASSWORD, optionally specifies the new |
| 1359 */ | 1304 /// password. |
| 1360 core.String newPassword; | 1305 core.String newPassword; |
| 1361 /** For commands of type RESET_PASSWORD, optionally specifies flags. */ | 1306 |
| 1307 /// For commands of type RESET_PASSWORD, optionally specifies flags. |
| 1362 core.List<core.String> resetPasswordFlags; | 1308 core.List<core.String> resetPasswordFlags; |
| 1363 /** | 1309 |
| 1364 * The type of the command. | 1310 /// The type of the command. |
| 1365 * Possible string values are: | 1311 /// Possible string values are: |
| 1366 * - "COMMAND_TYPE_UNSPECIFIED" : This value is disallowed. | 1312 /// - "COMMAND_TYPE_UNSPECIFIED" : This value is disallowed. |
| 1367 * - "LOCK" : Lock the device, as if the lock screen timeout had expired. | 1313 /// - "LOCK" : Lock the device, as if the lock screen timeout had expired. |
| 1368 * - "RESET_PASSWORD" : Reset the user's password. | 1314 /// - "RESET_PASSWORD" : Reset the user's password. |
| 1369 * - "REBOOT" : Reboot the device. Only supported on API level 24+. | 1315 /// - "REBOOT" : Reboot the device. Only supported on API level 24+. |
| 1370 */ | |
| 1371 core.String type; | 1316 core.String type; |
| 1372 | 1317 |
| 1373 Command(); | 1318 Command(); |
| 1374 | 1319 |
| 1375 Command.fromJson(core.Map _json) { | 1320 Command.fromJson(core.Map _json) { |
| 1376 if (_json.containsKey("createTime")) { | 1321 if (_json.containsKey("createTime")) { |
| 1377 createTime = _json["createTime"]; | 1322 createTime = _json["createTime"]; |
| 1378 } | 1323 } |
| 1379 if (_json.containsKey("duration")) { | 1324 if (_json.containsKey("duration")) { |
| 1380 duration = _json["duration"]; | 1325 duration = _json["duration"]; |
| 1381 } | 1326 } |
| 1382 if (_json.containsKey("newPassword")) { | 1327 if (_json.containsKey("newPassword")) { |
| 1383 newPassword = _json["newPassword"]; | 1328 newPassword = _json["newPassword"]; |
| 1384 } | 1329 } |
| 1385 if (_json.containsKey("resetPasswordFlags")) { | 1330 if (_json.containsKey("resetPasswordFlags")) { |
| 1386 resetPasswordFlags = _json["resetPasswordFlags"]; | 1331 resetPasswordFlags = _json["resetPasswordFlags"]; |
| 1387 } | 1332 } |
| 1388 if (_json.containsKey("type")) { | 1333 if (_json.containsKey("type")) { |
| 1389 type = _json["type"]; | 1334 type = _json["type"]; |
| 1390 } | 1335 } |
| 1391 } | 1336 } |
| 1392 | 1337 |
| 1393 core.Map<core.String, core.Object> toJson() { | 1338 core.Map<core.String, core.Object> toJson() { |
| 1394 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1339 final core.Map<core.String, core.Object> _json = |
| 1340 new core.Map<core.String, core.Object>(); |
| 1395 if (createTime != null) { | 1341 if (createTime != null) { |
| 1396 _json["createTime"] = createTime; | 1342 _json["createTime"] = createTime; |
| 1397 } | 1343 } |
| 1398 if (duration != null) { | 1344 if (duration != null) { |
| 1399 _json["duration"] = duration; | 1345 _json["duration"] = duration; |
| 1400 } | 1346 } |
| 1401 if (newPassword != null) { | 1347 if (newPassword != null) { |
| 1402 _json["newPassword"] = newPassword; | 1348 _json["newPassword"] = newPassword; |
| 1403 } | 1349 } |
| 1404 if (resetPasswordFlags != null) { | 1350 if (resetPasswordFlags != null) { |
| 1405 _json["resetPasswordFlags"] = resetPasswordFlags; | 1351 _json["resetPasswordFlags"] = resetPasswordFlags; |
| 1406 } | 1352 } |
| 1407 if (type != null) { | 1353 if (type != null) { |
| 1408 _json["type"] = type; | 1354 _json["type"] = type; |
| 1409 } | 1355 } |
| 1410 return _json; | 1356 return _json; |
| 1411 } | 1357 } |
| 1412 } | 1358 } |
| 1413 | 1359 |
| 1414 /** | 1360 /// A rule declaring which mitigating actions to take when a device is not |
| 1415 * A rule declaring which mitigating actions to take when a device is not | 1361 /// compliant with its policy. For every rule, there is always an implicit |
| 1416 * compliant with its policy. For every rule, there is always an implicit | 1362 /// mitigating action to set policy_compliant to false for the Device resource, |
| 1417 * mitigating action to set policy_compliant to false for the Device resource, | 1363 /// and display a message on the device indicating that the device is not |
| 1418 * and display a message on the device indicating that the device is not | 1364 /// compliant with its policy. Other mitigating actions may optionally be taken |
| 1419 * compliant with its policy. Other mitigating actions may optionally be taken | 1365 /// as well, depending on the field values in the rule. |
| 1420 * as well, depending on the field values in the rule. | |
| 1421 */ | |
| 1422 class ComplianceRule { | 1366 class ComplianceRule { |
| 1423 /** | 1367 /// A condition which is satisfied if the Android Framework API level on the |
| 1424 * A condition which is satisfied if the Android Framework API level on the | 1368 /// device does not meet a minimum requirement. |
| 1425 * device does not meet a minimum requirement. | |
| 1426 */ | |
| 1427 ApiLevelCondition apiLevelCondition; | 1369 ApiLevelCondition apiLevelCondition; |
| 1428 /** | 1370 |
| 1429 * If set to true, the rule includes a mitigating action to disable | 1371 /// If set to true, the rule includes a mitigating action to disable |
| 1430 * applications so that the device is effectively disabled, but application | 1372 /// applications so that the device is effectively disabled, but application |
| 1431 * data is preserved. If the device is running an app in locked task mode, the | 1373 /// data is preserved. If the device is running an app in locked task mode, |
| 1432 * app will be closed and a UI showing the reason for non-compliance will be | 1374 /// the app will be closed and a UI showing the reason for non-compliance |
| 1433 * displayed. | 1375 /// will be displayed. |
| 1434 */ | |
| 1435 core.bool disableApps; | 1376 core.bool disableApps; |
| 1436 /** | 1377 |
| 1437 * A condition which is satisfied if there exists any matching | 1378 /// A condition which is satisfied if there exists any matching |
| 1438 * NonComplianceDetail for the device. | 1379 /// NonComplianceDetail for the device. |
| 1439 */ | |
| 1440 NonComplianceDetailCondition nonComplianceDetailCondition; | 1380 NonComplianceDetailCondition nonComplianceDetailCondition; |
| 1441 | 1381 |
| 1442 ComplianceRule(); | 1382 ComplianceRule(); |
| 1443 | 1383 |
| 1444 ComplianceRule.fromJson(core.Map _json) { | 1384 ComplianceRule.fromJson(core.Map _json) { |
| 1445 if (_json.containsKey("apiLevelCondition")) { | 1385 if (_json.containsKey("apiLevelCondition")) { |
| 1446 apiLevelCondition = new ApiLevelCondition.fromJson(_json["apiLevelConditio
n"]); | 1386 apiLevelCondition = |
| 1387 new ApiLevelCondition.fromJson(_json["apiLevelCondition"]); |
| 1447 } | 1388 } |
| 1448 if (_json.containsKey("disableApps")) { | 1389 if (_json.containsKey("disableApps")) { |
| 1449 disableApps = _json["disableApps"]; | 1390 disableApps = _json["disableApps"]; |
| 1450 } | 1391 } |
| 1451 if (_json.containsKey("nonComplianceDetailCondition")) { | 1392 if (_json.containsKey("nonComplianceDetailCondition")) { |
| 1452 nonComplianceDetailCondition = new NonComplianceDetailCondition.fromJson(_
json["nonComplianceDetailCondition"]); | 1393 nonComplianceDetailCondition = new NonComplianceDetailCondition.fromJson( |
| 1394 _json["nonComplianceDetailCondition"]); |
| 1453 } | 1395 } |
| 1454 } | 1396 } |
| 1455 | 1397 |
| 1456 core.Map<core.String, core.Object> toJson() { | 1398 core.Map<core.String, core.Object> toJson() { |
| 1457 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1399 final core.Map<core.String, core.Object> _json = |
| 1400 new core.Map<core.String, core.Object>(); |
| 1458 if (apiLevelCondition != null) { | 1401 if (apiLevelCondition != null) { |
| 1459 _json["apiLevelCondition"] = (apiLevelCondition).toJson(); | 1402 _json["apiLevelCondition"] = (apiLevelCondition).toJson(); |
| 1460 } | 1403 } |
| 1461 if (disableApps != null) { | 1404 if (disableApps != null) { |
| 1462 _json["disableApps"] = disableApps; | 1405 _json["disableApps"] = disableApps; |
| 1463 } | 1406 } |
| 1464 if (nonComplianceDetailCondition != null) { | 1407 if (nonComplianceDetailCondition != null) { |
| 1465 _json["nonComplianceDetailCondition"] = (nonComplianceDetailCondition).toJ
son(); | 1408 _json["nonComplianceDetailCondition"] = |
| 1409 (nonComplianceDetailCondition).toJson(); |
| 1466 } | 1410 } |
| 1467 return _json; | 1411 return _json; |
| 1468 } | 1412 } |
| 1469 } | 1413 } |
| 1470 | 1414 |
| 1471 /** | 1415 /// A device owned by an enterprise. Unless otherwise noted, all fields are |
| 1472 * A device owned by an enterprise. Unless otherwise noted, all fields are | 1416 /// read-only and cannot be modified by an update device request. |
| 1473 * read-only and cannot be modified by an update device request. | |
| 1474 */ | |
| 1475 class Device { | 1417 class Device { |
| 1476 /** The API level of the Android platform version running on the device. */ | 1418 /// The API level of the Android platform version running on the device. |
| 1477 core.int apiLevel; | 1419 core.int apiLevel; |
| 1478 /** The name of the policy that is currently applied by the device. */ | 1420 |
| 1421 /// The name of the policy that is currently applied by the device. |
| 1479 core.String appliedPolicyName; | 1422 core.String appliedPolicyName; |
| 1480 /** The version of the policy that is currently applied by the device. */ | 1423 |
| 1424 /// The version of the policy that is currently applied by the device. |
| 1481 core.String appliedPolicyVersion; | 1425 core.String appliedPolicyVersion; |
| 1482 /** | 1426 |
| 1483 * The state that is currently applied by the device. | 1427 /// The state that is currently applied by the device. |
| 1484 * Possible string values are: | 1428 /// Possible string values are: |
| 1485 * - "DEVICE_STATE_UNSPECIFIED" : This value is disallowed. | 1429 /// - "DEVICE_STATE_UNSPECIFIED" : This value is disallowed. |
| 1486 * - "ACTIVE" : The device is active. | 1430 /// - "ACTIVE" : The device is active. |
| 1487 * - "DISABLED" : The device is disabled. | 1431 /// - "DISABLED" : The device is disabled. |
| 1488 * - "DELETED" : The device was deleted. This state will never be returned by | 1432 /// - "DELETED" : The device was deleted. This state will never be returned |
| 1489 * an API call, but will be used in the final policy compliance report | 1433 /// by an API call, but will be used in the final policy compliance report |
| 1490 * published to Cloud Pub/Sub when the device acknowledges the deletion. | 1434 /// published to Cloud Pub/Sub when the device acknowledges the deletion. |
| 1491 * - "PROVISIONING" : The device is being provisioned. Newly enrolled devices | 1435 /// - "PROVISIONING" : The device is being provisioned. Newly enrolled |
| 1492 * will be in this state until they have applied policy. | 1436 /// devices will be in this state until they have applied policy. |
| 1493 */ | |
| 1494 core.String appliedState; | 1437 core.String appliedState; |
| 1495 /** | 1438 |
| 1496 * If the device state is DISABLED, an optional message that is displayed on | 1439 /// If the device state is DISABLED, an optional message that is displayed on |
| 1497 * the device indicating the reason the device is disabled. This field may be | 1440 /// the device indicating the reason the device is disabled. This field may |
| 1498 * modified by an update request. | 1441 /// be modified by an update request. |
| 1499 */ | |
| 1500 UserFacingMessage disabledReason; | 1442 UserFacingMessage disabledReason; |
| 1501 /** | 1443 |
| 1502 * Displays on the device. This information is only available when | 1444 /// Displays on the device. This information is only available when |
| 1503 * displayInfoEnabled is true in the device's policy. | 1445 /// displayInfoEnabled is true in the device's policy. |
| 1504 */ | |
| 1505 core.List<Display> displays; | 1446 core.List<Display> displays; |
| 1506 /** The time of device enrollment. */ | 1447 |
| 1448 /// The time of device enrollment. |
| 1507 core.String enrollmentTime; | 1449 core.String enrollmentTime; |
| 1508 /** | 1450 |
| 1509 * If this device was enrolled with an enrollment token with additional data | 1451 /// If this device was enrolled with an enrollment token with additional data |
| 1510 * provided, this field contains that data. | 1452 /// provided, this field contains that data. |
| 1511 */ | |
| 1512 core.String enrollmentTokenData; | 1453 core.String enrollmentTokenData; |
| 1513 /** | 1454 |
| 1514 * If this device was enrolled with an enrollment token, this field contains | 1455 /// If this device was enrolled with an enrollment token, this field contains |
| 1515 * the name of the token. | 1456 /// the name of the token. |
| 1516 */ | |
| 1517 core.String enrollmentTokenName; | 1457 core.String enrollmentTokenName; |
| 1518 /** Detailed information about the device hardware. */ | 1458 |
| 1459 /// Detailed information about the device hardware. |
| 1519 HardwareInfo hardwareInfo; | 1460 HardwareInfo hardwareInfo; |
| 1520 /** | 1461 |
| 1521 * Hardware status samples in chronological order. This information is only | 1462 /// Hardware status samples in chronological order. This information is only |
| 1522 * available when hardwareStatusEnabled is true in the device's policy. | 1463 /// available when hardwareStatusEnabled is true in the device's policy. |
| 1523 */ | |
| 1524 core.List<HardwareStatus> hardwareStatusSamples; | 1464 core.List<HardwareStatus> hardwareStatusSamples; |
| 1525 /** The last time the device sent a policy compliance report. */ | 1465 |
| 1466 /// The last time the device sent a policy compliance report. |
| 1526 core.String lastPolicyComplianceReportTime; | 1467 core.String lastPolicyComplianceReportTime; |
| 1527 /** The last time the device fetched its policy. */ | 1468 |
| 1469 /// The last time the device fetched its policy. |
| 1528 core.String lastPolicySyncTime; | 1470 core.String lastPolicySyncTime; |
| 1529 /** The last time the device sent a status report. */ | 1471 |
| 1472 /// The last time the device sent a status report. |
| 1530 core.String lastStatusReportTime; | 1473 core.String lastStatusReportTime; |
| 1531 /** | 1474 |
| 1532 * Events related to memory and storage measurements in chronological order. | 1475 /// Events related to memory and storage measurements in chronological order. |
| 1533 * This information is only available when memoryInfoEnabled is true in the | 1476 /// This information is only available when memoryInfoEnabled is true in the |
| 1534 * device's policy. | 1477 /// device's policy. |
| 1535 */ | |
| 1536 core.List<MemoryEvent> memoryEvents; | 1478 core.List<MemoryEvent> memoryEvents; |
| 1537 /** | 1479 |
| 1538 * Memory information. This information is only available when | 1480 /// Memory information. This information is only available when |
| 1539 * memoryInfoEnabled is true in the device's policy. | 1481 /// memoryInfoEnabled is true in the device's policy. |
| 1540 */ | |
| 1541 MemoryInfo memoryInfo; | 1482 MemoryInfo memoryInfo; |
| 1542 /** | 1483 |
| 1543 * The name of the device in the form | 1484 /// The name of the device in the form |
| 1544 * enterprises/{enterpriseId}/devices/{deviceId} | 1485 /// enterprises/{enterpriseId}/devices/{deviceId} |
| 1545 */ | |
| 1546 core.String name; | 1486 core.String name; |
| 1547 /** | 1487 |
| 1548 * Device network information. This information is only available when | 1488 /// Device network information. This information is only available when |
| 1549 * networkInfoEnabled is true in the device's policy. | 1489 /// networkInfoEnabled is true in the device's policy. |
| 1550 */ | |
| 1551 NetworkInfo networkInfo; | 1490 NetworkInfo networkInfo; |
| 1552 /** | 1491 |
| 1553 * Details about policy settings for which the device is not in compliance. | 1492 /// Details about policy settings for which the device is not in compliance. |
| 1554 */ | |
| 1555 core.List<NonComplianceDetail> nonComplianceDetails; | 1493 core.List<NonComplianceDetail> nonComplianceDetails; |
| 1556 /** Whether the device is compliant with its policy. */ | 1494 |
| 1495 /// Whether the device is compliant with its policy. |
| 1557 core.bool policyCompliant; | 1496 core.bool policyCompliant; |
| 1558 /** | 1497 |
| 1559 * The name of the policy that is intended to be applied to the device. If | 1498 /// The name of the policy that is intended to be applied to the device. If |
| 1560 * empty, the policy with id default is applied. This field may be modified by | 1499 /// empty, the policy with id default is applied. This field may be modified |
| 1561 * an update request. The name of the policy is in the form | 1500 /// by an update request. The name of the policy is in the form |
| 1562 * enterprises/{enterpriseId}/policies/{policyId}. It is also permissible to | 1501 /// enterprises/{enterpriseId}/policies/{policyId}. It is also permissible to |
| 1563 * only specify the policyId when updating this field as long as the policyId | 1502 /// only specify the policyId when updating this field as long as the |
| 1564 * contains no slashes since the rest of the policy name can be inferred from | 1503 /// policyId contains no slashes since the rest of the policy name can be |
| 1565 * context. | 1504 /// inferred from context. |
| 1566 */ | |
| 1567 core.String policyName; | 1505 core.String policyName; |
| 1568 /** | 1506 |
| 1569 * Power management events on the device in chronological order. This | 1507 /// Power management events on the device in chronological order. This |
| 1570 * information is only available when powerManagementEventsEnabled is true in | 1508 /// information is only available when powerManagementEventsEnabled is true |
| 1571 * the device's policy. | 1509 /// in the device's policy. |
| 1572 */ | |
| 1573 core.List<PowerManagementEvent> powerManagementEvents; | 1510 core.List<PowerManagementEvent> powerManagementEvents; |
| 1574 /** | 1511 |
| 1575 * The previous device names used for the same physical device when it has | 1512 /// The previous device names used for the same physical device when it has |
| 1576 * been enrolled multiple times. The serial number is used as the unique | 1513 /// been enrolled multiple times. The serial number is used as the unique |
| 1577 * identifier to determine if the same physical device has enrolled | 1514 /// identifier to determine if the same physical device has enrolled |
| 1578 * previously. The names are in chronological order. | 1515 /// previously. The names are in chronological order. |
| 1579 */ | |
| 1580 core.List<core.String> previousDeviceNames; | 1516 core.List<core.String> previousDeviceNames; |
| 1581 /** | 1517 |
| 1582 * Detailed information about the device software. This information is only | 1518 /// Detailed information about the device software. This information is only |
| 1583 * available when softwareInfoEnabled is true in the device's policy. | 1519 /// available when softwareInfoEnabled is true in the device's policy. |
| 1584 */ | |
| 1585 SoftwareInfo softwareInfo; | 1520 SoftwareInfo softwareInfo; |
| 1586 /** | 1521 |
| 1587 * The state that is intended to be applied to the device. This field may be | 1522 /// The state that is intended to be applied to the device. This field may be |
| 1588 * modified by an update request. Note that UpdateDevice only handles toggling | 1523 /// modified by an update request. Note that UpdateDevice only handles |
| 1589 * between ACTIVE and DISABLED states. Use the delete device method to cause | 1524 /// toggling between ACTIVE and DISABLED states. Use the delete device method |
| 1590 * the device to enter the DELETED state. | 1525 /// to cause the device to enter the DELETED state. |
| 1591 * Possible string values are: | 1526 /// Possible string values are: |
| 1592 * - "DEVICE_STATE_UNSPECIFIED" : This value is disallowed. | 1527 /// - "DEVICE_STATE_UNSPECIFIED" : This value is disallowed. |
| 1593 * - "ACTIVE" : The device is active. | 1528 /// - "ACTIVE" : The device is active. |
| 1594 * - "DISABLED" : The device is disabled. | 1529 /// - "DISABLED" : The device is disabled. |
| 1595 * - "DELETED" : The device was deleted. This state will never be returned by | 1530 /// - "DELETED" : The device was deleted. This state will never be returned |
| 1596 * an API call, but will be used in the final policy compliance report | 1531 /// by an API call, but will be used in the final policy compliance report |
| 1597 * published to Cloud Pub/Sub when the device acknowledges the deletion. | 1532 /// published to Cloud Pub/Sub when the device acknowledges the deletion. |
| 1598 * - "PROVISIONING" : The device is being provisioned. Newly enrolled devices | 1533 /// - "PROVISIONING" : The device is being provisioned. Newly enrolled |
| 1599 * will be in this state until they have applied policy. | 1534 /// devices will be in this state until they have applied policy. |
| 1600 */ | |
| 1601 core.String state; | 1535 core.String state; |
| 1602 /** | 1536 |
| 1603 * The resource name of the user of the device in the form | 1537 /// The resource name of the user of the device in the form |
| 1604 * enterprises/{enterpriseId}/users/{userId}. This is the name of the device | 1538 /// enterprises/{enterpriseId}/users/{userId}. This is the name of the device |
| 1605 * account automatically created for this device. | 1539 /// account automatically created for this device. |
| 1606 */ | |
| 1607 core.String userName; | 1540 core.String userName; |
| 1608 | 1541 |
| 1609 Device(); | 1542 Device(); |
| 1610 | 1543 |
| 1611 Device.fromJson(core.Map _json) { | 1544 Device.fromJson(core.Map _json) { |
| 1612 if (_json.containsKey("apiLevel")) { | 1545 if (_json.containsKey("apiLevel")) { |
| 1613 apiLevel = _json["apiLevel"]; | 1546 apiLevel = _json["apiLevel"]; |
| 1614 } | 1547 } |
| 1615 if (_json.containsKey("appliedPolicyName")) { | 1548 if (_json.containsKey("appliedPolicyName")) { |
| 1616 appliedPolicyName = _json["appliedPolicyName"]; | 1549 appliedPolicyName = _json["appliedPolicyName"]; |
| 1617 } | 1550 } |
| 1618 if (_json.containsKey("appliedPolicyVersion")) { | 1551 if (_json.containsKey("appliedPolicyVersion")) { |
| 1619 appliedPolicyVersion = _json["appliedPolicyVersion"]; | 1552 appliedPolicyVersion = _json["appliedPolicyVersion"]; |
| 1620 } | 1553 } |
| 1621 if (_json.containsKey("appliedState")) { | 1554 if (_json.containsKey("appliedState")) { |
| 1622 appliedState = _json["appliedState"]; | 1555 appliedState = _json["appliedState"]; |
| 1623 } | 1556 } |
| 1624 if (_json.containsKey("disabledReason")) { | 1557 if (_json.containsKey("disabledReason")) { |
| 1625 disabledReason = new UserFacingMessage.fromJson(_json["disabledReason"]); | 1558 disabledReason = new UserFacingMessage.fromJson(_json["disabledReason"]); |
| 1626 } | 1559 } |
| 1627 if (_json.containsKey("displays")) { | 1560 if (_json.containsKey("displays")) { |
| 1628 displays = _json["displays"].map((value) => new Display.fromJson(value)).t
oList(); | 1561 displays = _json["displays"] |
| 1562 .map((value) => new Display.fromJson(value)) |
| 1563 .toList(); |
| 1629 } | 1564 } |
| 1630 if (_json.containsKey("enrollmentTime")) { | 1565 if (_json.containsKey("enrollmentTime")) { |
| 1631 enrollmentTime = _json["enrollmentTime"]; | 1566 enrollmentTime = _json["enrollmentTime"]; |
| 1632 } | 1567 } |
| 1633 if (_json.containsKey("enrollmentTokenData")) { | 1568 if (_json.containsKey("enrollmentTokenData")) { |
| 1634 enrollmentTokenData = _json["enrollmentTokenData"]; | 1569 enrollmentTokenData = _json["enrollmentTokenData"]; |
| 1635 } | 1570 } |
| 1636 if (_json.containsKey("enrollmentTokenName")) { | 1571 if (_json.containsKey("enrollmentTokenName")) { |
| 1637 enrollmentTokenName = _json["enrollmentTokenName"]; | 1572 enrollmentTokenName = _json["enrollmentTokenName"]; |
| 1638 } | 1573 } |
| 1639 if (_json.containsKey("hardwareInfo")) { | 1574 if (_json.containsKey("hardwareInfo")) { |
| 1640 hardwareInfo = new HardwareInfo.fromJson(_json["hardwareInfo"]); | 1575 hardwareInfo = new HardwareInfo.fromJson(_json["hardwareInfo"]); |
| 1641 } | 1576 } |
| 1642 if (_json.containsKey("hardwareStatusSamples")) { | 1577 if (_json.containsKey("hardwareStatusSamples")) { |
| 1643 hardwareStatusSamples = _json["hardwareStatusSamples"].map((value) => new
HardwareStatus.fromJson(value)).toList(); | 1578 hardwareStatusSamples = _json["hardwareStatusSamples"] |
| 1579 .map((value) => new HardwareStatus.fromJson(value)) |
| 1580 .toList(); |
| 1644 } | 1581 } |
| 1645 if (_json.containsKey("lastPolicyComplianceReportTime")) { | 1582 if (_json.containsKey("lastPolicyComplianceReportTime")) { |
| 1646 lastPolicyComplianceReportTime = _json["lastPolicyComplianceReportTime"]; | 1583 lastPolicyComplianceReportTime = _json["lastPolicyComplianceReportTime"]; |
| 1647 } | 1584 } |
| 1648 if (_json.containsKey("lastPolicySyncTime")) { | 1585 if (_json.containsKey("lastPolicySyncTime")) { |
| 1649 lastPolicySyncTime = _json["lastPolicySyncTime"]; | 1586 lastPolicySyncTime = _json["lastPolicySyncTime"]; |
| 1650 } | 1587 } |
| 1651 if (_json.containsKey("lastStatusReportTime")) { | 1588 if (_json.containsKey("lastStatusReportTime")) { |
| 1652 lastStatusReportTime = _json["lastStatusReportTime"]; | 1589 lastStatusReportTime = _json["lastStatusReportTime"]; |
| 1653 } | 1590 } |
| 1654 if (_json.containsKey("memoryEvents")) { | 1591 if (_json.containsKey("memoryEvents")) { |
| 1655 memoryEvents = _json["memoryEvents"].map((value) => new MemoryEvent.fromJs
on(value)).toList(); | 1592 memoryEvents = _json["memoryEvents"] |
| 1593 .map((value) => new MemoryEvent.fromJson(value)) |
| 1594 .toList(); |
| 1656 } | 1595 } |
| 1657 if (_json.containsKey("memoryInfo")) { | 1596 if (_json.containsKey("memoryInfo")) { |
| 1658 memoryInfo = new MemoryInfo.fromJson(_json["memoryInfo"]); | 1597 memoryInfo = new MemoryInfo.fromJson(_json["memoryInfo"]); |
| 1659 } | 1598 } |
| 1660 if (_json.containsKey("name")) { | 1599 if (_json.containsKey("name")) { |
| 1661 name = _json["name"]; | 1600 name = _json["name"]; |
| 1662 } | 1601 } |
| 1663 if (_json.containsKey("networkInfo")) { | 1602 if (_json.containsKey("networkInfo")) { |
| 1664 networkInfo = new NetworkInfo.fromJson(_json["networkInfo"]); | 1603 networkInfo = new NetworkInfo.fromJson(_json["networkInfo"]); |
| 1665 } | 1604 } |
| 1666 if (_json.containsKey("nonComplianceDetails")) { | 1605 if (_json.containsKey("nonComplianceDetails")) { |
| 1667 nonComplianceDetails = _json["nonComplianceDetails"].map((value) => new No
nComplianceDetail.fromJson(value)).toList(); | 1606 nonComplianceDetails = _json["nonComplianceDetails"] |
| 1607 .map((value) => new NonComplianceDetail.fromJson(value)) |
| 1608 .toList(); |
| 1668 } | 1609 } |
| 1669 if (_json.containsKey("policyCompliant")) { | 1610 if (_json.containsKey("policyCompliant")) { |
| 1670 policyCompliant = _json["policyCompliant"]; | 1611 policyCompliant = _json["policyCompliant"]; |
| 1671 } | 1612 } |
| 1672 if (_json.containsKey("policyName")) { | 1613 if (_json.containsKey("policyName")) { |
| 1673 policyName = _json["policyName"]; | 1614 policyName = _json["policyName"]; |
| 1674 } | 1615 } |
| 1675 if (_json.containsKey("powerManagementEvents")) { | 1616 if (_json.containsKey("powerManagementEvents")) { |
| 1676 powerManagementEvents = _json["powerManagementEvents"].map((value) => new
PowerManagementEvent.fromJson(value)).toList(); | 1617 powerManagementEvents = _json["powerManagementEvents"] |
| 1618 .map((value) => new PowerManagementEvent.fromJson(value)) |
| 1619 .toList(); |
| 1677 } | 1620 } |
| 1678 if (_json.containsKey("previousDeviceNames")) { | 1621 if (_json.containsKey("previousDeviceNames")) { |
| 1679 previousDeviceNames = _json["previousDeviceNames"]; | 1622 previousDeviceNames = _json["previousDeviceNames"]; |
| 1680 } | 1623 } |
| 1681 if (_json.containsKey("softwareInfo")) { | 1624 if (_json.containsKey("softwareInfo")) { |
| 1682 softwareInfo = new SoftwareInfo.fromJson(_json["softwareInfo"]); | 1625 softwareInfo = new SoftwareInfo.fromJson(_json["softwareInfo"]); |
| 1683 } | 1626 } |
| 1684 if (_json.containsKey("state")) { | 1627 if (_json.containsKey("state")) { |
| 1685 state = _json["state"]; | 1628 state = _json["state"]; |
| 1686 } | 1629 } |
| 1687 if (_json.containsKey("userName")) { | 1630 if (_json.containsKey("userName")) { |
| 1688 userName = _json["userName"]; | 1631 userName = _json["userName"]; |
| 1689 } | 1632 } |
| 1690 } | 1633 } |
| 1691 | 1634 |
| 1692 core.Map<core.String, core.Object> toJson() { | 1635 core.Map<core.String, core.Object> toJson() { |
| 1693 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1636 final core.Map<core.String, core.Object> _json = |
| 1637 new core.Map<core.String, core.Object>(); |
| 1694 if (apiLevel != null) { | 1638 if (apiLevel != null) { |
| 1695 _json["apiLevel"] = apiLevel; | 1639 _json["apiLevel"] = apiLevel; |
| 1696 } | 1640 } |
| 1697 if (appliedPolicyName != null) { | 1641 if (appliedPolicyName != null) { |
| 1698 _json["appliedPolicyName"] = appliedPolicyName; | 1642 _json["appliedPolicyName"] = appliedPolicyName; |
| 1699 } | 1643 } |
| 1700 if (appliedPolicyVersion != null) { | 1644 if (appliedPolicyVersion != null) { |
| 1701 _json["appliedPolicyVersion"] = appliedPolicyVersion; | 1645 _json["appliedPolicyVersion"] = appliedPolicyVersion; |
| 1702 } | 1646 } |
| 1703 if (appliedState != null) { | 1647 if (appliedState != null) { |
| (...skipping 11 matching lines...) Expand all Loading... |
| 1715 if (enrollmentTokenData != null) { | 1659 if (enrollmentTokenData != null) { |
| 1716 _json["enrollmentTokenData"] = enrollmentTokenData; | 1660 _json["enrollmentTokenData"] = enrollmentTokenData; |
| 1717 } | 1661 } |
| 1718 if (enrollmentTokenName != null) { | 1662 if (enrollmentTokenName != null) { |
| 1719 _json["enrollmentTokenName"] = enrollmentTokenName; | 1663 _json["enrollmentTokenName"] = enrollmentTokenName; |
| 1720 } | 1664 } |
| 1721 if (hardwareInfo != null) { | 1665 if (hardwareInfo != null) { |
| 1722 _json["hardwareInfo"] = (hardwareInfo).toJson(); | 1666 _json["hardwareInfo"] = (hardwareInfo).toJson(); |
| 1723 } | 1667 } |
| 1724 if (hardwareStatusSamples != null) { | 1668 if (hardwareStatusSamples != null) { |
| 1725 _json["hardwareStatusSamples"] = hardwareStatusSamples.map((value) => (val
ue).toJson()).toList(); | 1669 _json["hardwareStatusSamples"] = |
| 1670 hardwareStatusSamples.map((value) => (value).toJson()).toList(); |
| 1726 } | 1671 } |
| 1727 if (lastPolicyComplianceReportTime != null) { | 1672 if (lastPolicyComplianceReportTime != null) { |
| 1728 _json["lastPolicyComplianceReportTime"] = lastPolicyComplianceReportTime; | 1673 _json["lastPolicyComplianceReportTime"] = lastPolicyComplianceReportTime; |
| 1729 } | 1674 } |
| 1730 if (lastPolicySyncTime != null) { | 1675 if (lastPolicySyncTime != null) { |
| 1731 _json["lastPolicySyncTime"] = lastPolicySyncTime; | 1676 _json["lastPolicySyncTime"] = lastPolicySyncTime; |
| 1732 } | 1677 } |
| 1733 if (lastStatusReportTime != null) { | 1678 if (lastStatusReportTime != null) { |
| 1734 _json["lastStatusReportTime"] = lastStatusReportTime; | 1679 _json["lastStatusReportTime"] = lastStatusReportTime; |
| 1735 } | 1680 } |
| 1736 if (memoryEvents != null) { | 1681 if (memoryEvents != null) { |
| 1737 _json["memoryEvents"] = memoryEvents.map((value) => (value).toJson()).toLi
st(); | 1682 _json["memoryEvents"] = |
| 1683 memoryEvents.map((value) => (value).toJson()).toList(); |
| 1738 } | 1684 } |
| 1739 if (memoryInfo != null) { | 1685 if (memoryInfo != null) { |
| 1740 _json["memoryInfo"] = (memoryInfo).toJson(); | 1686 _json["memoryInfo"] = (memoryInfo).toJson(); |
| 1741 } | 1687 } |
| 1742 if (name != null) { | 1688 if (name != null) { |
| 1743 _json["name"] = name; | 1689 _json["name"] = name; |
| 1744 } | 1690 } |
| 1745 if (networkInfo != null) { | 1691 if (networkInfo != null) { |
| 1746 _json["networkInfo"] = (networkInfo).toJson(); | 1692 _json["networkInfo"] = (networkInfo).toJson(); |
| 1747 } | 1693 } |
| 1748 if (nonComplianceDetails != null) { | 1694 if (nonComplianceDetails != null) { |
| 1749 _json["nonComplianceDetails"] = nonComplianceDetails.map((value) => (value
).toJson()).toList(); | 1695 _json["nonComplianceDetails"] = |
| 1696 nonComplianceDetails.map((value) => (value).toJson()).toList(); |
| 1750 } | 1697 } |
| 1751 if (policyCompliant != null) { | 1698 if (policyCompliant != null) { |
| 1752 _json["policyCompliant"] = policyCompliant; | 1699 _json["policyCompliant"] = policyCompliant; |
| 1753 } | 1700 } |
| 1754 if (policyName != null) { | 1701 if (policyName != null) { |
| 1755 _json["policyName"] = policyName; | 1702 _json["policyName"] = policyName; |
| 1756 } | 1703 } |
| 1757 if (powerManagementEvents != null) { | 1704 if (powerManagementEvents != null) { |
| 1758 _json["powerManagementEvents"] = powerManagementEvents.map((value) => (val
ue).toJson()).toList(); | 1705 _json["powerManagementEvents"] = |
| 1706 powerManagementEvents.map((value) => (value).toJson()).toList(); |
| 1759 } | 1707 } |
| 1760 if (previousDeviceNames != null) { | 1708 if (previousDeviceNames != null) { |
| 1761 _json["previousDeviceNames"] = previousDeviceNames; | 1709 _json["previousDeviceNames"] = previousDeviceNames; |
| 1762 } | 1710 } |
| 1763 if (softwareInfo != null) { | 1711 if (softwareInfo != null) { |
| 1764 _json["softwareInfo"] = (softwareInfo).toJson(); | 1712 _json["softwareInfo"] = (softwareInfo).toJson(); |
| 1765 } | 1713 } |
| 1766 if (state != null) { | 1714 if (state != null) { |
| 1767 _json["state"] = state; | 1715 _json["state"] = state; |
| 1768 } | 1716 } |
| 1769 if (userName != null) { | 1717 if (userName != null) { |
| 1770 _json["userName"] = userName; | 1718 _json["userName"] = userName; |
| 1771 } | 1719 } |
| 1772 return _json; | 1720 return _json; |
| 1773 } | 1721 } |
| 1774 } | 1722 } |
| 1775 | 1723 |
| 1776 /** Device display information. */ | 1724 /// Device display information. |
| 1777 class Display { | 1725 class Display { |
| 1778 /** Display density expressed as dots-per-inch. */ | 1726 /// Display density expressed as dots-per-inch. |
| 1779 core.int density; | 1727 core.int density; |
| 1780 /** Unique display id. */ | 1728 |
| 1729 /// Unique display id. |
| 1781 core.int displayId; | 1730 core.int displayId; |
| 1782 /** Display height in pixels. */ | 1731 |
| 1732 /// Display height in pixels. |
| 1783 core.int height; | 1733 core.int height; |
| 1784 /** Name of the display. */ | 1734 |
| 1735 /// Name of the display. |
| 1785 core.String name; | 1736 core.String name; |
| 1786 /** Refresh rate of the display in frames per second. */ | 1737 |
| 1738 /// Refresh rate of the display in frames per second. |
| 1787 core.int refreshRate; | 1739 core.int refreshRate; |
| 1788 /** | 1740 |
| 1789 * State of the display. | 1741 /// State of the display. |
| 1790 * Possible string values are: | 1742 /// Possible string values are: |
| 1791 * - "DISPLAY_STATE_UNSPECIFIED" : This value is disallowed. | 1743 /// - "DISPLAY_STATE_UNSPECIFIED" : This value is disallowed. |
| 1792 * - "OFF" : Display is off. | 1744 /// - "OFF" : Display is off. |
| 1793 * - "ON" : Display is on. | 1745 /// - "ON" : Display is on. |
| 1794 * - "DOZE" : Display is dozing in a low power state | 1746 /// - "DOZE" : Display is dozing in a low power state |
| 1795 * - "SUSPENDED" : Display is dozing in a suspended low power state. | 1747 /// - "SUSPENDED" : Display is dozing in a suspended low power state. |
| 1796 */ | |
| 1797 core.String state; | 1748 core.String state; |
| 1798 /** Display width in pixels. */ | 1749 |
| 1750 /// Display width in pixels. |
| 1799 core.int width; | 1751 core.int width; |
| 1800 | 1752 |
| 1801 Display(); | 1753 Display(); |
| 1802 | 1754 |
| 1803 Display.fromJson(core.Map _json) { | 1755 Display.fromJson(core.Map _json) { |
| 1804 if (_json.containsKey("density")) { | 1756 if (_json.containsKey("density")) { |
| 1805 density = _json["density"]; | 1757 density = _json["density"]; |
| 1806 } | 1758 } |
| 1807 if (_json.containsKey("displayId")) { | 1759 if (_json.containsKey("displayId")) { |
| 1808 displayId = _json["displayId"]; | 1760 displayId = _json["displayId"]; |
| 1809 } | 1761 } |
| 1810 if (_json.containsKey("height")) { | 1762 if (_json.containsKey("height")) { |
| 1811 height = _json["height"]; | 1763 height = _json["height"]; |
| 1812 } | 1764 } |
| 1813 if (_json.containsKey("name")) { | 1765 if (_json.containsKey("name")) { |
| 1814 name = _json["name"]; | 1766 name = _json["name"]; |
| 1815 } | 1767 } |
| 1816 if (_json.containsKey("refreshRate")) { | 1768 if (_json.containsKey("refreshRate")) { |
| 1817 refreshRate = _json["refreshRate"]; | 1769 refreshRate = _json["refreshRate"]; |
| 1818 } | 1770 } |
| 1819 if (_json.containsKey("state")) { | 1771 if (_json.containsKey("state")) { |
| 1820 state = _json["state"]; | 1772 state = _json["state"]; |
| 1821 } | 1773 } |
| 1822 if (_json.containsKey("width")) { | 1774 if (_json.containsKey("width")) { |
| 1823 width = _json["width"]; | 1775 width = _json["width"]; |
| 1824 } | 1776 } |
| 1825 } | 1777 } |
| 1826 | 1778 |
| 1827 core.Map<core.String, core.Object> toJson() { | 1779 core.Map<core.String, core.Object> toJson() { |
| 1828 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1780 final core.Map<core.String, core.Object> _json = |
| 1781 new core.Map<core.String, core.Object>(); |
| 1829 if (density != null) { | 1782 if (density != null) { |
| 1830 _json["density"] = density; | 1783 _json["density"] = density; |
| 1831 } | 1784 } |
| 1832 if (displayId != null) { | 1785 if (displayId != null) { |
| 1833 _json["displayId"] = displayId; | 1786 _json["displayId"] = displayId; |
| 1834 } | 1787 } |
| 1835 if (height != null) { | 1788 if (height != null) { |
| 1836 _json["height"] = height; | 1789 _json["height"] = height; |
| 1837 } | 1790 } |
| 1838 if (name != null) { | 1791 if (name != null) { |
| 1839 _json["name"] = name; | 1792 _json["name"] = name; |
| 1840 } | 1793 } |
| 1841 if (refreshRate != null) { | 1794 if (refreshRate != null) { |
| 1842 _json["refreshRate"] = refreshRate; | 1795 _json["refreshRate"] = refreshRate; |
| 1843 } | 1796 } |
| 1844 if (state != null) { | 1797 if (state != null) { |
| 1845 _json["state"] = state; | 1798 _json["state"] = state; |
| 1846 } | 1799 } |
| 1847 if (width != null) { | 1800 if (width != null) { |
| 1848 _json["width"] = width; | 1801 _json["width"] = width; |
| 1849 } | 1802 } |
| 1850 return _json; | 1803 return _json; |
| 1851 } | 1804 } |
| 1852 } | 1805 } |
| 1853 | 1806 |
| 1854 /** | 1807 /// A generic empty message that you can re-use to avoid defining duplicated |
| 1855 * A generic empty message that you can re-use to avoid defining duplicated | 1808 /// empty messages in your APIs. A typical example is to use it as the request |
| 1856 * empty messages in your APIs. A typical example is to use it as the request or | 1809 /// or the response type of an API method. For instance: |
| 1857 * the response type of an API method. For instance: | 1810 /// service Foo { |
| 1858 * service Foo { | 1811 /// rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); |
| 1859 * rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); | 1812 /// } |
| 1860 * } | 1813 /// The JSON representation for Empty is empty JSON object {}. |
| 1861 * The JSON representation for Empty is empty JSON object {}. | |
| 1862 */ | |
| 1863 class Empty { | 1814 class Empty { |
| 1864 | |
| 1865 Empty(); | 1815 Empty(); |
| 1866 | 1816 |
| 1867 Empty.fromJson(core.Map _json) { | 1817 Empty.fromJson(core.Map _json) {} |
| 1868 } | |
| 1869 | 1818 |
| 1870 core.Map<core.String, core.Object> toJson() { | 1819 core.Map<core.String, core.Object> toJson() { |
| 1871 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1820 final core.Map<core.String, core.Object> _json = |
| 1821 new core.Map<core.String, core.Object>(); |
| 1872 return _json; | 1822 return _json; |
| 1873 } | 1823 } |
| 1874 } | 1824 } |
| 1875 | 1825 |
| 1876 /** An enrollment token. */ | 1826 /// An enrollment token. |
| 1877 class EnrollmentToken { | 1827 class EnrollmentToken { |
| 1878 /** | 1828 /// Optional, arbitrary data associated with the enrollment token. This could |
| 1879 * Optional, arbitrary data associated with the enrollment token. This could | 1829 /// contain, for example, the id of an org unit to which the device is |
| 1880 * contain, for example, the id of an org unit to which the device is assigned | 1830 /// assigned after enrollment. After a device enrolls with the token, this |
| 1881 * after enrollment. After a device enrolls with the token, this data will be | 1831 /// data will be exposed in the enrollment_token_data field of the Device |
| 1882 * exposed in the enrollment_token_data field of the Device resource. The data | 1832 /// resource. The data must be 1024 characters or less; otherwise, the |
| 1883 * must be 1024 characters or less; otherwise, the creation request will fail. | 1833 /// creation request will fail. |
| 1884 */ | |
| 1885 core.String additionalData; | 1834 core.String additionalData; |
| 1886 /** | 1835 |
| 1887 * The duration of the token. If not specified, the duration will be 1 hour. | 1836 /// The duration of the token. If not specified, the duration will be 1 hour. |
| 1888 * The allowed range is 1 minute to 30 days. | 1837 /// The allowed range is 1 minute to 30 days. |
| 1889 */ | |
| 1890 core.String duration; | 1838 core.String duration; |
| 1891 /** | 1839 |
| 1892 * The expiration time of the token. This is a read-only field generated by | 1840 /// The expiration time of the token. This is a read-only field generated by |
| 1893 * the server. | 1841 /// the server. |
| 1894 */ | |
| 1895 core.String expirationTimestamp; | 1842 core.String expirationTimestamp; |
| 1896 /** | 1843 |
| 1897 * The name of the enrollment token, which is generated by the server during | 1844 /// The name of the enrollment token, which is generated by the server during |
| 1898 * creation, in the form | 1845 /// creation, in the form |
| 1899 * enterprises/{enterpriseId}/enrollmentTokens/{enrollmentTokenId} | 1846 /// enterprises/{enterpriseId}/enrollmentTokens/{enrollmentTokenId} |
| 1900 */ | |
| 1901 core.String name; | 1847 core.String name; |
| 1902 /** | 1848 |
| 1903 * The name of the policy that will be initially applied to the enrolled | 1849 /// The name of the policy that will be initially applied to the enrolled |
| 1904 * device in the form enterprises/{enterpriseId}/policies/{policyId}. If not | 1850 /// device in the form enterprises/{enterpriseId}/policies/{policyId}. If not |
| 1905 * specified, the policy with id default is applied. It is permissible to only | 1851 /// specified, the policy with id default is applied. It is permissible to |
| 1906 * specify the policyId when updating this field as long as the policyId | 1852 /// only specify the policyId when updating this field as long as the |
| 1907 * contains no slashes since the rest of the policy name can be inferred from | 1853 /// policyId contains no slashes since the rest of the policy name can be |
| 1908 * context. | 1854 /// inferred from context. |
| 1909 */ | |
| 1910 core.String policyName; | 1855 core.String policyName; |
| 1911 /** | 1856 |
| 1912 * A JSON string whose UTF-8 representation can be used to generate a QR code | 1857 /// A JSON string whose UTF-8 representation can be used to generate a QR |
| 1913 * to enroll a device with this enrollment token. To enroll a device using | 1858 /// code to enroll a device with this enrollment token. To enroll a device |
| 1914 * NFC, the NFC record must contain a serialized java.util.Properties | 1859 /// using NFC, the NFC record must contain a serialized java.util.Properties |
| 1915 * representation of the properties in the JSON. | 1860 /// representation of the properties in the JSON. |
| 1916 */ | |
| 1917 core.String qrCode; | 1861 core.String qrCode; |
| 1918 /** | 1862 |
| 1919 * The token value which is passed to the device and authorizes the device to | 1863 /// The token value which is passed to the device and authorizes the device |
| 1920 * enroll. This is a read-only field generated by the server. | 1864 /// to enroll. This is a read-only field generated by the server. |
| 1921 */ | |
| 1922 core.String value; | 1865 core.String value; |
| 1923 | 1866 |
| 1924 EnrollmentToken(); | 1867 EnrollmentToken(); |
| 1925 | 1868 |
| 1926 EnrollmentToken.fromJson(core.Map _json) { | 1869 EnrollmentToken.fromJson(core.Map _json) { |
| 1927 if (_json.containsKey("additionalData")) { | 1870 if (_json.containsKey("additionalData")) { |
| 1928 additionalData = _json["additionalData"]; | 1871 additionalData = _json["additionalData"]; |
| 1929 } | 1872 } |
| 1930 if (_json.containsKey("duration")) { | 1873 if (_json.containsKey("duration")) { |
| 1931 duration = _json["duration"]; | 1874 duration = _json["duration"]; |
| 1932 } | 1875 } |
| 1933 if (_json.containsKey("expirationTimestamp")) { | 1876 if (_json.containsKey("expirationTimestamp")) { |
| 1934 expirationTimestamp = _json["expirationTimestamp"]; | 1877 expirationTimestamp = _json["expirationTimestamp"]; |
| 1935 } | 1878 } |
| 1936 if (_json.containsKey("name")) { | 1879 if (_json.containsKey("name")) { |
| 1937 name = _json["name"]; | 1880 name = _json["name"]; |
| 1938 } | 1881 } |
| 1939 if (_json.containsKey("policyName")) { | 1882 if (_json.containsKey("policyName")) { |
| 1940 policyName = _json["policyName"]; | 1883 policyName = _json["policyName"]; |
| 1941 } | 1884 } |
| 1942 if (_json.containsKey("qrCode")) { | 1885 if (_json.containsKey("qrCode")) { |
| 1943 qrCode = _json["qrCode"]; | 1886 qrCode = _json["qrCode"]; |
| 1944 } | 1887 } |
| 1945 if (_json.containsKey("value")) { | 1888 if (_json.containsKey("value")) { |
| 1946 value = _json["value"]; | 1889 value = _json["value"]; |
| 1947 } | 1890 } |
| 1948 } | 1891 } |
| 1949 | 1892 |
| 1950 core.Map<core.String, core.Object> toJson() { | 1893 core.Map<core.String, core.Object> toJson() { |
| 1951 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1894 final core.Map<core.String, core.Object> _json = |
| 1895 new core.Map<core.String, core.Object>(); |
| 1952 if (additionalData != null) { | 1896 if (additionalData != null) { |
| 1953 _json["additionalData"] = additionalData; | 1897 _json["additionalData"] = additionalData; |
| 1954 } | 1898 } |
| 1955 if (duration != null) { | 1899 if (duration != null) { |
| 1956 _json["duration"] = duration; | 1900 _json["duration"] = duration; |
| 1957 } | 1901 } |
| 1958 if (expirationTimestamp != null) { | 1902 if (expirationTimestamp != null) { |
| 1959 _json["expirationTimestamp"] = expirationTimestamp; | 1903 _json["expirationTimestamp"] = expirationTimestamp; |
| 1960 } | 1904 } |
| 1961 if (name != null) { | 1905 if (name != null) { |
| 1962 _json["name"] = name; | 1906 _json["name"] = name; |
| 1963 } | 1907 } |
| 1964 if (policyName != null) { | 1908 if (policyName != null) { |
| 1965 _json["policyName"] = policyName; | 1909 _json["policyName"] = policyName; |
| 1966 } | 1910 } |
| 1967 if (qrCode != null) { | 1911 if (qrCode != null) { |
| 1968 _json["qrCode"] = qrCode; | 1912 _json["qrCode"] = qrCode; |
| 1969 } | 1913 } |
| 1970 if (value != null) { | 1914 if (value != null) { |
| 1971 _json["value"] = value; | 1915 _json["value"] = value; |
| 1972 } | 1916 } |
| 1973 return _json; | 1917 return _json; |
| 1974 } | 1918 } |
| 1975 } | 1919 } |
| 1976 | 1920 |
| 1977 /** The configuration applied to an enterprise. */ | 1921 /// The configuration applied to an enterprise. |
| 1978 class Enterprise { | 1922 class Enterprise { |
| 1979 /** | 1923 /// Whether app auto-approval is enabled. When enabled, apps installed via |
| 1980 * Whether app auto-approval is enabled. When enabled, apps installed via | 1924 /// policy for this enterprise have all permissions automatically approved. |
| 1981 * policy for this enterprise have all permissions automatically approved. | 1925 /// When enabled, it is the caller's responsibility to display the |
| 1982 * When enabled, it is the caller's responsibility to display the permissions | 1926 /// permissions required by an app to the enterprise admin before setting the |
| 1983 * required by an app to the enterprise admin before setting the app to be | 1927 /// app to be installed in a policy. |
| 1984 * installed in a policy. | |
| 1985 */ | |
| 1986 core.bool appAutoApprovalEnabled; | 1928 core.bool appAutoApprovalEnabled; |
| 1987 /** The notification types to enable via Google Cloud Pub/Sub. */ | 1929 |
| 1930 /// The notification types to enable via Google Cloud Pub/Sub. |
| 1988 core.List<core.String> enabledNotificationTypes; | 1931 core.List<core.String> enabledNotificationTypes; |
| 1989 /** The name of the enterprise as it will appear to users. */ | 1932 |
| 1933 /// The name of the enterprise as it will appear to users. |
| 1990 core.String enterpriseDisplayName; | 1934 core.String enterpriseDisplayName; |
| 1991 /** | 1935 |
| 1992 * An image displayed as a logo during device provisioning. Supported types | 1936 /// An image displayed as a logo during device provisioning. Supported types |
| 1993 * are: image/bmp, image/gif, image/x-ico, image/jpeg, image/png, image/webp, | 1937 /// are: image/bmp, image/gif, image/x-ico, image/jpeg, image/png, |
| 1994 * image/vnd.wap.wbmp, image/x-adobe-dng. | 1938 /// image/webp, image/vnd.wap.wbmp, image/x-adobe-dng. |
| 1995 */ | |
| 1996 ExternalData logo; | 1939 ExternalData logo; |
| 1997 /** | 1940 |
| 1998 * The name of the enterprise which is generated by the server during | 1941 /// The name of the enterprise which is generated by the server during |
| 1999 * creation, in the form enterprises/{enterpriseId} | 1942 /// creation, in the form enterprises/{enterpriseId} |
| 2000 */ | |
| 2001 core.String name; | 1943 core.String name; |
| 2002 /** | 1944 |
| 2003 * A color in RGB format indicating the predominant color to display in the | 1945 /// A color in RGB format indicating the predominant color to display in the |
| 2004 * device management app UI. The color components are stored as follows: (red | 1946 /// device management app UI. The color components are stored as follows: |
| 2005 * << 16) | (green << 8) | blue, where each component may take a value between | 1947 /// (red << 16) | (green << 8) | blue, where each component may take a value |
| 2006 * 0 and 255 inclusive. | 1948 /// between 0 and 255 inclusive. |
| 2007 */ | |
| 2008 core.int primaryColor; | 1949 core.int primaryColor; |
| 2009 /** | 1950 |
| 2010 * When Cloud Pub/Sub notifications are enabled, this field is required to | 1951 /// When Cloud Pub/Sub notifications are enabled, this field is required to |
| 2011 * indicate the topic to which the notifications will be published. The format | 1952 /// indicate the topic to which the notifications will be published. The |
| 2012 * of this field is projects/{project}/topics/{topic}. You must have granted | 1953 /// format of this field is projects/{project}/topics/{topic}. You must have |
| 2013 * the publish permission on this topic to | 1954 /// granted the publish permission on this topic to |
| 2014 * android-cloud-policy@system.gserviceaccount.com | 1955 /// android-cloud-policy@system.gserviceaccount.com |
| 2015 */ | |
| 2016 core.String pubsubTopic; | 1956 core.String pubsubTopic; |
| 2017 | 1957 |
| 2018 Enterprise(); | 1958 Enterprise(); |
| 2019 | 1959 |
| 2020 Enterprise.fromJson(core.Map _json) { | 1960 Enterprise.fromJson(core.Map _json) { |
| 2021 if (_json.containsKey("appAutoApprovalEnabled")) { | 1961 if (_json.containsKey("appAutoApprovalEnabled")) { |
| 2022 appAutoApprovalEnabled = _json["appAutoApprovalEnabled"]; | 1962 appAutoApprovalEnabled = _json["appAutoApprovalEnabled"]; |
| 2023 } | 1963 } |
| 2024 if (_json.containsKey("enabledNotificationTypes")) { | 1964 if (_json.containsKey("enabledNotificationTypes")) { |
| 2025 enabledNotificationTypes = _json["enabledNotificationTypes"]; | 1965 enabledNotificationTypes = _json["enabledNotificationTypes"]; |
| 2026 } | 1966 } |
| 2027 if (_json.containsKey("enterpriseDisplayName")) { | 1967 if (_json.containsKey("enterpriseDisplayName")) { |
| 2028 enterpriseDisplayName = _json["enterpriseDisplayName"]; | 1968 enterpriseDisplayName = _json["enterpriseDisplayName"]; |
| 2029 } | 1969 } |
| 2030 if (_json.containsKey("logo")) { | 1970 if (_json.containsKey("logo")) { |
| 2031 logo = new ExternalData.fromJson(_json["logo"]); | 1971 logo = new ExternalData.fromJson(_json["logo"]); |
| 2032 } | 1972 } |
| 2033 if (_json.containsKey("name")) { | 1973 if (_json.containsKey("name")) { |
| 2034 name = _json["name"]; | 1974 name = _json["name"]; |
| 2035 } | 1975 } |
| 2036 if (_json.containsKey("primaryColor")) { | 1976 if (_json.containsKey("primaryColor")) { |
| 2037 primaryColor = _json["primaryColor"]; | 1977 primaryColor = _json["primaryColor"]; |
| 2038 } | 1978 } |
| 2039 if (_json.containsKey("pubsubTopic")) { | 1979 if (_json.containsKey("pubsubTopic")) { |
| 2040 pubsubTopic = _json["pubsubTopic"]; | 1980 pubsubTopic = _json["pubsubTopic"]; |
| 2041 } | 1981 } |
| 2042 } | 1982 } |
| 2043 | 1983 |
| 2044 core.Map<core.String, core.Object> toJson() { | 1984 core.Map<core.String, core.Object> toJson() { |
| 2045 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1985 final core.Map<core.String, core.Object> _json = |
| 1986 new core.Map<core.String, core.Object>(); |
| 2046 if (appAutoApprovalEnabled != null) { | 1987 if (appAutoApprovalEnabled != null) { |
| 2047 _json["appAutoApprovalEnabled"] = appAutoApprovalEnabled; | 1988 _json["appAutoApprovalEnabled"] = appAutoApprovalEnabled; |
| 2048 } | 1989 } |
| 2049 if (enabledNotificationTypes != null) { | 1990 if (enabledNotificationTypes != null) { |
| 2050 _json["enabledNotificationTypes"] = enabledNotificationTypes; | 1991 _json["enabledNotificationTypes"] = enabledNotificationTypes; |
| 2051 } | 1992 } |
| 2052 if (enterpriseDisplayName != null) { | 1993 if (enterpriseDisplayName != null) { |
| 2053 _json["enterpriseDisplayName"] = enterpriseDisplayName; | 1994 _json["enterpriseDisplayName"] = enterpriseDisplayName; |
| 2054 } | 1995 } |
| 2055 if (logo != null) { | 1996 if (logo != null) { |
| 2056 _json["logo"] = (logo).toJson(); | 1997 _json["logo"] = (logo).toJson(); |
| 2057 } | 1998 } |
| 2058 if (name != null) { | 1999 if (name != null) { |
| 2059 _json["name"] = name; | 2000 _json["name"] = name; |
| 2060 } | 2001 } |
| 2061 if (primaryColor != null) { | 2002 if (primaryColor != null) { |
| 2062 _json["primaryColor"] = primaryColor; | 2003 _json["primaryColor"] = primaryColor; |
| 2063 } | 2004 } |
| 2064 if (pubsubTopic != null) { | 2005 if (pubsubTopic != null) { |
| 2065 _json["pubsubTopic"] = pubsubTopic; | 2006 _json["pubsubTopic"] = pubsubTopic; |
| 2066 } | 2007 } |
| 2067 return _json; | 2008 return _json; |
| 2068 } | 2009 } |
| 2069 } | 2010 } |
| 2070 | 2011 |
| 2071 /** | 2012 /// Data hosted at an external location. The data is to be downloaded by |
| 2072 * Data hosted at an external location. The data is to be downloaded by Android | 2013 /// Android Device Policy and verified against the hash. |
| 2073 * Device Policy and verified against the hash. | |
| 2074 */ | |
| 2075 class ExternalData { | 2014 class ExternalData { |
| 2076 /** | 2015 /// The base-64 encoded SHA-256 hash of the content hosted at url. If the |
| 2077 * The base-64 encoded SHA-256 hash of the content hosted at url. If the | 2016 /// content does not match this hash, Android Device Policy will not use the |
| 2078 * content does not match this hash, Android Device Policy will not use the | 2017 /// data. |
| 2079 * data. | |
| 2080 */ | |
| 2081 core.String sha256Hash; | 2018 core.String sha256Hash; |
| 2082 /** | 2019 |
| 2083 * The absolute URL to the data, which must use either the http or https | 2020 /// The absolute URL to the data, which must use either the http or https |
| 2084 * scheme. Android Device Policy does not provide any credentials in the GET | 2021 /// scheme. Android Device Policy does not provide any credentials in the GET |
| 2085 * request, so the URL must be publicly accessible. Including a long, random | 2022 /// request, so the URL must be publicly accessible. Including a long, random |
| 2086 * component in the URL may be used to prevent attackers from discovering the | 2023 /// component in the URL may be used to prevent attackers from discovering |
| 2087 * URL. | 2024 /// the URL. |
| 2088 */ | |
| 2089 core.String url; | 2025 core.String url; |
| 2090 | 2026 |
| 2091 ExternalData(); | 2027 ExternalData(); |
| 2092 | 2028 |
| 2093 ExternalData.fromJson(core.Map _json) { | 2029 ExternalData.fromJson(core.Map _json) { |
| 2094 if (_json.containsKey("sha256Hash")) { | 2030 if (_json.containsKey("sha256Hash")) { |
| 2095 sha256Hash = _json["sha256Hash"]; | 2031 sha256Hash = _json["sha256Hash"]; |
| 2096 } | 2032 } |
| 2097 if (_json.containsKey("url")) { | 2033 if (_json.containsKey("url")) { |
| 2098 url = _json["url"]; | 2034 url = _json["url"]; |
| 2099 } | 2035 } |
| 2100 } | 2036 } |
| 2101 | 2037 |
| 2102 core.Map<core.String, core.Object> toJson() { | 2038 core.Map<core.String, core.Object> toJson() { |
| 2103 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2039 final core.Map<core.String, core.Object> _json = |
| 2040 new core.Map<core.String, core.Object>(); |
| 2104 if (sha256Hash != null) { | 2041 if (sha256Hash != null) { |
| 2105 _json["sha256Hash"] = sha256Hash; | 2042 _json["sha256Hash"] = sha256Hash; |
| 2106 } | 2043 } |
| 2107 if (url != null) { | 2044 if (url != null) { |
| 2108 _json["url"] = url; | 2045 _json["url"] = url; |
| 2109 } | 2046 } |
| 2110 return _json; | 2047 return _json; |
| 2111 } | 2048 } |
| 2112 } | 2049 } |
| 2113 | 2050 |
| 2114 /** | 2051 /// Information about device hardware. The fields related to temperature |
| 2115 * Information about device hardware. The fields related to temperature | 2052 /// thresholds are only available when hardwareStatusEnabled is true in the |
| 2116 * thresholds are only available when hardwareStatusEnabled is true in the | 2053 /// device's policy. |
| 2117 * device's policy. | |
| 2118 */ | |
| 2119 class HardwareInfo { | 2054 class HardwareInfo { |
| 2120 /** | 2055 /// Battery shutdown temperature thresholds in Celsius for each battery on |
| 2121 * Battery shutdown temperature thresholds in Celsius for each battery on the | 2056 /// the device. |
| 2122 * device. | |
| 2123 */ | |
| 2124 core.List<core.double> batteryShutdownTemperatures; | 2057 core.List<core.double> batteryShutdownTemperatures; |
| 2125 /** | 2058 |
| 2126 * Battery throttling temperature thresholds in Celsius for each battery on | 2059 /// Battery throttling temperature thresholds in Celsius for each battery on |
| 2127 * the device. | 2060 /// the device. |
| 2128 */ | |
| 2129 core.List<core.double> batteryThrottlingTemperatures; | 2061 core.List<core.double> batteryThrottlingTemperatures; |
| 2130 /** Brand of the device, e.g. Google. */ | 2062 |
| 2063 /// Brand of the device, e.g. Google. |
| 2131 core.String brand; | 2064 core.String brand; |
| 2132 /** | 2065 |
| 2133 * CPU shutdown temperature thresholds in Celsius for each CPU on the device. | 2066 /// CPU shutdown temperature thresholds in Celsius for each CPU on the |
| 2134 */ | 2067 /// device. |
| 2135 core.List<core.double> cpuShutdownTemperatures; | 2068 core.List<core.double> cpuShutdownTemperatures; |
| 2136 /** | 2069 |
| 2137 * CPU throttling temperature thresholds in Celsius for each CPU on the | 2070 /// CPU throttling temperature thresholds in Celsius for each CPU on the |
| 2138 * device. | 2071 /// device. |
| 2139 */ | |
| 2140 core.List<core.double> cpuThrottlingTemperatures; | 2072 core.List<core.double> cpuThrottlingTemperatures; |
| 2141 /** Baseband version, e.g. MDM9625_104662.22.05.34p. */ | 2073 |
| 2074 /// Baseband version, e.g. MDM9625_104662.22.05.34p. |
| 2142 core.String deviceBasebandVersion; | 2075 core.String deviceBasebandVersion; |
| 2143 /** | 2076 |
| 2144 * GPU shutdown temperature thresholds in Celsius for each GPU on the device. | 2077 /// GPU shutdown temperature thresholds in Celsius for each GPU on the |
| 2145 */ | 2078 /// device. |
| 2146 core.List<core.double> gpuShutdownTemperatures; | 2079 core.List<core.double> gpuShutdownTemperatures; |
| 2147 /** | 2080 |
| 2148 * GPU throttling temperature thresholds in Celsius for each GPU on the | 2081 /// GPU throttling temperature thresholds in Celsius for each GPU on the |
| 2149 * device. | 2082 /// device. |
| 2150 */ | |
| 2151 core.List<core.double> gpuThrottlingTemperatures; | 2083 core.List<core.double> gpuThrottlingTemperatures; |
| 2152 /** Name of the hardware, e.g. Angler. */ | 2084 |
| 2085 /// Name of the hardware, e.g. Angler. |
| 2153 core.String hardware; | 2086 core.String hardware; |
| 2154 /** Manufacturer, e.g. Motorola. */ | 2087 |
| 2088 /// Manufacturer, e.g. Motorola. |
| 2155 core.String manufacturer; | 2089 core.String manufacturer; |
| 2156 /** The model of the device, e.g. Asus Nexus 7. */ | 2090 |
| 2091 /// The model of the device, e.g. Asus Nexus 7. |
| 2157 core.String model; | 2092 core.String model; |
| 2158 /** The device serial number. */ | 2093 |
| 2094 /// The device serial number. |
| 2159 core.String serialNumber; | 2095 core.String serialNumber; |
| 2160 /** Device skin shutdown temperature thresholds in Celsius. */ | 2096 |
| 2097 /// Device skin shutdown temperature thresholds in Celsius. |
| 2161 core.List<core.double> skinShutdownTemperatures; | 2098 core.List<core.double> skinShutdownTemperatures; |
| 2162 /** Device skin throttling temperature thresholds in Celsius. */ | 2099 |
| 2100 /// Device skin throttling temperature thresholds in Celsius. |
| 2163 core.List<core.double> skinThrottlingTemperatures; | 2101 core.List<core.double> skinThrottlingTemperatures; |
| 2164 | 2102 |
| 2165 HardwareInfo(); | 2103 HardwareInfo(); |
| 2166 | 2104 |
| 2167 HardwareInfo.fromJson(core.Map _json) { | 2105 HardwareInfo.fromJson(core.Map _json) { |
| 2168 if (_json.containsKey("batteryShutdownTemperatures")) { | 2106 if (_json.containsKey("batteryShutdownTemperatures")) { |
| 2169 batteryShutdownTemperatures = _json["batteryShutdownTemperatures"]; | 2107 batteryShutdownTemperatures = _json["batteryShutdownTemperatures"]; |
| 2170 } | 2108 } |
| 2171 if (_json.containsKey("batteryThrottlingTemperatures")) { | 2109 if (_json.containsKey("batteryThrottlingTemperatures")) { |
| 2172 batteryThrottlingTemperatures = _json["batteryThrottlingTemperatures"]; | 2110 batteryThrottlingTemperatures = _json["batteryThrottlingTemperatures"]; |
| (...skipping 30 matching lines...) Expand all Loading... |
| 2203 } | 2141 } |
| 2204 if (_json.containsKey("skinShutdownTemperatures")) { | 2142 if (_json.containsKey("skinShutdownTemperatures")) { |
| 2205 skinShutdownTemperatures = _json["skinShutdownTemperatures"]; | 2143 skinShutdownTemperatures = _json["skinShutdownTemperatures"]; |
| 2206 } | 2144 } |
| 2207 if (_json.containsKey("skinThrottlingTemperatures")) { | 2145 if (_json.containsKey("skinThrottlingTemperatures")) { |
| 2208 skinThrottlingTemperatures = _json["skinThrottlingTemperatures"]; | 2146 skinThrottlingTemperatures = _json["skinThrottlingTemperatures"]; |
| 2209 } | 2147 } |
| 2210 } | 2148 } |
| 2211 | 2149 |
| 2212 core.Map<core.String, core.Object> toJson() { | 2150 core.Map<core.String, core.Object> toJson() { |
| 2213 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2151 final core.Map<core.String, core.Object> _json = |
| 2152 new core.Map<core.String, core.Object>(); |
| 2214 if (batteryShutdownTemperatures != null) { | 2153 if (batteryShutdownTemperatures != null) { |
| 2215 _json["batteryShutdownTemperatures"] = batteryShutdownTemperatures; | 2154 _json["batteryShutdownTemperatures"] = batteryShutdownTemperatures; |
| 2216 } | 2155 } |
| 2217 if (batteryThrottlingTemperatures != null) { | 2156 if (batteryThrottlingTemperatures != null) { |
| 2218 _json["batteryThrottlingTemperatures"] = batteryThrottlingTemperatures; | 2157 _json["batteryThrottlingTemperatures"] = batteryThrottlingTemperatures; |
| 2219 } | 2158 } |
| 2220 if (brand != null) { | 2159 if (brand != null) { |
| 2221 _json["brand"] = brand; | 2160 _json["brand"] = brand; |
| 2222 } | 2161 } |
| 2223 if (cpuShutdownTemperatures != null) { | 2162 if (cpuShutdownTemperatures != null) { |
| (...skipping 26 matching lines...) Expand all Loading... |
| 2250 if (skinShutdownTemperatures != null) { | 2189 if (skinShutdownTemperatures != null) { |
| 2251 _json["skinShutdownTemperatures"] = skinShutdownTemperatures; | 2190 _json["skinShutdownTemperatures"] = skinShutdownTemperatures; |
| 2252 } | 2191 } |
| 2253 if (skinThrottlingTemperatures != null) { | 2192 if (skinThrottlingTemperatures != null) { |
| 2254 _json["skinThrottlingTemperatures"] = skinThrottlingTemperatures; | 2193 _json["skinThrottlingTemperatures"] = skinThrottlingTemperatures; |
| 2255 } | 2194 } |
| 2256 return _json; | 2195 return _json; |
| 2257 } | 2196 } |
| 2258 } | 2197 } |
| 2259 | 2198 |
| 2260 /** | 2199 /// Hardware status. Temperatures may be compared to the temperature thresholds |
| 2261 * Hardware status. Temperatures may be compared to the temperature thresholds | 2200 /// available in hardwareInfo to determine hardware health. |
| 2262 * available in hardwareInfo to determine hardware health. | |
| 2263 */ | |
| 2264 class HardwareStatus { | 2201 class HardwareStatus { |
| 2265 /** | 2202 /// Current battery temperatures in Celsius for each battery on the device. |
| 2266 * Current battery temperatures in Celsius for each battery on the device. | |
| 2267 */ | |
| 2268 core.List<core.double> batteryTemperatures; | 2203 core.List<core.double> batteryTemperatures; |
| 2269 /** Current CPU temperatures in Celsius for each CPU on the device. */ | 2204 |
| 2205 /// Current CPU temperatures in Celsius for each CPU on the device. |
| 2270 core.List<core.double> cpuTemperatures; | 2206 core.List<core.double> cpuTemperatures; |
| 2271 /** | 2207 |
| 2272 * CPU usages in percentage for each core available on the device. Usage is 0 | 2208 /// CPU usages in percentage for each core available on the device. Usage is |
| 2273 * for each unplugged core. Empty array implies that CPU usage is not | 2209 /// 0 for each unplugged core. Empty array implies that CPU usage is not |
| 2274 * supported in the system. | 2210 /// supported in the system. |
| 2275 */ | |
| 2276 core.List<core.double> cpuUsages; | 2211 core.List<core.double> cpuUsages; |
| 2277 /** The time the measurements were taken. */ | 2212 |
| 2213 /// The time the measurements were taken. |
| 2278 core.String createTime; | 2214 core.String createTime; |
| 2279 /** | 2215 |
| 2280 * Fan speeds in RPM for each fan on the device. Empty array means that there | 2216 /// Fan speeds in RPM for each fan on the device. Empty array means that |
| 2281 * are no fans or fan speed is not supported on the system. | 2217 /// there are no fans or fan speed is not supported on the system. |
| 2282 */ | |
| 2283 core.List<core.double> fanSpeeds; | 2218 core.List<core.double> fanSpeeds; |
| 2284 /** Current GPU temperatures in Celsius for each GPU on the device. */ | 2219 |
| 2220 /// Current GPU temperatures in Celsius for each GPU on the device. |
| 2285 core.List<core.double> gpuTemperatures; | 2221 core.List<core.double> gpuTemperatures; |
| 2286 /** Current device skin temperatures in Celsius. */ | 2222 |
| 2223 /// Current device skin temperatures in Celsius. |
| 2287 core.List<core.double> skinTemperatures; | 2224 core.List<core.double> skinTemperatures; |
| 2288 | 2225 |
| 2289 HardwareStatus(); | 2226 HardwareStatus(); |
| 2290 | 2227 |
| 2291 HardwareStatus.fromJson(core.Map _json) { | 2228 HardwareStatus.fromJson(core.Map _json) { |
| 2292 if (_json.containsKey("batteryTemperatures")) { | 2229 if (_json.containsKey("batteryTemperatures")) { |
| 2293 batteryTemperatures = _json["batteryTemperatures"]; | 2230 batteryTemperatures = _json["batteryTemperatures"]; |
| 2294 } | 2231 } |
| 2295 if (_json.containsKey("cpuTemperatures")) { | 2232 if (_json.containsKey("cpuTemperatures")) { |
| 2296 cpuTemperatures = _json["cpuTemperatures"]; | 2233 cpuTemperatures = _json["cpuTemperatures"]; |
| 2297 } | 2234 } |
| 2298 if (_json.containsKey("cpuUsages")) { | 2235 if (_json.containsKey("cpuUsages")) { |
| 2299 cpuUsages = _json["cpuUsages"]; | 2236 cpuUsages = _json["cpuUsages"]; |
| 2300 } | 2237 } |
| 2301 if (_json.containsKey("createTime")) { | 2238 if (_json.containsKey("createTime")) { |
| 2302 createTime = _json["createTime"]; | 2239 createTime = _json["createTime"]; |
| 2303 } | 2240 } |
| 2304 if (_json.containsKey("fanSpeeds")) { | 2241 if (_json.containsKey("fanSpeeds")) { |
| 2305 fanSpeeds = _json["fanSpeeds"]; | 2242 fanSpeeds = _json["fanSpeeds"]; |
| 2306 } | 2243 } |
| 2307 if (_json.containsKey("gpuTemperatures")) { | 2244 if (_json.containsKey("gpuTemperatures")) { |
| 2308 gpuTemperatures = _json["gpuTemperatures"]; | 2245 gpuTemperatures = _json["gpuTemperatures"]; |
| 2309 } | 2246 } |
| 2310 if (_json.containsKey("skinTemperatures")) { | 2247 if (_json.containsKey("skinTemperatures")) { |
| 2311 skinTemperatures = _json["skinTemperatures"]; | 2248 skinTemperatures = _json["skinTemperatures"]; |
| 2312 } | 2249 } |
| 2313 } | 2250 } |
| 2314 | 2251 |
| 2315 core.Map<core.String, core.Object> toJson() { | 2252 core.Map<core.String, core.Object> toJson() { |
| 2316 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2253 final core.Map<core.String, core.Object> _json = |
| 2254 new core.Map<core.String, core.Object>(); |
| 2317 if (batteryTemperatures != null) { | 2255 if (batteryTemperatures != null) { |
| 2318 _json["batteryTemperatures"] = batteryTemperatures; | 2256 _json["batteryTemperatures"] = batteryTemperatures; |
| 2319 } | 2257 } |
| 2320 if (cpuTemperatures != null) { | 2258 if (cpuTemperatures != null) { |
| 2321 _json["cpuTemperatures"] = cpuTemperatures; | 2259 _json["cpuTemperatures"] = cpuTemperatures; |
| 2322 } | 2260 } |
| 2323 if (cpuUsages != null) { | 2261 if (cpuUsages != null) { |
| 2324 _json["cpuUsages"] = cpuUsages; | 2262 _json["cpuUsages"] = cpuUsages; |
| 2325 } | 2263 } |
| 2326 if (createTime != null) { | 2264 if (createTime != null) { |
| 2327 _json["createTime"] = createTime; | 2265 _json["createTime"] = createTime; |
| 2328 } | 2266 } |
| 2329 if (fanSpeeds != null) { | 2267 if (fanSpeeds != null) { |
| 2330 _json["fanSpeeds"] = fanSpeeds; | 2268 _json["fanSpeeds"] = fanSpeeds; |
| 2331 } | 2269 } |
| 2332 if (gpuTemperatures != null) { | 2270 if (gpuTemperatures != null) { |
| 2333 _json["gpuTemperatures"] = gpuTemperatures; | 2271 _json["gpuTemperatures"] = gpuTemperatures; |
| 2334 } | 2272 } |
| 2335 if (skinTemperatures != null) { | 2273 if (skinTemperatures != null) { |
| 2336 _json["skinTemperatures"] = skinTemperatures; | 2274 _json["skinTemperatures"] = skinTemperatures; |
| 2337 } | 2275 } |
| 2338 return _json; | 2276 return _json; |
| 2339 } | 2277 } |
| 2340 } | 2278 } |
| 2341 | 2279 |
| 2342 /** Response to a request to list devices for a given enterprise. */ | 2280 /// Response to a request to list devices for a given enterprise. |
| 2343 class ListDevicesResponse { | 2281 class ListDevicesResponse { |
| 2344 /** The list of devices. */ | 2282 /// The list of devices. |
| 2345 core.List<Device> devices; | 2283 core.List<Device> devices; |
| 2346 /** If there are more results, a token to retrieve next page of results. */ | 2284 |
| 2285 /// If there are more results, a token to retrieve next page of results. |
| 2347 core.String nextPageToken; | 2286 core.String nextPageToken; |
| 2348 | 2287 |
| 2349 ListDevicesResponse(); | 2288 ListDevicesResponse(); |
| 2350 | 2289 |
| 2351 ListDevicesResponse.fromJson(core.Map _json) { | 2290 ListDevicesResponse.fromJson(core.Map _json) { |
| 2352 if (_json.containsKey("devices")) { | 2291 if (_json.containsKey("devices")) { |
| 2353 devices = _json["devices"].map((value) => new Device.fromJson(value)).toLi
st(); | 2292 devices = |
| 2293 _json["devices"].map((value) => new Device.fromJson(value)).toList(); |
| 2354 } | 2294 } |
| 2355 if (_json.containsKey("nextPageToken")) { | 2295 if (_json.containsKey("nextPageToken")) { |
| 2356 nextPageToken = _json["nextPageToken"]; | 2296 nextPageToken = _json["nextPageToken"]; |
| 2357 } | 2297 } |
| 2358 } | 2298 } |
| 2359 | 2299 |
| 2360 core.Map<core.String, core.Object> toJson() { | 2300 core.Map<core.String, core.Object> toJson() { |
| 2361 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2301 final core.Map<core.String, core.Object> _json = |
| 2302 new core.Map<core.String, core.Object>(); |
| 2362 if (devices != null) { | 2303 if (devices != null) { |
| 2363 _json["devices"] = devices.map((value) => (value).toJson()).toList(); | 2304 _json["devices"] = devices.map((value) => (value).toJson()).toList(); |
| 2364 } | 2305 } |
| 2365 if (nextPageToken != null) { | 2306 if (nextPageToken != null) { |
| 2366 _json["nextPageToken"] = nextPageToken; | 2307 _json["nextPageToken"] = nextPageToken; |
| 2367 } | 2308 } |
| 2368 return _json; | 2309 return _json; |
| 2369 } | 2310 } |
| 2370 } | 2311 } |
| 2371 | 2312 |
| 2372 /** The response message for Operations.ListOperations. */ | 2313 /// The response message for Operations.ListOperations. |
| 2373 class ListOperationsResponse { | 2314 class ListOperationsResponse { |
| 2374 /** The standard List next-page token. */ | 2315 /// The standard List next-page token. |
| 2375 core.String nextPageToken; | 2316 core.String nextPageToken; |
| 2376 /** A list of operations that matches the specified filter in the request. */ | 2317 |
| 2318 /// A list of operations that matches the specified filter in the request. |
| 2377 core.List<Operation> operations; | 2319 core.List<Operation> operations; |
| 2378 | 2320 |
| 2379 ListOperationsResponse(); | 2321 ListOperationsResponse(); |
| 2380 | 2322 |
| 2381 ListOperationsResponse.fromJson(core.Map _json) { | 2323 ListOperationsResponse.fromJson(core.Map _json) { |
| 2382 if (_json.containsKey("nextPageToken")) { | 2324 if (_json.containsKey("nextPageToken")) { |
| 2383 nextPageToken = _json["nextPageToken"]; | 2325 nextPageToken = _json["nextPageToken"]; |
| 2384 } | 2326 } |
| 2385 if (_json.containsKey("operations")) { | 2327 if (_json.containsKey("operations")) { |
| 2386 operations = _json["operations"].map((value) => new Operation.fromJson(val
ue)).toList(); | 2328 operations = _json["operations"] |
| 2329 .map((value) => new Operation.fromJson(value)) |
| 2330 .toList(); |
| 2387 } | 2331 } |
| 2388 } | 2332 } |
| 2389 | 2333 |
| 2390 core.Map<core.String, core.Object> toJson() { | 2334 core.Map<core.String, core.Object> toJson() { |
| 2391 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2335 final core.Map<core.String, core.Object> _json = |
| 2336 new core.Map<core.String, core.Object>(); |
| 2392 if (nextPageToken != null) { | 2337 if (nextPageToken != null) { |
| 2393 _json["nextPageToken"] = nextPageToken; | 2338 _json["nextPageToken"] = nextPageToken; |
| 2394 } | 2339 } |
| 2395 if (operations != null) { | 2340 if (operations != null) { |
| 2396 _json["operations"] = operations.map((value) => (value).toJson()).toList()
; | 2341 _json["operations"] = |
| 2342 operations.map((value) => (value).toJson()).toList(); |
| 2397 } | 2343 } |
| 2398 return _json; | 2344 return _json; |
| 2399 } | 2345 } |
| 2400 } | 2346 } |
| 2401 | 2347 |
| 2402 /** Response to a request to list policies for a given enterprise. */ | 2348 /// Response to a request to list policies for a given enterprise. |
| 2403 class ListPoliciesResponse { | 2349 class ListPoliciesResponse { |
| 2404 /** If there are more results, a token to retrieve next page of results. */ | 2350 /// If there are more results, a token to retrieve next page of results. |
| 2405 core.String nextPageToken; | 2351 core.String nextPageToken; |
| 2406 /** The list of policies. */ | 2352 |
| 2353 /// The list of policies. |
| 2407 core.List<Policy> policies; | 2354 core.List<Policy> policies; |
| 2408 | 2355 |
| 2409 ListPoliciesResponse(); | 2356 ListPoliciesResponse(); |
| 2410 | 2357 |
| 2411 ListPoliciesResponse.fromJson(core.Map _json) { | 2358 ListPoliciesResponse.fromJson(core.Map _json) { |
| 2412 if (_json.containsKey("nextPageToken")) { | 2359 if (_json.containsKey("nextPageToken")) { |
| 2413 nextPageToken = _json["nextPageToken"]; | 2360 nextPageToken = _json["nextPageToken"]; |
| 2414 } | 2361 } |
| 2415 if (_json.containsKey("policies")) { | 2362 if (_json.containsKey("policies")) { |
| 2416 policies = _json["policies"].map((value) => new Policy.fromJson(value)).to
List(); | 2363 policies = |
| 2364 _json["policies"].map((value) => new Policy.fromJson(value)).toList(); |
| 2417 } | 2365 } |
| 2418 } | 2366 } |
| 2419 | 2367 |
| 2420 core.Map<core.String, core.Object> toJson() { | 2368 core.Map<core.String, core.Object> toJson() { |
| 2421 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2369 final core.Map<core.String, core.Object> _json = |
| 2370 new core.Map<core.String, core.Object>(); |
| 2422 if (nextPageToken != null) { | 2371 if (nextPageToken != null) { |
| 2423 _json["nextPageToken"] = nextPageToken; | 2372 _json["nextPageToken"] = nextPageToken; |
| 2424 } | 2373 } |
| 2425 if (policies != null) { | 2374 if (policies != null) { |
| 2426 _json["policies"] = policies.map((value) => (value).toJson()).toList(); | 2375 _json["policies"] = policies.map((value) => (value).toJson()).toList(); |
| 2427 } | 2376 } |
| 2428 return _json; | 2377 return _json; |
| 2429 } | 2378 } |
| 2430 } | 2379 } |
| 2431 | 2380 |
| 2432 /** Managed property. */ | 2381 /// Managed property. |
| 2433 class ManagedProperty { | 2382 class ManagedProperty { |
| 2434 /** | 2383 /// The default value of the properties. BUNDLE_ARRAY properties never have a |
| 2435 * The default value of the properties. BUNDLE_ARRAY properties never have a | 2384 /// default value. |
| 2436 * default value. | 2385 /// |
| 2437 * | 2386 /// The values for Object must be JSON objects. It can consist of `num`, |
| 2438 * The values for Object must be JSON objects. It can consist of `num`, | 2387 /// `String`, `bool` and `null` as well as `Map` and `List` values. |
| 2439 * `String`, `bool` and `null` as well as `Map` and `List` values. | |
| 2440 */ | |
| 2441 core.Object defaultValue; | 2388 core.Object defaultValue; |
| 2442 /** | 2389 |
| 2443 * A longer description of the property, giving more detail of what it | 2390 /// A longer description of the property, giving more detail of what it |
| 2444 * affects. Localized. | 2391 /// affects. Localized. |
| 2445 */ | |
| 2446 core.String description; | 2392 core.String description; |
| 2447 /** For CHOICE or MULTISELECT properties, the list of possible entries. */ | 2393 |
| 2394 /// For CHOICE or MULTISELECT properties, the list of possible entries. |
| 2448 core.List<ManagedPropertyEntry> entries; | 2395 core.List<ManagedPropertyEntry> entries; |
| 2449 /** | 2396 |
| 2450 * The unique key that the application uses to identify the property, e.g. | 2397 /// The unique key that the application uses to identify the property, e.g. |
| 2451 * "com.google.android.gm.fieldname". | 2398 /// "com.google.android.gm.fieldname". |
| 2452 */ | |
| 2453 core.String key; | 2399 core.String key; |
| 2454 /** | 2400 |
| 2455 * For BUNDLE_ARRAY properties, the list of nested properties. A BUNDLE_ARRAY | 2401 /// For BUNDLE_ARRAY properties, the list of nested properties. A |
| 2456 * property is at most two levels deep. | 2402 /// BUNDLE_ARRAY property is at most two levels deep. |
| 2457 */ | |
| 2458 core.List<ManagedProperty> nestedProperties; | 2403 core.List<ManagedProperty> nestedProperties; |
| 2459 /** The name of the property. Localized. */ | 2404 |
| 2405 /// The name of the property. Localized. |
| 2460 core.String title; | 2406 core.String title; |
| 2461 /** | 2407 |
| 2462 * The type of the property. | 2408 /// The type of the property. |
| 2463 * Possible string values are: | 2409 /// Possible string values are: |
| 2464 * - "MANAGED_PROPERTY_TYPE_UNSPECIFIED" : Not used. | 2410 /// - "MANAGED_PROPERTY_TYPE_UNSPECIFIED" : Not used. |
| 2465 * - "BOOL" : A property of boolean type. | 2411 /// - "BOOL" : A property of boolean type. |
| 2466 * - "STRING" : A property of string type. | 2412 /// - "STRING" : A property of string type. |
| 2467 * - "INTEGER" : A property of integer type. | 2413 /// - "INTEGER" : A property of integer type. |
| 2468 * - "CHOICE" : A choice of one item from a set. | 2414 /// - "CHOICE" : A choice of one item from a set. |
| 2469 * - "MULTISELECT" : A choice of multiple items from a set. | 2415 /// - "MULTISELECT" : A choice of multiple items from a set. |
| 2470 * - "HIDDEN" : A hidden restriction of string type (the default value can be | 2416 /// - "HIDDEN" : A hidden restriction of string type (the default value can |
| 2471 * used to pass along information that cannot be modified, such as a version | 2417 /// be used to pass along information that cannot be modified, such as a |
| 2472 * code). | 2418 /// version code). |
| 2473 * - "BUNDLE_ARRAY" : An array of property bundles. | 2419 /// - "BUNDLE_ARRAY" : An array of property bundles. |
| 2474 */ | |
| 2475 core.String type; | 2420 core.String type; |
| 2476 | 2421 |
| 2477 ManagedProperty(); | 2422 ManagedProperty(); |
| 2478 | 2423 |
| 2479 ManagedProperty.fromJson(core.Map _json) { | 2424 ManagedProperty.fromJson(core.Map _json) { |
| 2480 if (_json.containsKey("defaultValue")) { | 2425 if (_json.containsKey("defaultValue")) { |
| 2481 defaultValue = _json["defaultValue"]; | 2426 defaultValue = _json["defaultValue"]; |
| 2482 } | 2427 } |
| 2483 if (_json.containsKey("description")) { | 2428 if (_json.containsKey("description")) { |
| 2484 description = _json["description"]; | 2429 description = _json["description"]; |
| 2485 } | 2430 } |
| 2486 if (_json.containsKey("entries")) { | 2431 if (_json.containsKey("entries")) { |
| 2487 entries = _json["entries"].map((value) => new ManagedPropertyEntry.fromJso
n(value)).toList(); | 2432 entries = _json["entries"] |
| 2433 .map((value) => new ManagedPropertyEntry.fromJson(value)) |
| 2434 .toList(); |
| 2488 } | 2435 } |
| 2489 if (_json.containsKey("key")) { | 2436 if (_json.containsKey("key")) { |
| 2490 key = _json["key"]; | 2437 key = _json["key"]; |
| 2491 } | 2438 } |
| 2492 if (_json.containsKey("nestedProperties")) { | 2439 if (_json.containsKey("nestedProperties")) { |
| 2493 nestedProperties = _json["nestedProperties"].map((value) => new ManagedPro
perty.fromJson(value)).toList(); | 2440 nestedProperties = _json["nestedProperties"] |
| 2441 .map((value) => new ManagedProperty.fromJson(value)) |
| 2442 .toList(); |
| 2494 } | 2443 } |
| 2495 if (_json.containsKey("title")) { | 2444 if (_json.containsKey("title")) { |
| 2496 title = _json["title"]; | 2445 title = _json["title"]; |
| 2497 } | 2446 } |
| 2498 if (_json.containsKey("type")) { | 2447 if (_json.containsKey("type")) { |
| 2499 type = _json["type"]; | 2448 type = _json["type"]; |
| 2500 } | 2449 } |
| 2501 } | 2450 } |
| 2502 | 2451 |
| 2503 core.Map<core.String, core.Object> toJson() { | 2452 core.Map<core.String, core.Object> toJson() { |
| 2504 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2453 final core.Map<core.String, core.Object> _json = |
| 2454 new core.Map<core.String, core.Object>(); |
| 2505 if (defaultValue != null) { | 2455 if (defaultValue != null) { |
| 2506 _json["defaultValue"] = defaultValue; | 2456 _json["defaultValue"] = defaultValue; |
| 2507 } | 2457 } |
| 2508 if (description != null) { | 2458 if (description != null) { |
| 2509 _json["description"] = description; | 2459 _json["description"] = description; |
| 2510 } | 2460 } |
| 2511 if (entries != null) { | 2461 if (entries != null) { |
| 2512 _json["entries"] = entries.map((value) => (value).toJson()).toList(); | 2462 _json["entries"] = entries.map((value) => (value).toJson()).toList(); |
| 2513 } | 2463 } |
| 2514 if (key != null) { | 2464 if (key != null) { |
| 2515 _json["key"] = key; | 2465 _json["key"] = key; |
| 2516 } | 2466 } |
| 2517 if (nestedProperties != null) { | 2467 if (nestedProperties != null) { |
| 2518 _json["nestedProperties"] = nestedProperties.map((value) => (value).toJson
()).toList(); | 2468 _json["nestedProperties"] = |
| 2469 nestedProperties.map((value) => (value).toJson()).toList(); |
| 2519 } | 2470 } |
| 2520 if (title != null) { | 2471 if (title != null) { |
| 2521 _json["title"] = title; | 2472 _json["title"] = title; |
| 2522 } | 2473 } |
| 2523 if (type != null) { | 2474 if (type != null) { |
| 2524 _json["type"] = type; | 2475 _json["type"] = type; |
| 2525 } | 2476 } |
| 2526 return _json; | 2477 return _json; |
| 2527 } | 2478 } |
| 2528 } | 2479 } |
| 2529 | 2480 |
| 2530 /** An entry of a managed property. */ | 2481 /// An entry of a managed property. |
| 2531 class ManagedPropertyEntry { | 2482 class ManagedPropertyEntry { |
| 2532 /** The human-readable name of the value. Localized. */ | 2483 /// The human-readable name of the value. Localized. |
| 2533 core.String name; | 2484 core.String name; |
| 2534 /** | 2485 |
| 2535 * The machine-readable value of the entry, which should be used in the | 2486 /// The machine-readable value of the entry, which should be used in the |
| 2536 * configuration. Not localized. | 2487 /// configuration. Not localized. |
| 2537 */ | |
| 2538 core.String value; | 2488 core.String value; |
| 2539 | 2489 |
| 2540 ManagedPropertyEntry(); | 2490 ManagedPropertyEntry(); |
| 2541 | 2491 |
| 2542 ManagedPropertyEntry.fromJson(core.Map _json) { | 2492 ManagedPropertyEntry.fromJson(core.Map _json) { |
| 2543 if (_json.containsKey("name")) { | 2493 if (_json.containsKey("name")) { |
| 2544 name = _json["name"]; | 2494 name = _json["name"]; |
| 2545 } | 2495 } |
| 2546 if (_json.containsKey("value")) { | 2496 if (_json.containsKey("value")) { |
| 2547 value = _json["value"]; | 2497 value = _json["value"]; |
| 2548 } | 2498 } |
| 2549 } | 2499 } |
| 2550 | 2500 |
| 2551 core.Map<core.String, core.Object> toJson() { | 2501 core.Map<core.String, core.Object> toJson() { |
| 2552 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2502 final core.Map<core.String, core.Object> _json = |
| 2503 new core.Map<core.String, core.Object>(); |
| 2553 if (name != null) { | 2504 if (name != null) { |
| 2554 _json["name"] = name; | 2505 _json["name"] = name; |
| 2555 } | 2506 } |
| 2556 if (value != null) { | 2507 if (value != null) { |
| 2557 _json["value"] = value; | 2508 _json["value"] = value; |
| 2558 } | 2509 } |
| 2559 return _json; | 2510 return _json; |
| 2560 } | 2511 } |
| 2561 } | 2512 } |
| 2562 | 2513 |
| 2563 /** An event related to memory and storage measurements. */ | 2514 /// An event related to memory and storage measurements. |
| 2564 class MemoryEvent { | 2515 class MemoryEvent { |
| 2565 /** | 2516 /// The number of free bytes in the medium, or for EXTERNAL_STORAGE_DETECTED, |
| 2566 * The number of free bytes in the medium, or for EXTERNAL_STORAGE_DETECTED, | 2517 /// the total capacity in bytes of the storage medium. |
| 2567 * the total capacity in bytes of the storage medium. | |
| 2568 */ | |
| 2569 core.String byteCount; | 2518 core.String byteCount; |
| 2570 /** The creation time of the event. */ | 2519 |
| 2520 /// The creation time of the event. |
| 2571 core.String createTime; | 2521 core.String createTime; |
| 2572 /** | 2522 |
| 2573 * Event type. | 2523 /// Event type. |
| 2574 * Possible string values are: | 2524 /// Possible string values are: |
| 2575 * - "MEMORY_EVENT_TYPE_UNSPECIFIED" : Unspecified. No events have this type. | 2525 /// - "MEMORY_EVENT_TYPE_UNSPECIFIED" : Unspecified. No events have this |
| 2576 * - "RAM_MEASURED" : Free space in RAM was measured. | 2526 /// type. |
| 2577 * - "INTERNAL_STORAGE_MEASURED" : Free space in internal storage was | 2527 /// - "RAM_MEASURED" : Free space in RAM was measured. |
| 2578 * measured. | 2528 /// - "INTERNAL_STORAGE_MEASURED" : Free space in internal storage was |
| 2579 * - "EXTERNAL_STORAGE_DETECTED" : A new external storage medium was detected. | 2529 /// measured. |
| 2580 * The reported byte count is the total capacity of the storage medium. | 2530 /// - "EXTERNAL_STORAGE_DETECTED" : A new external storage medium was |
| 2581 * - "EXTERNAL_STORAGE_REMOVED" : An external storage medium was removed. The | 2531 /// detected. The reported byte count is the total capacity of the storage |
| 2582 * reported byte count is zero. | 2532 /// medium. |
| 2583 * - "EXTERNAL_STORAGE_MEASURED" : Free space in an external storage medium | 2533 /// - "EXTERNAL_STORAGE_REMOVED" : An external storage medium was removed. |
| 2584 * was measured. | 2534 /// The reported byte count is zero. |
| 2585 */ | 2535 /// - "EXTERNAL_STORAGE_MEASURED" : Free space in an external storage medium |
| 2536 /// was measured. |
| 2586 core.String eventType; | 2537 core.String eventType; |
| 2587 | 2538 |
| 2588 MemoryEvent(); | 2539 MemoryEvent(); |
| 2589 | 2540 |
| 2590 MemoryEvent.fromJson(core.Map _json) { | 2541 MemoryEvent.fromJson(core.Map _json) { |
| 2591 if (_json.containsKey("byteCount")) { | 2542 if (_json.containsKey("byteCount")) { |
| 2592 byteCount = _json["byteCount"]; | 2543 byteCount = _json["byteCount"]; |
| 2593 } | 2544 } |
| 2594 if (_json.containsKey("createTime")) { | 2545 if (_json.containsKey("createTime")) { |
| 2595 createTime = _json["createTime"]; | 2546 createTime = _json["createTime"]; |
| 2596 } | 2547 } |
| 2597 if (_json.containsKey("eventType")) { | 2548 if (_json.containsKey("eventType")) { |
| 2598 eventType = _json["eventType"]; | 2549 eventType = _json["eventType"]; |
| 2599 } | 2550 } |
| 2600 } | 2551 } |
| 2601 | 2552 |
| 2602 core.Map<core.String, core.Object> toJson() { | 2553 core.Map<core.String, core.Object> toJson() { |
| 2603 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2554 final core.Map<core.String, core.Object> _json = |
| 2555 new core.Map<core.String, core.Object>(); |
| 2604 if (byteCount != null) { | 2556 if (byteCount != null) { |
| 2605 _json["byteCount"] = byteCount; | 2557 _json["byteCount"] = byteCount; |
| 2606 } | 2558 } |
| 2607 if (createTime != null) { | 2559 if (createTime != null) { |
| 2608 _json["createTime"] = createTime; | 2560 _json["createTime"] = createTime; |
| 2609 } | 2561 } |
| 2610 if (eventType != null) { | 2562 if (eventType != null) { |
| 2611 _json["eventType"] = eventType; | 2563 _json["eventType"] = eventType; |
| 2612 } | 2564 } |
| 2613 return _json; | 2565 return _json; |
| 2614 } | 2566 } |
| 2615 } | 2567 } |
| 2616 | 2568 |
| 2617 /** Information about device memory and storage. */ | 2569 /// Information about device memory and storage. |
| 2618 class MemoryInfo { | 2570 class MemoryInfo { |
| 2619 /** Total internal storage on device in bytes. */ | 2571 /// Total internal storage on device in bytes. |
| 2620 core.String totalInternalStorage; | 2572 core.String totalInternalStorage; |
| 2621 /** Total RAM on device in bytes. */ | 2573 |
| 2574 /// Total RAM on device in bytes. |
| 2622 core.String totalRam; | 2575 core.String totalRam; |
| 2623 | 2576 |
| 2624 MemoryInfo(); | 2577 MemoryInfo(); |
| 2625 | 2578 |
| 2626 MemoryInfo.fromJson(core.Map _json) { | 2579 MemoryInfo.fromJson(core.Map _json) { |
| 2627 if (_json.containsKey("totalInternalStorage")) { | 2580 if (_json.containsKey("totalInternalStorage")) { |
| 2628 totalInternalStorage = _json["totalInternalStorage"]; | 2581 totalInternalStorage = _json["totalInternalStorage"]; |
| 2629 } | 2582 } |
| 2630 if (_json.containsKey("totalRam")) { | 2583 if (_json.containsKey("totalRam")) { |
| 2631 totalRam = _json["totalRam"]; | 2584 totalRam = _json["totalRam"]; |
| 2632 } | 2585 } |
| 2633 } | 2586 } |
| 2634 | 2587 |
| 2635 core.Map<core.String, core.Object> toJson() { | 2588 core.Map<core.String, core.Object> toJson() { |
| 2636 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2589 final core.Map<core.String, core.Object> _json = |
| 2590 new core.Map<core.String, core.Object>(); |
| 2637 if (totalInternalStorage != null) { | 2591 if (totalInternalStorage != null) { |
| 2638 _json["totalInternalStorage"] = totalInternalStorage; | 2592 _json["totalInternalStorage"] = totalInternalStorage; |
| 2639 } | 2593 } |
| 2640 if (totalRam != null) { | 2594 if (totalRam != null) { |
| 2641 _json["totalRam"] = totalRam; | 2595 _json["totalRam"] = totalRam; |
| 2642 } | 2596 } |
| 2643 return _json; | 2597 return _json; |
| 2644 } | 2598 } |
| 2645 } | 2599 } |
| 2646 | 2600 |
| 2647 /** Device network info. */ | 2601 /// Device network info. |
| 2648 class NetworkInfo { | 2602 class NetworkInfo { |
| 2649 /** IMEI number of the GSM device, e.g. A1000031212. */ | 2603 /// IMEI number of the GSM device, e.g. A1000031212. |
| 2650 core.String imei; | 2604 core.String imei; |
| 2651 /** MEID number of the CDMA device, e.g. A00000292788E1. */ | 2605 |
| 2606 /// MEID number of the CDMA device, e.g. A00000292788E1. |
| 2652 core.String meid; | 2607 core.String meid; |
| 2653 /** WiFi MAC address of the device, e.g. 7c:11:11:11:11:11. */ | 2608 |
| 2609 /// WiFi MAC address of the device, e.g. 7c:11:11:11:11:11. |
| 2654 core.String wifiMacAddress; | 2610 core.String wifiMacAddress; |
| 2655 | 2611 |
| 2656 NetworkInfo(); | 2612 NetworkInfo(); |
| 2657 | 2613 |
| 2658 NetworkInfo.fromJson(core.Map _json) { | 2614 NetworkInfo.fromJson(core.Map _json) { |
| 2659 if (_json.containsKey("imei")) { | 2615 if (_json.containsKey("imei")) { |
| 2660 imei = _json["imei"]; | 2616 imei = _json["imei"]; |
| 2661 } | 2617 } |
| 2662 if (_json.containsKey("meid")) { | 2618 if (_json.containsKey("meid")) { |
| 2663 meid = _json["meid"]; | 2619 meid = _json["meid"]; |
| 2664 } | 2620 } |
| 2665 if (_json.containsKey("wifiMacAddress")) { | 2621 if (_json.containsKey("wifiMacAddress")) { |
| 2666 wifiMacAddress = _json["wifiMacAddress"]; | 2622 wifiMacAddress = _json["wifiMacAddress"]; |
| 2667 } | 2623 } |
| 2668 } | 2624 } |
| 2669 | 2625 |
| 2670 core.Map<core.String, core.Object> toJson() { | 2626 core.Map<core.String, core.Object> toJson() { |
| 2671 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2627 final core.Map<core.String, core.Object> _json = |
| 2628 new core.Map<core.String, core.Object>(); |
| 2672 if (imei != null) { | 2629 if (imei != null) { |
| 2673 _json["imei"] = imei; | 2630 _json["imei"] = imei; |
| 2674 } | 2631 } |
| 2675 if (meid != null) { | 2632 if (meid != null) { |
| 2676 _json["meid"] = meid; | 2633 _json["meid"] = meid; |
| 2677 } | 2634 } |
| 2678 if (wifiMacAddress != null) { | 2635 if (wifiMacAddress != null) { |
| 2679 _json["wifiMacAddress"] = wifiMacAddress; | 2636 _json["wifiMacAddress"] = wifiMacAddress; |
| 2680 } | 2637 } |
| 2681 return _json; | 2638 return _json; |
| 2682 } | 2639 } |
| 2683 } | 2640 } |
| 2684 | 2641 |
| 2685 /** Provides detail about non-compliance with a policy setting. */ | 2642 /// Provides detail about non-compliance with a policy setting. |
| 2686 class NonComplianceDetail { | 2643 class NonComplianceDetail { |
| 2687 /** | 2644 /// If the policy setting could not be applied, the current value of the |
| 2688 * If the policy setting could not be applied, the current value of the | 2645 /// setting on the device. |
| 2689 * setting on the device. | 2646 /// |
| 2690 * | 2647 /// The values for Object must be JSON objects. It can consist of `num`, |
| 2691 * The values for Object must be JSON objects. It can consist of `num`, | 2648 /// `String`, `bool` and `null` as well as `Map` and `List` values. |
| 2692 * `String`, `bool` and `null` as well as `Map` and `List` values. | |
| 2693 */ | |
| 2694 core.Object currentValue; | 2649 core.Object currentValue; |
| 2695 /** | 2650 |
| 2696 * For settings with nested fields, if a particular nested field is out of | 2651 /// For settings with nested fields, if a particular nested field is out of |
| 2697 * compliance, this specifies the full path to the offending field. The path | 2652 /// compliance, this specifies the full path to the offending field. The path |
| 2698 * is formatted in the same way the policy JSON field would be referenced in | 2653 /// is formatted in the same way the policy JSON field would be referenced in |
| 2699 * JavaScript, that is: 1) For object-typed fields, the field name is followed | 2654 /// JavaScript, that is: 1) For object-typed fields, the field name is |
| 2700 * by a dot then by a subfield name. 2) For array-typed fields, the field | 2655 /// followed by a dot then by a subfield name. 2) For array-typed fields, |
| 2701 * name is followed by the array index enclosed in brackets. For example, to | 2656 /// the field name is followed by the array index enclosed in brackets. For |
| 2702 * indicate a problem with the url field in the externalData field in the 3rd | 2657 /// example, to indicate a problem with the url field in the externalData |
| 2703 * application, the path would be applications[2].externalData.url | 2658 /// field in the 3rd application, the path would be |
| 2704 */ | 2659 /// applications[2].externalData.url |
| 2705 core.String fieldPath; | 2660 core.String fieldPath; |
| 2706 /** | 2661 |
| 2707 * If package_name is set and the non-compliance reason is APP_NOT_INSTALLED, | 2662 /// If package_name is set and the non-compliance reason is |
| 2708 * the detailed reason the app cannot be installed. | 2663 /// APP_NOT_INSTALLED, the detailed reason the app cannot be installed. |
| 2709 * Possible string values are: | 2664 /// Possible string values are: |
| 2710 * - "INSTALLATION_FAILURE_REASON_UNSPECIFIED" : This value is disallowed. | 2665 /// - "INSTALLATION_FAILURE_REASON_UNSPECIFIED" : This value is disallowed. |
| 2711 * - "INSTALLATION_FAILURE_REASON_UNKNOWN" : An unknown condition is | 2666 /// - "INSTALLATION_FAILURE_REASON_UNKNOWN" : An unknown condition is |
| 2712 * preventing the app from being installed. Some potential reaons are that the | 2667 /// preventing the app from being installed. Some potential reaons are that |
| 2713 * device does not have enough storage, the device network connection is | 2668 /// the device does not have enough storage, the device network connection is |
| 2714 * unreliable, or the installation is taking longer than expected. The | 2669 /// unreliable, or the installation is taking longer than expected. The |
| 2715 * installation will be retried automatically. | 2670 /// installation will be retried automatically. |
| 2716 * - "IN_PROGRESS" : The installation is still in progress. | 2671 /// - "IN_PROGRESS" : The installation is still in progress. |
| 2717 * - "NOT_FOUND" : The app was not found in Play. | 2672 /// - "NOT_FOUND" : The app was not found in Play. |
| 2718 * - "NOT_COMPATIBLE_WITH_DEVICE" : The app is incompatible with the device. | 2673 /// - "NOT_COMPATIBLE_WITH_DEVICE" : The app is incompatible with the device. |
| 2719 * - "NOT_APPROVED" : The app has not been approved by the admin. | 2674 /// - "NOT_APPROVED" : The app has not been approved by the admin. |
| 2720 * - "PERMISSIONS_NOT_ACCEPTED" : The app has new permissions that have not | 2675 /// - "PERMISSIONS_NOT_ACCEPTED" : The app has new permissions that have not |
| 2721 * been accepted by the admin. | 2676 /// been accepted by the admin. |
| 2722 * - "NOT_AVAILABLE_IN_COUNTRY" : The app is not available in the user's | 2677 /// - "NOT_AVAILABLE_IN_COUNTRY" : The app is not available in the user's |
| 2723 * country. | 2678 /// country. |
| 2724 * - "NO_LICENSES_REMAINING" : There are no more licenses to assign to the | 2679 /// - "NO_LICENSES_REMAINING" : There are no more licenses to assign to the |
| 2725 * user. | 2680 /// user. |
| 2726 * - "NOT_ENROLLED" : The enterprise is no longer enrolled with Play for Work | 2681 /// - "NOT_ENROLLED" : The enterprise is no longer enrolled with Play for |
| 2727 * or Android Device Policy is not enabled for the enterprise. | 2682 /// Work or Android Device Policy is not enabled for the enterprise. |
| 2728 * - "USER_INVALID" : The user is no longer valid. The user may have been | 2683 /// - "USER_INVALID" : The user is no longer valid. The user may have been |
| 2729 * deleted or disabled. | 2684 /// deleted or disabled. |
| 2730 */ | |
| 2731 core.String installationFailureReason; | 2685 core.String installationFailureReason; |
| 2732 /** | 2686 |
| 2733 * The reason the device is not in compliance with the setting. | 2687 /// The reason the device is not in compliance with the setting. |
| 2734 * Possible string values are: | 2688 /// Possible string values are: |
| 2735 * - "NON_COMPLIANCE_REASON_UNSPECIFIED" : This value is disallowed. | 2689 /// - "NON_COMPLIANCE_REASON_UNSPECIFIED" : This value is disallowed. |
| 2736 * - "API_LEVEL" : The setting is not supported in the API level of Android OS | 2690 /// - "API_LEVEL" : The setting is not supported in the API level of Android |
| 2737 * version the device is running. | 2691 /// OS version the device is running. |
| 2738 * - "ADMIN_TYPE" : The admin type (profile owner, device owner, etc.) does | 2692 /// - "ADMIN_TYPE" : The admin type (profile owner, device owner, etc.) does |
| 2739 * not support the setting. | 2693 /// not support the setting. |
| 2740 * - "USER_ACTION" : The user has not taken required action to comply with the | 2694 /// - "USER_ACTION" : The user has not taken required action to comply with |
| 2741 * setting. | 2695 /// the setting. |
| 2742 * - "INVALID_VALUE" : The setting has an invalid value. | 2696 /// - "INVALID_VALUE" : The setting has an invalid value. |
| 2743 * - "APP_NOT_INSTALLED" : The application required to implement the policy is | 2697 /// - "APP_NOT_INSTALLED" : The application required to implement the policy |
| 2744 * not installed. | 2698 /// is not installed. |
| 2745 * - "UNSUPPORTED" : The policy is not supported by the version of Android | 2699 /// - "UNSUPPORTED" : The policy is not supported by the version of Android |
| 2746 * Device Policy on the device. | 2700 /// Device Policy on the device. |
| 2747 * - "APP_INSTALLED" : A blocked application is installed. | 2701 /// - "APP_INSTALLED" : A blocked application is installed. |
| 2748 * - "PENDING" : The setting was not applied yet at the time of the report, | 2702 /// - "PENDING" : The setting was not applied yet at the time of the report, |
| 2749 * but is expected to be applied shortly. | 2703 /// but is expected to be applied shortly. |
| 2750 * - "APP_INCOMPATIBLE" : The setting cannot be applied to the application | 2704 /// - "APP_INCOMPATIBLE" : The setting cannot be applied to the application |
| 2751 * because its target SDK version is not high enough. | 2705 /// because its target SDK version is not high enough. |
| 2752 */ | |
| 2753 core.String nonComplianceReason; | 2706 core.String nonComplianceReason; |
| 2754 /** | 2707 |
| 2755 * The package name indicating which application is out of compliance, if | 2708 /// The package name indicating which application is out of compliance, if |
| 2756 * applicable. | 2709 /// applicable. |
| 2757 */ | |
| 2758 core.String packageName; | 2710 core.String packageName; |
| 2759 /** | 2711 |
| 2760 * The name of the policy setting. This is the JSON field name of a top-level | 2712 /// The name of the policy setting. This is the JSON field name of a |
| 2761 * Policy field. | 2713 /// top-level Policy field. |
| 2762 */ | |
| 2763 core.String settingName; | 2714 core.String settingName; |
| 2764 | 2715 |
| 2765 NonComplianceDetail(); | 2716 NonComplianceDetail(); |
| 2766 | 2717 |
| 2767 NonComplianceDetail.fromJson(core.Map _json) { | 2718 NonComplianceDetail.fromJson(core.Map _json) { |
| 2768 if (_json.containsKey("currentValue")) { | 2719 if (_json.containsKey("currentValue")) { |
| 2769 currentValue = _json["currentValue"]; | 2720 currentValue = _json["currentValue"]; |
| 2770 } | 2721 } |
| 2771 if (_json.containsKey("fieldPath")) { | 2722 if (_json.containsKey("fieldPath")) { |
| 2772 fieldPath = _json["fieldPath"]; | 2723 fieldPath = _json["fieldPath"]; |
| 2773 } | 2724 } |
| 2774 if (_json.containsKey("installationFailureReason")) { | 2725 if (_json.containsKey("installationFailureReason")) { |
| 2775 installationFailureReason = _json["installationFailureReason"]; | 2726 installationFailureReason = _json["installationFailureReason"]; |
| 2776 } | 2727 } |
| 2777 if (_json.containsKey("nonComplianceReason")) { | 2728 if (_json.containsKey("nonComplianceReason")) { |
| 2778 nonComplianceReason = _json["nonComplianceReason"]; | 2729 nonComplianceReason = _json["nonComplianceReason"]; |
| 2779 } | 2730 } |
| 2780 if (_json.containsKey("packageName")) { | 2731 if (_json.containsKey("packageName")) { |
| 2781 packageName = _json["packageName"]; | 2732 packageName = _json["packageName"]; |
| 2782 } | 2733 } |
| 2783 if (_json.containsKey("settingName")) { | 2734 if (_json.containsKey("settingName")) { |
| 2784 settingName = _json["settingName"]; | 2735 settingName = _json["settingName"]; |
| 2785 } | 2736 } |
| 2786 } | 2737 } |
| 2787 | 2738 |
| 2788 core.Map<core.String, core.Object> toJson() { | 2739 core.Map<core.String, core.Object> toJson() { |
| 2789 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2740 final core.Map<core.String, core.Object> _json = |
| 2741 new core.Map<core.String, core.Object>(); |
| 2790 if (currentValue != null) { | 2742 if (currentValue != null) { |
| 2791 _json["currentValue"] = currentValue; | 2743 _json["currentValue"] = currentValue; |
| 2792 } | 2744 } |
| 2793 if (fieldPath != null) { | 2745 if (fieldPath != null) { |
| 2794 _json["fieldPath"] = fieldPath; | 2746 _json["fieldPath"] = fieldPath; |
| 2795 } | 2747 } |
| 2796 if (installationFailureReason != null) { | 2748 if (installationFailureReason != null) { |
| 2797 _json["installationFailureReason"] = installationFailureReason; | 2749 _json["installationFailureReason"] = installationFailureReason; |
| 2798 } | 2750 } |
| 2799 if (nonComplianceReason != null) { | 2751 if (nonComplianceReason != null) { |
| 2800 _json["nonComplianceReason"] = nonComplianceReason; | 2752 _json["nonComplianceReason"] = nonComplianceReason; |
| 2801 } | 2753 } |
| 2802 if (packageName != null) { | 2754 if (packageName != null) { |
| 2803 _json["packageName"] = packageName; | 2755 _json["packageName"] = packageName; |
| 2804 } | 2756 } |
| 2805 if (settingName != null) { | 2757 if (settingName != null) { |
| 2806 _json["settingName"] = settingName; | 2758 _json["settingName"] = settingName; |
| 2807 } | 2759 } |
| 2808 return _json; | 2760 return _json; |
| 2809 } | 2761 } |
| 2810 } | 2762 } |
| 2811 | 2763 |
| 2812 /** | 2764 /// A compliance rule condition which is satisfied if there exists any matching |
| 2813 * A compliance rule condition which is satisfied if there exists any matching | 2765 /// NonComplianceDetail for the device. A NonComplianceDetail matches a |
| 2814 * NonComplianceDetail for the device. A NonComplianceDetail matches a | 2766 /// NonComplianceDetailCondition if all the fields which are set within the |
| 2815 * NonComplianceDetailCondition if all the fields which are set within the | 2767 /// NonComplianceDetailCondition match the corresponding NonComplianceDetail |
| 2816 * NonComplianceDetailCondition match the corresponding NonComplianceDetail | 2768 /// fields. |
| 2817 * fields. | |
| 2818 */ | |
| 2819 class NonComplianceDetailCondition { | 2769 class NonComplianceDetailCondition { |
| 2820 /** | 2770 /// The reason the device is not in compliance with the setting. If not set, |
| 2821 * The reason the device is not in compliance with the setting. If not set, | 2771 /// then this condition matches any reason. |
| 2822 * then this condition matches any reason. | 2772 /// Possible string values are: |
| 2823 * Possible string values are: | 2773 /// - "NON_COMPLIANCE_REASON_UNSPECIFIED" : This value is disallowed. |
| 2824 * - "NON_COMPLIANCE_REASON_UNSPECIFIED" : This value is disallowed. | 2774 /// - "API_LEVEL" : The setting is not supported in the API level of Android |
| 2825 * - "API_LEVEL" : The setting is not supported in the API level of Android OS | 2775 /// OS version the device is running. |
| 2826 * version the device is running. | 2776 /// - "ADMIN_TYPE" : The admin type (profile owner, device owner, etc.) does |
| 2827 * - "ADMIN_TYPE" : The admin type (profile owner, device owner, etc.) does | 2777 /// not support the setting. |
| 2828 * not support the setting. | 2778 /// - "USER_ACTION" : The user has not taken required action to comply with |
| 2829 * - "USER_ACTION" : The user has not taken required action to comply with the | 2779 /// the setting. |
| 2830 * setting. | 2780 /// - "INVALID_VALUE" : The setting has an invalid value. |
| 2831 * - "INVALID_VALUE" : The setting has an invalid value. | 2781 /// - "APP_NOT_INSTALLED" : The application required to implement the policy |
| 2832 * - "APP_NOT_INSTALLED" : The application required to implement the policy is | 2782 /// is not installed. |
| 2833 * not installed. | 2783 /// - "UNSUPPORTED" : The policy is not supported by the version of Android |
| 2834 * - "UNSUPPORTED" : The policy is not supported by the version of Android | 2784 /// Device Policy on the device. |
| 2835 * Device Policy on the device. | 2785 /// - "APP_INSTALLED" : A blocked application is installed. |
| 2836 * - "APP_INSTALLED" : A blocked application is installed. | 2786 /// - "PENDING" : The setting was not applied yet at the time of the report, |
| 2837 * - "PENDING" : The setting was not applied yet at the time of the report, | 2787 /// but is expected to be applied shortly. |
| 2838 * but is expected to be applied shortly. | 2788 /// - "APP_INCOMPATIBLE" : The setting cannot be applied to the application |
| 2839 * - "APP_INCOMPATIBLE" : The setting cannot be applied to the application | 2789 /// because its target SDK version is not high enough. |
| 2840 * because its target SDK version is not high enough. | |
| 2841 */ | |
| 2842 core.String nonComplianceReason; | 2790 core.String nonComplianceReason; |
| 2843 /** | 2791 |
| 2844 * The package name indicating which application is out of compliance. If not | 2792 /// The package name indicating which application is out of compliance. If |
| 2845 * set, then this condition matches any package name. If this field is set, | 2793 /// not set, then this condition matches any package name. If this field is |
| 2846 * then setting_name must be unset or set to applications; otherwise, the | 2794 /// set, then setting_name must be unset or set to applications; otherwise, |
| 2847 * condition would never be satisfied. | 2795 /// the condition would never be satisfied. |
| 2848 */ | |
| 2849 core.String packageName; | 2796 core.String packageName; |
| 2850 /** | 2797 |
| 2851 * The name of the policy setting. This is the JSON field name of a top-level | 2798 /// The name of the policy setting. This is the JSON field name of a |
| 2852 * Policy field. If not set, then this condition matches any setting name. | 2799 /// top-level Policy field. If not set, then this condition matches any |
| 2853 */ | 2800 /// setting name. |
| 2854 core.String settingName; | 2801 core.String settingName; |
| 2855 | 2802 |
| 2856 NonComplianceDetailCondition(); | 2803 NonComplianceDetailCondition(); |
| 2857 | 2804 |
| 2858 NonComplianceDetailCondition.fromJson(core.Map _json) { | 2805 NonComplianceDetailCondition.fromJson(core.Map _json) { |
| 2859 if (_json.containsKey("nonComplianceReason")) { | 2806 if (_json.containsKey("nonComplianceReason")) { |
| 2860 nonComplianceReason = _json["nonComplianceReason"]; | 2807 nonComplianceReason = _json["nonComplianceReason"]; |
| 2861 } | 2808 } |
| 2862 if (_json.containsKey("packageName")) { | 2809 if (_json.containsKey("packageName")) { |
| 2863 packageName = _json["packageName"]; | 2810 packageName = _json["packageName"]; |
| 2864 } | 2811 } |
| 2865 if (_json.containsKey("settingName")) { | 2812 if (_json.containsKey("settingName")) { |
| 2866 settingName = _json["settingName"]; | 2813 settingName = _json["settingName"]; |
| 2867 } | 2814 } |
| 2868 } | 2815 } |
| 2869 | 2816 |
| 2870 core.Map<core.String, core.Object> toJson() { | 2817 core.Map<core.String, core.Object> toJson() { |
| 2871 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2818 final core.Map<core.String, core.Object> _json = |
| 2819 new core.Map<core.String, core.Object>(); |
| 2872 if (nonComplianceReason != null) { | 2820 if (nonComplianceReason != null) { |
| 2873 _json["nonComplianceReason"] = nonComplianceReason; | 2821 _json["nonComplianceReason"] = nonComplianceReason; |
| 2874 } | 2822 } |
| 2875 if (packageName != null) { | 2823 if (packageName != null) { |
| 2876 _json["packageName"] = packageName; | 2824 _json["packageName"] = packageName; |
| 2877 } | 2825 } |
| 2878 if (settingName != null) { | 2826 if (settingName != null) { |
| 2879 _json["settingName"] = settingName; | 2827 _json["settingName"] = settingName; |
| 2880 } | 2828 } |
| 2881 return _json; | 2829 return _json; |
| 2882 } | 2830 } |
| 2883 } | 2831 } |
| 2884 | 2832 |
| 2885 /** | 2833 /// This resource represents a long-running operation that is the result of a |
| 2886 * This resource represents a long-running operation that is the result of a | 2834 /// network API call. |
| 2887 * network API call. | |
| 2888 */ | |
| 2889 class Operation { | 2835 class Operation { |
| 2890 /** | 2836 /// If the value is false, it means the operation is still in progress. If |
| 2891 * If the value is false, it means the operation is still in progress. If | 2837 /// true, the operation is completed, and either error or response is |
| 2892 * true, the operation is completed, and either error or response is | 2838 /// available. |
| 2893 * available. | |
| 2894 */ | |
| 2895 core.bool done; | 2839 core.bool done; |
| 2896 /** The error result of the operation in case of failure or cancellation. */ | 2840 |
| 2841 /// The error result of the operation in case of failure or cancellation. |
| 2897 Status error; | 2842 Status error; |
| 2898 /** | 2843 |
| 2899 * Service-specific metadata associated with the operation. It typically | 2844 /// Service-specific metadata associated with the operation. It typically |
| 2900 * contains progress information and common metadata such as create time. Some | 2845 /// contains progress information and common metadata such as create time. |
| 2901 * services might not provide such metadata. Any method that returns a | 2846 /// Some services might not provide such metadata. Any method that returns a |
| 2902 * long-running operation should document the metadata type, if any. | 2847 /// long-running operation should document the metadata type, if any. |
| 2903 * | 2848 /// |
| 2904 * The values for Object must be JSON objects. It can consist of `num`, | 2849 /// The values for Object must be JSON objects. It can consist of `num`, |
| 2905 * `String`, `bool` and `null` as well as `Map` and `List` values. | 2850 /// `String`, `bool` and `null` as well as `Map` and `List` values. |
| 2906 */ | |
| 2907 core.Map<core.String, core.Object> metadata; | 2851 core.Map<core.String, core.Object> metadata; |
| 2908 /** | 2852 |
| 2909 * The server-assigned name, which is only unique within the same service that | 2853 /// The server-assigned name, which is only unique within the same service |
| 2910 * originally returns it. If you use the default HTTP mapping, the name should | 2854 /// that originally returns it. If you use the default HTTP mapping, the name |
| 2911 * have the format of operations/some/unique/name. | 2855 /// should have the format of operations/some/unique/name. |
| 2912 */ | |
| 2913 core.String name; | 2856 core.String name; |
| 2914 /** | 2857 |
| 2915 * The normal response of the operation in case of success. If the original | 2858 /// The normal response of the operation in case of success. If the original |
| 2916 * method returns no data on success, such as Delete, the response is | 2859 /// method returns no data on success, such as Delete, the response is |
| 2917 * google.protobuf.Empty. If the original method is standard | 2860 /// google.protobuf.Empty. If the original method is standard |
| 2918 * Get/Create/Update, the response should be the resource. For other methods, | 2861 /// Get/Create/Update, the response should be the resource. For other |
| 2919 * the response should have the type XxxResponse, where Xxx is the original | 2862 /// methods, the response should have the type XxxResponse, where Xxx is the |
| 2920 * method name. For example, if the original method name is TakeSnapshot(), | 2863 /// original method name. For example, if the original method name is |
| 2921 * the inferred response type is TakeSnapshotResponse. | 2864 /// TakeSnapshot(), the inferred response type is TakeSnapshotResponse. |
| 2922 * | 2865 /// |
| 2923 * The values for Object must be JSON objects. It can consist of `num`, | 2866 /// The values for Object must be JSON objects. It can consist of `num`, |
| 2924 * `String`, `bool` and `null` as well as `Map` and `List` values. | 2867 /// `String`, `bool` and `null` as well as `Map` and `List` values. |
| 2925 */ | |
| 2926 core.Map<core.String, core.Object> response; | 2868 core.Map<core.String, core.Object> response; |
| 2927 | 2869 |
| 2928 Operation(); | 2870 Operation(); |
| 2929 | 2871 |
| 2930 Operation.fromJson(core.Map _json) { | 2872 Operation.fromJson(core.Map _json) { |
| 2931 if (_json.containsKey("done")) { | 2873 if (_json.containsKey("done")) { |
| 2932 done = _json["done"]; | 2874 done = _json["done"]; |
| 2933 } | 2875 } |
| 2934 if (_json.containsKey("error")) { | 2876 if (_json.containsKey("error")) { |
| 2935 error = new Status.fromJson(_json["error"]); | 2877 error = new Status.fromJson(_json["error"]); |
| 2936 } | 2878 } |
| 2937 if (_json.containsKey("metadata")) { | 2879 if (_json.containsKey("metadata")) { |
| 2938 metadata = _json["metadata"]; | 2880 metadata = _json["metadata"]; |
| 2939 } | 2881 } |
| 2940 if (_json.containsKey("name")) { | 2882 if (_json.containsKey("name")) { |
| 2941 name = _json["name"]; | 2883 name = _json["name"]; |
| 2942 } | 2884 } |
| 2943 if (_json.containsKey("response")) { | 2885 if (_json.containsKey("response")) { |
| 2944 response = _json["response"]; | 2886 response = _json["response"]; |
| 2945 } | 2887 } |
| 2946 } | 2888 } |
| 2947 | 2889 |
| 2948 core.Map<core.String, core.Object> toJson() { | 2890 core.Map<core.String, core.Object> toJson() { |
| 2949 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2891 final core.Map<core.String, core.Object> _json = |
| 2892 new core.Map<core.String, core.Object>(); |
| 2950 if (done != null) { | 2893 if (done != null) { |
| 2951 _json["done"] = done; | 2894 _json["done"] = done; |
| 2952 } | 2895 } |
| 2953 if (error != null) { | 2896 if (error != null) { |
| 2954 _json["error"] = (error).toJson(); | 2897 _json["error"] = (error).toJson(); |
| 2955 } | 2898 } |
| 2956 if (metadata != null) { | 2899 if (metadata != null) { |
| 2957 _json["metadata"] = metadata; | 2900 _json["metadata"] = metadata; |
| 2958 } | 2901 } |
| 2959 if (name != null) { | 2902 if (name != null) { |
| 2960 _json["name"] = name; | 2903 _json["name"] = name; |
| 2961 } | 2904 } |
| 2962 if (response != null) { | 2905 if (response != null) { |
| 2963 _json["response"] = response; | 2906 _json["response"] = response; |
| 2964 } | 2907 } |
| 2965 return _json; | 2908 return _json; |
| 2966 } | 2909 } |
| 2967 } | 2910 } |
| 2968 | 2911 |
| 2969 /** Requirements for the password used to unlock a device. */ | 2912 /// Requirements for the password used to unlock a device. |
| 2970 class PasswordRequirements { | 2913 class PasswordRequirements { |
| 2971 /** | 2914 /// A device will be wiped after too many incorrect device-unlock passwords |
| 2972 * A device will be wiped after too many incorrect device-unlock passwords | 2915 /// have been entered. A value of 0 means there is no restriction. |
| 2973 * have been entered. A value of 0 means there is no restriction. | |
| 2974 */ | |
| 2975 core.int maximumFailedPasswordsForWipe; | 2916 core.int maximumFailedPasswordsForWipe; |
| 2976 /** Password expiration timeout. */ | 2917 |
| 2918 /// Password expiration timeout. |
| 2977 core.String passwordExpirationTimeout; | 2919 core.String passwordExpirationTimeout; |
| 2978 /** | 2920 |
| 2979 * The length of the password history. After setting this, the user will not | 2921 /// The length of the password history. After setting this, the user will not |
| 2980 * be able to enter a new password that is the same as any password in the | 2922 /// be able to enter a new password that is the same as any password in the |
| 2981 * history. A value of 0 means there is no restriction. | 2923 /// history. A value of 0 means there is no restriction. |
| 2982 */ | |
| 2983 core.int passwordHistoryLength; | 2924 core.int passwordHistoryLength; |
| 2984 /** | 2925 |
| 2985 * The minimum allowed password length. A value of 0 means there is no | 2926 /// The minimum allowed password length. A value of 0 means there is no |
| 2986 * restriction. Only enforced when password_quality is NUMERIC, | 2927 /// restriction. Only enforced when password_quality is NUMERIC, |
| 2987 * NUMERIC_COMPLEX, ALPHABETIC, ALPHANUMERIC, or COMPLEX. | 2928 /// NUMERIC_COMPLEX, ALPHABETIC, ALPHANUMERIC, or COMPLEX. |
| 2988 */ | |
| 2989 core.int passwordMinimumLength; | 2929 core.int passwordMinimumLength; |
| 2990 /** | 2930 |
| 2991 * Minimum number of letters required in the password. Only enforced when | 2931 /// Minimum number of letters required in the password. Only enforced when |
| 2992 * password_quality is COMPLEX. | 2932 /// password_quality is COMPLEX. |
| 2993 */ | |
| 2994 core.int passwordMinimumLetters; | 2933 core.int passwordMinimumLetters; |
| 2995 /** | 2934 |
| 2996 * Minimum number of lower case letters required in the password. Only | 2935 /// Minimum number of lower case letters required in the password. Only |
| 2997 * enforced when password_quality is COMPLEX. | 2936 /// enforced when password_quality is COMPLEX. |
| 2998 */ | |
| 2999 core.int passwordMinimumLowerCase; | 2937 core.int passwordMinimumLowerCase; |
| 3000 /** | 2938 |
| 3001 * Minimum number of non-letter characters (numerical digits or symbols) | 2939 /// Minimum number of non-letter characters (numerical digits or symbols) |
| 3002 * required in the password. Only enforced when password_quality is COMPLEX. | 2940 /// required in the password. Only enforced when password_quality is COMPLEX. |
| 3003 */ | |
| 3004 core.int passwordMinimumNonLetter; | 2941 core.int passwordMinimumNonLetter; |
| 3005 /** | 2942 |
| 3006 * Minimum number of numerical digits required in the password. Only enforced | 2943 /// Minimum number of numerical digits required in the password. Only |
| 3007 * when password_quality is COMPLEX. | 2944 /// enforced when password_quality is COMPLEX. |
| 3008 */ | |
| 3009 core.int passwordMinimumNumeric; | 2945 core.int passwordMinimumNumeric; |
| 3010 /** | 2946 |
| 3011 * Minimum number of symbols required in the password. Only enforced when | 2947 /// Minimum number of symbols required in the password. Only enforced when |
| 3012 * password_quality is COMPLEX. | 2948 /// password_quality is COMPLEX. |
| 3013 */ | |
| 3014 core.int passwordMinimumSymbols; | 2949 core.int passwordMinimumSymbols; |
| 3015 /** | 2950 |
| 3016 * Minimum number of upper case letters required in the password. Only | 2951 /// Minimum number of upper case letters required in the password. Only |
| 3017 * enforced when password_quality is COMPLEX. | 2952 /// enforced when password_quality is COMPLEX. |
| 3018 */ | |
| 3019 core.int passwordMinimumUpperCase; | 2953 core.int passwordMinimumUpperCase; |
| 3020 /** | 2954 |
| 3021 * The required password quality. | 2955 /// The required password quality. |
| 3022 * Possible string values are: | 2956 /// Possible string values are: |
| 3023 * - "PASSWORD_QUALITY_UNSPECIFIED" : There are no requirements for the | 2957 /// - "PASSWORD_QUALITY_UNSPECIFIED" : There are no requirements for the |
| 3024 * password. | 2958 /// password. |
| 3025 * - "SOMETHING" : There must be a password, but there are no restrictions on | 2959 /// - "SOMETHING" : There must be a password, but there are no restrictions |
| 3026 * its characters. | 2960 /// on its characters. |
| 3027 * - "NUMERIC" : The password must contain numeric characters. | 2961 /// - "NUMERIC" : The password must contain numeric characters. |
| 3028 * - "NUMERIC_COMPLEX" : The password must contain numeric characters with no | 2962 /// - "NUMERIC_COMPLEX" : The password must contain numeric characters with |
| 3029 * repeating (4444) or ordered (1234, 4321, 2468) sequences. | 2963 /// no repeating (4444) or ordered (1234, 4321, 2468) sequences. |
| 3030 * - "ALPHABETIC" : The password must contain alphabetic (or symbol) | 2964 /// - "ALPHABETIC" : The password must contain alphabetic (or symbol) |
| 3031 * characters. | 2965 /// characters. |
| 3032 * - "ALPHANUMERIC" : The password must contain at both numeric and alphabetic | 2966 /// - "ALPHANUMERIC" : The password must contain at both numeric and |
| 3033 * (or symbol) characters. | 2967 /// alphabetic (or symbol) characters. |
| 3034 * - "COMPLEX" : The password must contain at least a letter, a numerical | 2968 /// - "COMPLEX" : The password must contain at least a letter, a numerical |
| 3035 * digit and a special symbol. Other password constraints, for example, | 2969 /// digit and a special symbol. Other password constraints, for example, |
| 3036 * password_minimum_letters are enforced. | 2970 /// password_minimum_letters are enforced. |
| 3037 */ | |
| 3038 core.String passwordQuality; | 2971 core.String passwordQuality; |
| 3039 | 2972 |
| 3040 PasswordRequirements(); | 2973 PasswordRequirements(); |
| 3041 | 2974 |
| 3042 PasswordRequirements.fromJson(core.Map _json) { | 2975 PasswordRequirements.fromJson(core.Map _json) { |
| 3043 if (_json.containsKey("maximumFailedPasswordsForWipe")) { | 2976 if (_json.containsKey("maximumFailedPasswordsForWipe")) { |
| 3044 maximumFailedPasswordsForWipe = _json["maximumFailedPasswordsForWipe"]; | 2977 maximumFailedPasswordsForWipe = _json["maximumFailedPasswordsForWipe"]; |
| 3045 } | 2978 } |
| 3046 if (_json.containsKey("passwordExpirationTimeout")) { | 2979 if (_json.containsKey("passwordExpirationTimeout")) { |
| 3047 passwordExpirationTimeout = _json["passwordExpirationTimeout"]; | 2980 passwordExpirationTimeout = _json["passwordExpirationTimeout"]; |
| (...skipping 21 matching lines...) Expand all Loading... |
| 3069 } | 3002 } |
| 3070 if (_json.containsKey("passwordMinimumUpperCase")) { | 3003 if (_json.containsKey("passwordMinimumUpperCase")) { |
| 3071 passwordMinimumUpperCase = _json["passwordMinimumUpperCase"]; | 3004 passwordMinimumUpperCase = _json["passwordMinimumUpperCase"]; |
| 3072 } | 3005 } |
| 3073 if (_json.containsKey("passwordQuality")) { | 3006 if (_json.containsKey("passwordQuality")) { |
| 3074 passwordQuality = _json["passwordQuality"]; | 3007 passwordQuality = _json["passwordQuality"]; |
| 3075 } | 3008 } |
| 3076 } | 3009 } |
| 3077 | 3010 |
| 3078 core.Map<core.String, core.Object> toJson() { | 3011 core.Map<core.String, core.Object> toJson() { |
| 3079 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3012 final core.Map<core.String, core.Object> _json = |
| 3013 new core.Map<core.String, core.Object>(); |
| 3080 if (maximumFailedPasswordsForWipe != null) { | 3014 if (maximumFailedPasswordsForWipe != null) { |
| 3081 _json["maximumFailedPasswordsForWipe"] = maximumFailedPasswordsForWipe; | 3015 _json["maximumFailedPasswordsForWipe"] = maximumFailedPasswordsForWipe; |
| 3082 } | 3016 } |
| 3083 if (passwordExpirationTimeout != null) { | 3017 if (passwordExpirationTimeout != null) { |
| 3084 _json["passwordExpirationTimeout"] = passwordExpirationTimeout; | 3018 _json["passwordExpirationTimeout"] = passwordExpirationTimeout; |
| 3085 } | 3019 } |
| 3086 if (passwordHistoryLength != null) { | 3020 if (passwordHistoryLength != null) { |
| 3087 _json["passwordHistoryLength"] = passwordHistoryLength; | 3021 _json["passwordHistoryLength"] = passwordHistoryLength; |
| 3088 } | 3022 } |
| 3089 if (passwordMinimumLength != null) { | 3023 if (passwordMinimumLength != null) { |
| (...skipping 17 matching lines...) Expand all Loading... |
| 3107 if (passwordMinimumUpperCase != null) { | 3041 if (passwordMinimumUpperCase != null) { |
| 3108 _json["passwordMinimumUpperCase"] = passwordMinimumUpperCase; | 3042 _json["passwordMinimumUpperCase"] = passwordMinimumUpperCase; |
| 3109 } | 3043 } |
| 3110 if (passwordQuality != null) { | 3044 if (passwordQuality != null) { |
| 3111 _json["passwordQuality"] = passwordQuality; | 3045 _json["passwordQuality"] = passwordQuality; |
| 3112 } | 3046 } |
| 3113 return _json; | 3047 return _json; |
| 3114 } | 3048 } |
| 3115 } | 3049 } |
| 3116 | 3050 |
| 3117 /** Configuration for an Android permission and its grant state. */ | 3051 /// Configuration for an Android permission and its grant state. |
| 3118 class PermissionGrant { | 3052 class PermissionGrant { |
| 3119 /** The android permission, e.g. android.permission.READ_CALENDAR. */ | 3053 /// The android permission, e.g. android.permission.READ_CALENDAR. |
| 3120 core.String permission; | 3054 core.String permission; |
| 3121 /** | 3055 |
| 3122 * The policy for granting the permission. | 3056 /// The policy for granting the permission. |
| 3123 * Possible string values are: | 3057 /// Possible string values are: |
| 3124 * - "PERMISSION_POLICY_UNSPECIFIED" : Policy not specified. If no policy is | 3058 /// - "PERMISSION_POLICY_UNSPECIFIED" : Policy not specified. If no policy is |
| 3125 * specified for a permission at any level, then the PROMPT behavior is used | 3059 /// specified for a permission at any level, then the PROMPT behavior is used |
| 3126 * by default. | 3060 /// by default. |
| 3127 * - "PROMPT" : Prompt the user to grant a permission. | 3061 /// - "PROMPT" : Prompt the user to grant a permission. |
| 3128 * - "GRANT" : Automatically grant a permission. | 3062 /// - "GRANT" : Automatically grant a permission. |
| 3129 * - "DENY" : Automatically deny a permission. | 3063 /// - "DENY" : Automatically deny a permission. |
| 3130 */ | |
| 3131 core.String policy; | 3064 core.String policy; |
| 3132 | 3065 |
| 3133 PermissionGrant(); | 3066 PermissionGrant(); |
| 3134 | 3067 |
| 3135 PermissionGrant.fromJson(core.Map _json) { | 3068 PermissionGrant.fromJson(core.Map _json) { |
| 3136 if (_json.containsKey("permission")) { | 3069 if (_json.containsKey("permission")) { |
| 3137 permission = _json["permission"]; | 3070 permission = _json["permission"]; |
| 3138 } | 3071 } |
| 3139 if (_json.containsKey("policy")) { | 3072 if (_json.containsKey("policy")) { |
| 3140 policy = _json["policy"]; | 3073 policy = _json["policy"]; |
| 3141 } | 3074 } |
| 3142 } | 3075 } |
| 3143 | 3076 |
| 3144 core.Map<core.String, core.Object> toJson() { | 3077 core.Map<core.String, core.Object> toJson() { |
| 3145 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3078 final core.Map<core.String, core.Object> _json = |
| 3079 new core.Map<core.String, core.Object>(); |
| 3146 if (permission != null) { | 3080 if (permission != null) { |
| 3147 _json["permission"] = permission; | 3081 _json["permission"] = permission; |
| 3148 } | 3082 } |
| 3149 if (policy != null) { | 3083 if (policy != null) { |
| 3150 _json["policy"] = policy; | 3084 _json["policy"] = policy; |
| 3151 } | 3085 } |
| 3152 return _json; | 3086 return _json; |
| 3153 } | 3087 } |
| 3154 } | 3088 } |
| 3155 | 3089 |
| 3156 /** | 3090 /// A default activity for handling intents that match a particular intent |
| 3157 * A default activity for handling intents that match a particular intent | 3091 /// filter. |
| 3158 * filter. | |
| 3159 */ | |
| 3160 class PersistentPreferredActivity { | 3092 class PersistentPreferredActivity { |
| 3161 /** | 3093 /// The intent actions to match in the filter. If any actions are included in |
| 3162 * The intent actions to match in the filter. If any actions are included in | 3094 /// the filter, then an intent's action must be one of those values for it to |
| 3163 * the filter, then an intent's action must be one of those values for it to | 3095 /// match. If no actions are included, the intent action is ignored. |
| 3164 * match. If no actions are included, the intent action is ignored. | |
| 3165 */ | |
| 3166 core.List<core.String> actions; | 3096 core.List<core.String> actions; |
| 3167 /** | 3097 |
| 3168 * The intent categories to match in the filter. An intent includes the | 3098 /// The intent categories to match in the filter. An intent includes the |
| 3169 * categories that it requires, all of which must be included in the filter in | 3099 /// categories that it requires, all of which must be included in the filter |
| 3170 * order to match. In other words, adding a category to the filter has no | 3100 /// in order to match. In other words, adding a category to the filter has no |
| 3171 * impact on matching unless that category is specified in the intent. | 3101 /// impact on matching unless that category is specified in the intent. |
| 3172 */ | |
| 3173 core.List<core.String> categories; | 3102 core.List<core.String> categories; |
| 3174 /** | 3103 |
| 3175 * The activity that should be the default intent handler. This should be an | 3104 /// The activity that should be the default intent handler. This should be an |
| 3176 * Android component name, e.g. com.android.enterprise.app/.MainActivity. | 3105 /// Android component name, e.g. com.android.enterprise.app/.MainActivity. |
| 3177 * Alternatively, the value may be the package name of an app, which causes | 3106 /// Alternatively, the value may be the package name of an app, which causes |
| 3178 * Android Device Policy to choose an appropriate activity from the app to | 3107 /// Android Device Policy to choose an appropriate activity from the app to |
| 3179 * handle the intent. | 3108 /// handle the intent. |
| 3180 */ | |
| 3181 core.String receiverActivity; | 3109 core.String receiverActivity; |
| 3182 | 3110 |
| 3183 PersistentPreferredActivity(); | 3111 PersistentPreferredActivity(); |
| 3184 | 3112 |
| 3185 PersistentPreferredActivity.fromJson(core.Map _json) { | 3113 PersistentPreferredActivity.fromJson(core.Map _json) { |
| 3186 if (_json.containsKey("actions")) { | 3114 if (_json.containsKey("actions")) { |
| 3187 actions = _json["actions"]; | 3115 actions = _json["actions"]; |
| 3188 } | 3116 } |
| 3189 if (_json.containsKey("categories")) { | 3117 if (_json.containsKey("categories")) { |
| 3190 categories = _json["categories"]; | 3118 categories = _json["categories"]; |
| 3191 } | 3119 } |
| 3192 if (_json.containsKey("receiverActivity")) { | 3120 if (_json.containsKey("receiverActivity")) { |
| 3193 receiverActivity = _json["receiverActivity"]; | 3121 receiverActivity = _json["receiverActivity"]; |
| 3194 } | 3122 } |
| 3195 } | 3123 } |
| 3196 | 3124 |
| 3197 core.Map<core.String, core.Object> toJson() { | 3125 core.Map<core.String, core.Object> toJson() { |
| 3198 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3126 final core.Map<core.String, core.Object> _json = |
| 3127 new core.Map<core.String, core.Object>(); |
| 3199 if (actions != null) { | 3128 if (actions != null) { |
| 3200 _json["actions"] = actions; | 3129 _json["actions"] = actions; |
| 3201 } | 3130 } |
| 3202 if (categories != null) { | 3131 if (categories != null) { |
| 3203 _json["categories"] = categories; | 3132 _json["categories"] = categories; |
| 3204 } | 3133 } |
| 3205 if (receiverActivity != null) { | 3134 if (receiverActivity != null) { |
| 3206 _json["receiverActivity"] = receiverActivity; | 3135 _json["receiverActivity"] = receiverActivity; |
| 3207 } | 3136 } |
| 3208 return _json; | 3137 return _json; |
| 3209 } | 3138 } |
| 3210 } | 3139 } |
| 3211 | 3140 |
| 3212 /** A policy, which governs behavior for a device. */ | 3141 /// A policy, which governs behavior for a device. |
| 3213 class Policy { | 3142 class Policy { |
| 3214 /** Whether adding new users and profiles is disabled. */ | 3143 /// Whether adding new users and profiles is disabled. |
| 3215 core.bool addUserDisabled; | 3144 core.bool addUserDisabled; |
| 3216 /** Whether adjusting the master volume is disabled. */ | 3145 |
| 3146 /// Whether adjusting the master volume is disabled. |
| 3217 core.bool adjustVolumeDisabled; | 3147 core.bool adjustVolumeDisabled; |
| 3218 /** Policy applied to apps. */ | 3148 |
| 3149 /// Policy applied to apps. |
| 3219 core.List<ApplicationPolicy> applications; | 3150 core.List<ApplicationPolicy> applications; |
| 3220 /** | 3151 |
| 3221 * Whether applications other than the ones configured in applications are | 3152 /// Whether applications other than the ones configured in applications are |
| 3222 * blocked from being installed. When set, applications that were installed | 3153 /// blocked from being installed. When set, applications that were installed |
| 3223 * under a previous policy but no longer appear in the policy are | 3154 /// under a previous policy but no longer appear in the policy are |
| 3224 * automatically uninstalled. | 3155 /// automatically uninstalled. |
| 3225 */ | |
| 3226 core.bool blockApplicationsEnabled; | 3156 core.bool blockApplicationsEnabled; |
| 3227 /** Whether all cameras on the device are disabled. */ | 3157 |
| 3158 /// Whether all cameras on the device are disabled. |
| 3228 core.bool cameraDisabled; | 3159 core.bool cameraDisabled; |
| 3229 /** | 3160 |
| 3230 * Rules declaring which mitigating actions to take when a device is not | 3161 /// Rules declaring which mitigating actions to take when a device is not |
| 3231 * compliant with its policy. When the conditions for multiple rules are | 3162 /// compliant with its policy. When the conditions for multiple rules are |
| 3232 * satisfied, all of the mitigating actions for the rules are taken. There is | 3163 /// satisfied, all of the mitigating actions for the rules are taken. There |
| 3233 * a maximum limit of 100 rules. | 3164 /// is a maximum limit of 100 rules. |
| 3234 */ | |
| 3235 core.List<ComplianceRule> complianceRules; | 3165 core.List<ComplianceRule> complianceRules; |
| 3236 /** Whether the user is allowed to enable debugging features. */ | 3166 |
| 3167 /// Whether the user is allowed to enable debugging features. |
| 3237 core.bool debuggingFeaturesAllowed; | 3168 core.bool debuggingFeaturesAllowed; |
| 3238 /** | 3169 |
| 3239 * The default permission policy for requests for runtime permissions. | 3170 /// The default permission policy for requests for runtime permissions. |
| 3240 * Possible string values are: | 3171 /// Possible string values are: |
| 3241 * - "PERMISSION_POLICY_UNSPECIFIED" : Policy not specified. If no policy is | 3172 /// - "PERMISSION_POLICY_UNSPECIFIED" : Policy not specified. If no policy is |
| 3242 * specified for a permission at any level, then the PROMPT behavior is used | 3173 /// specified for a permission at any level, then the PROMPT behavior is used |
| 3243 * by default. | 3174 /// by default. |
| 3244 * - "PROMPT" : Prompt the user to grant a permission. | 3175 /// - "PROMPT" : Prompt the user to grant a permission. |
| 3245 * - "GRANT" : Automatically grant a permission. | 3176 /// - "GRANT" : Automatically grant a permission. |
| 3246 * - "DENY" : Automatically deny a permission. | 3177 /// - "DENY" : Automatically deny a permission. |
| 3247 */ | |
| 3248 core.String defaultPermissionPolicy; | 3178 core.String defaultPermissionPolicy; |
| 3249 /** Whether factory resetting from settings is disabled. */ | 3179 |
| 3180 /// Whether factory resetting from settings is disabled. |
| 3250 core.bool factoryResetDisabled; | 3181 core.bool factoryResetDisabled; |
| 3251 /** | 3182 |
| 3252 * Email addresses of device administrators for factory reset protection. When | 3183 /// Email addresses of device administrators for factory reset protection. |
| 3253 * the device is factory reset, it will require one of these admins to log in | 3184 /// When the device is factory reset, it will require one of these admins to |
| 3254 * with the Google account email and password to unlock the device. If no | 3185 /// log in with the Google account email and password to unlock the device. |
| 3255 * admins are specified, the device will not provide factory reset protection. | 3186 /// If no admins are specified, the device will not provide factory reset |
| 3256 */ | 3187 /// protection. |
| 3257 core.List<core.String> frpAdminEmails; | 3188 core.List<core.String> frpAdminEmails; |
| 3258 /** | 3189 |
| 3259 * Whether the user is allowed to have fun. Controls whether the Easter egg | 3190 /// Whether the user is allowed to have fun. Controls whether the Easter egg |
| 3260 * game in Settings is disabled. | 3191 /// game in Settings is disabled. |
| 3261 */ | |
| 3262 core.bool funDisabled; | 3192 core.bool funDisabled; |
| 3263 /** | 3193 |
| 3264 * Whether the user is allowed to enable the "Unknown Sources" setting, which | 3194 /// Whether the user is allowed to enable the "Unknown Sources" setting, |
| 3265 * allows installation of apps from unknown sources. | 3195 /// which allows installation of apps from unknown sources. |
| 3266 */ | |
| 3267 core.bool installUnknownSourcesAllowed; | 3196 core.bool installUnknownSourcesAllowed; |
| 3268 /** Whether the keyguard is disabled. */ | 3197 |
| 3198 /// Whether the keyguard is disabled. |
| 3269 core.bool keyguardDisabled; | 3199 core.bool keyguardDisabled; |
| 3270 /** | 3200 |
| 3271 * Maximum time in milliseconds for user activity until the device will lock. | 3201 /// Maximum time in milliseconds for user activity until the device will |
| 3272 * A value of 0 means there is no restriction. | 3202 /// lock. A value of 0 means there is no restriction. |
| 3273 */ | |
| 3274 core.String maximumTimeToLock; | 3203 core.String maximumTimeToLock; |
| 3275 /** Whether adding or removing accounts is disabled. */ | 3204 |
| 3205 /// Whether adding or removing accounts is disabled. |
| 3276 core.bool modifyAccountsDisabled; | 3206 core.bool modifyAccountsDisabled; |
| 3277 /** | 3207 |
| 3278 * The name of the policy in the form | 3208 /// The name of the policy in the form |
| 3279 * enterprises/{enterpriseId}/policies/{policyId} | 3209 /// enterprises/{enterpriseId}/policies/{policyId} |
| 3280 */ | |
| 3281 core.String name; | 3210 core.String name; |
| 3282 /** | 3211 |
| 3283 * Flag to specify if network escape hatch is enabled. If this flag has been | 3212 /// Flag to specify if network escape hatch is enabled. If this flag has been |
| 3284 * enabled then upon device boot if device has no network connection, then an | 3213 /// enabled then upon device boot if device has no network connection, then |
| 3285 * activity will be shown that allows the user to temporarily connect to a | 3214 /// an activity will be shown that allows the user to temporarily connect to |
| 3286 * network to fetch the latest policy. The launched activity will time out if | 3215 /// a network to fetch the latest policy. The launched activity will time out |
| 3287 * no network has been connected for a given while and will return to the | 3216 /// if no network has been connected for a given while and will return to the |
| 3288 * previous activity that was shown. | 3217 /// previous activity that was shown. |
| 3289 */ | |
| 3290 core.bool networkEscapeHatchEnabled; | 3218 core.bool networkEscapeHatchEnabled; |
| 3291 /** | 3219 |
| 3292 * Network configuration for the device. See configure networks for more | 3220 /// Network configuration for the device. See configure networks for more |
| 3293 * information. | 3221 /// information. |
| 3294 * | 3222 /// |
| 3295 * The values for Object must be JSON objects. It can consist of `num`, | 3223 /// The values for Object must be JSON objects. It can consist of `num`, |
| 3296 * `String`, `bool` and `null` as well as `Map` and `List` values. | 3224 /// `String`, `bool` and `null` as well as `Map` and `List` values. |
| 3297 */ | |
| 3298 core.Map<core.String, core.Object> openNetworkConfiguration; | 3225 core.Map<core.String, core.Object> openNetworkConfiguration; |
| 3299 /** Password requirements. */ | 3226 |
| 3227 /// Password requirements. |
| 3300 PasswordRequirements passwordRequirements; | 3228 PasswordRequirements passwordRequirements; |
| 3301 /** Default intent handler activities. */ | 3229 |
| 3230 /// Default intent handler activities. |
| 3302 core.List<PersistentPreferredActivity> persistentPreferredActivities; | 3231 core.List<PersistentPreferredActivity> persistentPreferredActivities; |
| 3303 /** Whether removing other users is disabled. */ | 3232 |
| 3233 /// Whether removing other users is disabled. |
| 3304 core.bool removeUserDisabled; | 3234 core.bool removeUserDisabled; |
| 3305 /** Whether rebooting the device into safe boot is disabled. */ | 3235 |
| 3236 /// Whether rebooting the device into safe boot is disabled. |
| 3306 core.bool safeBootDisabled; | 3237 core.bool safeBootDisabled; |
| 3307 /** Whether screen capture is disabled. */ | 3238 |
| 3239 /// Whether screen capture is disabled. |
| 3308 core.bool screenCaptureDisabled; | 3240 core.bool screenCaptureDisabled; |
| 3309 /** | 3241 |
| 3310 * Whether the status bar is disabled. This disables notifications, quick | 3242 /// Whether the status bar is disabled. This disables notifications, quick |
| 3311 * settings and other screen overlays that allow escape from full-screen mode. | 3243 /// settings and other screen overlays that allow escape from full-screen |
| 3312 */ | 3244 /// mode. |
| 3313 core.bool statusBarDisabled; | 3245 core.bool statusBarDisabled; |
| 3314 /** Status reporting settings */ | 3246 |
| 3247 /// Status reporting settings |
| 3315 StatusReportingSettings statusReportingSettings; | 3248 StatusReportingSettings statusReportingSettings; |
| 3316 /** | 3249 |
| 3317 * The battery plugged in modes for which the device stays on. When using this | 3250 /// The battery plugged in modes for which the device stays on. When using |
| 3318 * setting, it is recommended to clear maximum_time_to_lock so that the device | 3251 /// this setting, it is recommended to clear maximum_time_to_lock so that the |
| 3319 * doesn't lock itself while it stays on. | 3252 /// device doesn't lock itself while it stays on. |
| 3320 */ | |
| 3321 core.List<core.String> stayOnPluggedModes; | 3253 core.List<core.String> stayOnPluggedModes; |
| 3322 /** | 3254 |
| 3323 * The system update policy, which controls how OS updates are applied. If the | 3255 /// The system update policy, which controls how OS updates are applied. If |
| 3324 * update type is WINDOWED and the device has a device account, the update | 3256 /// the update type is WINDOWED and the device has a device account, the |
| 3325 * window will automatically apply to Play app updates as well. | 3257 /// update window will automatically apply to Play app updates as well. |
| 3326 */ | |
| 3327 SystemUpdate systemUpdate; | 3258 SystemUpdate systemUpdate; |
| 3328 /** | 3259 |
| 3329 * Whether the microphone is muted and adjusting microphone volume is | 3260 /// Whether the microphone is muted and adjusting microphone volume is |
| 3330 * disabled. | 3261 /// disabled. |
| 3331 */ | |
| 3332 core.bool unmuteMicrophoneDisabled; | 3262 core.bool unmuteMicrophoneDisabled; |
| 3333 /** | 3263 |
| 3334 * The version of the policy. This is a read-only field. The version is | 3264 /// The version of the policy. This is a read-only field. The version is |
| 3335 * incremented each time the policy is updated. | 3265 /// incremented each time the policy is updated. |
| 3336 */ | |
| 3337 core.String version; | 3266 core.String version; |
| 3338 | 3267 |
| 3268 /// Whether configuring WiFi access points is disabled. |
| 3269 core.bool wifiConfigDisabled; |
| 3270 |
| 3271 /// Whether WiFi networks defined in Open Network Configuration are locked so |
| 3272 /// they cannot be edited by the user. |
| 3273 core.bool wifiConfigsLockdownEnabled; |
| 3274 |
| 3339 Policy(); | 3275 Policy(); |
| 3340 | 3276 |
| 3341 Policy.fromJson(core.Map _json) { | 3277 Policy.fromJson(core.Map _json) { |
| 3342 if (_json.containsKey("addUserDisabled")) { | 3278 if (_json.containsKey("addUserDisabled")) { |
| 3343 addUserDisabled = _json["addUserDisabled"]; | 3279 addUserDisabled = _json["addUserDisabled"]; |
| 3344 } | 3280 } |
| 3345 if (_json.containsKey("adjustVolumeDisabled")) { | 3281 if (_json.containsKey("adjustVolumeDisabled")) { |
| 3346 adjustVolumeDisabled = _json["adjustVolumeDisabled"]; | 3282 adjustVolumeDisabled = _json["adjustVolumeDisabled"]; |
| 3347 } | 3283 } |
| 3348 if (_json.containsKey("applications")) { | 3284 if (_json.containsKey("applications")) { |
| 3349 applications = _json["applications"].map((value) => new ApplicationPolicy.
fromJson(value)).toList(); | 3285 applications = _json["applications"] |
| 3286 .map((value) => new ApplicationPolicy.fromJson(value)) |
| 3287 .toList(); |
| 3350 } | 3288 } |
| 3351 if (_json.containsKey("blockApplicationsEnabled")) { | 3289 if (_json.containsKey("blockApplicationsEnabled")) { |
| 3352 blockApplicationsEnabled = _json["blockApplicationsEnabled"]; | 3290 blockApplicationsEnabled = _json["blockApplicationsEnabled"]; |
| 3353 } | 3291 } |
| 3354 if (_json.containsKey("cameraDisabled")) { | 3292 if (_json.containsKey("cameraDisabled")) { |
| 3355 cameraDisabled = _json["cameraDisabled"]; | 3293 cameraDisabled = _json["cameraDisabled"]; |
| 3356 } | 3294 } |
| 3357 if (_json.containsKey("complianceRules")) { | 3295 if (_json.containsKey("complianceRules")) { |
| 3358 complianceRules = _json["complianceRules"].map((value) => new ComplianceRu
le.fromJson(value)).toList(); | 3296 complianceRules = _json["complianceRules"] |
| 3297 .map((value) => new ComplianceRule.fromJson(value)) |
| 3298 .toList(); |
| 3359 } | 3299 } |
| 3360 if (_json.containsKey("debuggingFeaturesAllowed")) { | 3300 if (_json.containsKey("debuggingFeaturesAllowed")) { |
| 3361 debuggingFeaturesAllowed = _json["debuggingFeaturesAllowed"]; | 3301 debuggingFeaturesAllowed = _json["debuggingFeaturesAllowed"]; |
| 3362 } | 3302 } |
| 3363 if (_json.containsKey("defaultPermissionPolicy")) { | 3303 if (_json.containsKey("defaultPermissionPolicy")) { |
| 3364 defaultPermissionPolicy = _json["defaultPermissionPolicy"]; | 3304 defaultPermissionPolicy = _json["defaultPermissionPolicy"]; |
| 3365 } | 3305 } |
| 3366 if (_json.containsKey("factoryResetDisabled")) { | 3306 if (_json.containsKey("factoryResetDisabled")) { |
| 3367 factoryResetDisabled = _json["factoryResetDisabled"]; | 3307 factoryResetDisabled = _json["factoryResetDisabled"]; |
| 3368 } | 3308 } |
| (...skipping 18 matching lines...) Expand all Loading... |
| 3387 if (_json.containsKey("name")) { | 3327 if (_json.containsKey("name")) { |
| 3388 name = _json["name"]; | 3328 name = _json["name"]; |
| 3389 } | 3329 } |
| 3390 if (_json.containsKey("networkEscapeHatchEnabled")) { | 3330 if (_json.containsKey("networkEscapeHatchEnabled")) { |
| 3391 networkEscapeHatchEnabled = _json["networkEscapeHatchEnabled"]; | 3331 networkEscapeHatchEnabled = _json["networkEscapeHatchEnabled"]; |
| 3392 } | 3332 } |
| 3393 if (_json.containsKey("openNetworkConfiguration")) { | 3333 if (_json.containsKey("openNetworkConfiguration")) { |
| 3394 openNetworkConfiguration = _json["openNetworkConfiguration"]; | 3334 openNetworkConfiguration = _json["openNetworkConfiguration"]; |
| 3395 } | 3335 } |
| 3396 if (_json.containsKey("passwordRequirements")) { | 3336 if (_json.containsKey("passwordRequirements")) { |
| 3397 passwordRequirements = new PasswordRequirements.fromJson(_json["passwordRe
quirements"]); | 3337 passwordRequirements = |
| 3338 new PasswordRequirements.fromJson(_json["passwordRequirements"]); |
| 3398 } | 3339 } |
| 3399 if (_json.containsKey("persistentPreferredActivities")) { | 3340 if (_json.containsKey("persistentPreferredActivities")) { |
| 3400 persistentPreferredActivities = _json["persistentPreferredActivities"].map
((value) => new PersistentPreferredActivity.fromJson(value)).toList(); | 3341 persistentPreferredActivities = _json["persistentPreferredActivities"] |
| 3342 .map((value) => new PersistentPreferredActivity.fromJson(value)) |
| 3343 .toList(); |
| 3401 } | 3344 } |
| 3402 if (_json.containsKey("removeUserDisabled")) { | 3345 if (_json.containsKey("removeUserDisabled")) { |
| 3403 removeUserDisabled = _json["removeUserDisabled"]; | 3346 removeUserDisabled = _json["removeUserDisabled"]; |
| 3404 } | 3347 } |
| 3405 if (_json.containsKey("safeBootDisabled")) { | 3348 if (_json.containsKey("safeBootDisabled")) { |
| 3406 safeBootDisabled = _json["safeBootDisabled"]; | 3349 safeBootDisabled = _json["safeBootDisabled"]; |
| 3407 } | 3350 } |
| 3408 if (_json.containsKey("screenCaptureDisabled")) { | 3351 if (_json.containsKey("screenCaptureDisabled")) { |
| 3409 screenCaptureDisabled = _json["screenCaptureDisabled"]; | 3352 screenCaptureDisabled = _json["screenCaptureDisabled"]; |
| 3410 } | 3353 } |
| 3411 if (_json.containsKey("statusBarDisabled")) { | 3354 if (_json.containsKey("statusBarDisabled")) { |
| 3412 statusBarDisabled = _json["statusBarDisabled"]; | 3355 statusBarDisabled = _json["statusBarDisabled"]; |
| 3413 } | 3356 } |
| 3414 if (_json.containsKey("statusReportingSettings")) { | 3357 if (_json.containsKey("statusReportingSettings")) { |
| 3415 statusReportingSettings = new StatusReportingSettings.fromJson(_json["stat
usReportingSettings"]); | 3358 statusReportingSettings = new StatusReportingSettings.fromJson( |
| 3359 _json["statusReportingSettings"]); |
| 3416 } | 3360 } |
| 3417 if (_json.containsKey("stayOnPluggedModes")) { | 3361 if (_json.containsKey("stayOnPluggedModes")) { |
| 3418 stayOnPluggedModes = _json["stayOnPluggedModes"]; | 3362 stayOnPluggedModes = _json["stayOnPluggedModes"]; |
| 3419 } | 3363 } |
| 3420 if (_json.containsKey("systemUpdate")) { | 3364 if (_json.containsKey("systemUpdate")) { |
| 3421 systemUpdate = new SystemUpdate.fromJson(_json["systemUpdate"]); | 3365 systemUpdate = new SystemUpdate.fromJson(_json["systemUpdate"]); |
| 3422 } | 3366 } |
| 3423 if (_json.containsKey("unmuteMicrophoneDisabled")) { | 3367 if (_json.containsKey("unmuteMicrophoneDisabled")) { |
| 3424 unmuteMicrophoneDisabled = _json["unmuteMicrophoneDisabled"]; | 3368 unmuteMicrophoneDisabled = _json["unmuteMicrophoneDisabled"]; |
| 3425 } | 3369 } |
| 3426 if (_json.containsKey("version")) { | 3370 if (_json.containsKey("version")) { |
| 3427 version = _json["version"]; | 3371 version = _json["version"]; |
| 3428 } | 3372 } |
| 3373 if (_json.containsKey("wifiConfigDisabled")) { |
| 3374 wifiConfigDisabled = _json["wifiConfigDisabled"]; |
| 3375 } |
| 3376 if (_json.containsKey("wifiConfigsLockdownEnabled")) { |
| 3377 wifiConfigsLockdownEnabled = _json["wifiConfigsLockdownEnabled"]; |
| 3378 } |
| 3429 } | 3379 } |
| 3430 | 3380 |
| 3431 core.Map<core.String, core.Object> toJson() { | 3381 core.Map<core.String, core.Object> toJson() { |
| 3432 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3382 final core.Map<core.String, core.Object> _json = |
| 3383 new core.Map<core.String, core.Object>(); |
| 3433 if (addUserDisabled != null) { | 3384 if (addUserDisabled != null) { |
| 3434 _json["addUserDisabled"] = addUserDisabled; | 3385 _json["addUserDisabled"] = addUserDisabled; |
| 3435 } | 3386 } |
| 3436 if (adjustVolumeDisabled != null) { | 3387 if (adjustVolumeDisabled != null) { |
| 3437 _json["adjustVolumeDisabled"] = adjustVolumeDisabled; | 3388 _json["adjustVolumeDisabled"] = adjustVolumeDisabled; |
| 3438 } | 3389 } |
| 3439 if (applications != null) { | 3390 if (applications != null) { |
| 3440 _json["applications"] = applications.map((value) => (value).toJson()).toLi
st(); | 3391 _json["applications"] = |
| 3392 applications.map((value) => (value).toJson()).toList(); |
| 3441 } | 3393 } |
| 3442 if (blockApplicationsEnabled != null) { | 3394 if (blockApplicationsEnabled != null) { |
| 3443 _json["blockApplicationsEnabled"] = blockApplicationsEnabled; | 3395 _json["blockApplicationsEnabled"] = blockApplicationsEnabled; |
| 3444 } | 3396 } |
| 3445 if (cameraDisabled != null) { | 3397 if (cameraDisabled != null) { |
| 3446 _json["cameraDisabled"] = cameraDisabled; | 3398 _json["cameraDisabled"] = cameraDisabled; |
| 3447 } | 3399 } |
| 3448 if (complianceRules != null) { | 3400 if (complianceRules != null) { |
| 3449 _json["complianceRules"] = complianceRules.map((value) => (value).toJson()
).toList(); | 3401 _json["complianceRules"] = |
| 3402 complianceRules.map((value) => (value).toJson()).toList(); |
| 3450 } | 3403 } |
| 3451 if (debuggingFeaturesAllowed != null) { | 3404 if (debuggingFeaturesAllowed != null) { |
| 3452 _json["debuggingFeaturesAllowed"] = debuggingFeaturesAllowed; | 3405 _json["debuggingFeaturesAllowed"] = debuggingFeaturesAllowed; |
| 3453 } | 3406 } |
| 3454 if (defaultPermissionPolicy != null) { | 3407 if (defaultPermissionPolicy != null) { |
| 3455 _json["defaultPermissionPolicy"] = defaultPermissionPolicy; | 3408 _json["defaultPermissionPolicy"] = defaultPermissionPolicy; |
| 3456 } | 3409 } |
| 3457 if (factoryResetDisabled != null) { | 3410 if (factoryResetDisabled != null) { |
| 3458 _json["factoryResetDisabled"] = factoryResetDisabled; | 3411 _json["factoryResetDisabled"] = factoryResetDisabled; |
| 3459 } | 3412 } |
| (...skipping 21 matching lines...) Expand all Loading... |
| 3481 if (networkEscapeHatchEnabled != null) { | 3434 if (networkEscapeHatchEnabled != null) { |
| 3482 _json["networkEscapeHatchEnabled"] = networkEscapeHatchEnabled; | 3435 _json["networkEscapeHatchEnabled"] = networkEscapeHatchEnabled; |
| 3483 } | 3436 } |
| 3484 if (openNetworkConfiguration != null) { | 3437 if (openNetworkConfiguration != null) { |
| 3485 _json["openNetworkConfiguration"] = openNetworkConfiguration; | 3438 _json["openNetworkConfiguration"] = openNetworkConfiguration; |
| 3486 } | 3439 } |
| 3487 if (passwordRequirements != null) { | 3440 if (passwordRequirements != null) { |
| 3488 _json["passwordRequirements"] = (passwordRequirements).toJson(); | 3441 _json["passwordRequirements"] = (passwordRequirements).toJson(); |
| 3489 } | 3442 } |
| 3490 if (persistentPreferredActivities != null) { | 3443 if (persistentPreferredActivities != null) { |
| 3491 _json["persistentPreferredActivities"] = persistentPreferredActivities.map
((value) => (value).toJson()).toList(); | 3444 _json["persistentPreferredActivities"] = persistentPreferredActivities |
| 3445 .map((value) => (value).toJson()) |
| 3446 .toList(); |
| 3492 } | 3447 } |
| 3493 if (removeUserDisabled != null) { | 3448 if (removeUserDisabled != null) { |
| 3494 _json["removeUserDisabled"] = removeUserDisabled; | 3449 _json["removeUserDisabled"] = removeUserDisabled; |
| 3495 } | 3450 } |
| 3496 if (safeBootDisabled != null) { | 3451 if (safeBootDisabled != null) { |
| 3497 _json["safeBootDisabled"] = safeBootDisabled; | 3452 _json["safeBootDisabled"] = safeBootDisabled; |
| 3498 } | 3453 } |
| 3499 if (screenCaptureDisabled != null) { | 3454 if (screenCaptureDisabled != null) { |
| 3500 _json["screenCaptureDisabled"] = screenCaptureDisabled; | 3455 _json["screenCaptureDisabled"] = screenCaptureDisabled; |
| 3501 } | 3456 } |
| 3502 if (statusBarDisabled != null) { | 3457 if (statusBarDisabled != null) { |
| 3503 _json["statusBarDisabled"] = statusBarDisabled; | 3458 _json["statusBarDisabled"] = statusBarDisabled; |
| 3504 } | 3459 } |
| 3505 if (statusReportingSettings != null) { | 3460 if (statusReportingSettings != null) { |
| 3506 _json["statusReportingSettings"] = (statusReportingSettings).toJson(); | 3461 _json["statusReportingSettings"] = (statusReportingSettings).toJson(); |
| 3507 } | 3462 } |
| 3508 if (stayOnPluggedModes != null) { | 3463 if (stayOnPluggedModes != null) { |
| 3509 _json["stayOnPluggedModes"] = stayOnPluggedModes; | 3464 _json["stayOnPluggedModes"] = stayOnPluggedModes; |
| 3510 } | 3465 } |
| 3511 if (systemUpdate != null) { | 3466 if (systemUpdate != null) { |
| 3512 _json["systemUpdate"] = (systemUpdate).toJson(); | 3467 _json["systemUpdate"] = (systemUpdate).toJson(); |
| 3513 } | 3468 } |
| 3514 if (unmuteMicrophoneDisabled != null) { | 3469 if (unmuteMicrophoneDisabled != null) { |
| 3515 _json["unmuteMicrophoneDisabled"] = unmuteMicrophoneDisabled; | 3470 _json["unmuteMicrophoneDisabled"] = unmuteMicrophoneDisabled; |
| 3516 } | 3471 } |
| 3517 if (version != null) { | 3472 if (version != null) { |
| 3518 _json["version"] = version; | 3473 _json["version"] = version; |
| 3519 } | 3474 } |
| 3475 if (wifiConfigDisabled != null) { |
| 3476 _json["wifiConfigDisabled"] = wifiConfigDisabled; |
| 3477 } |
| 3478 if (wifiConfigsLockdownEnabled != null) { |
| 3479 _json["wifiConfigsLockdownEnabled"] = wifiConfigsLockdownEnabled; |
| 3480 } |
| 3520 return _json; | 3481 return _json; |
| 3521 } | 3482 } |
| 3522 } | 3483 } |
| 3523 | 3484 |
| 3524 /** A power management event. */ | 3485 /// A power management event. |
| 3525 class PowerManagementEvent { | 3486 class PowerManagementEvent { |
| 3526 /** For BATTERY_LEVEL_COLLECTED events, the battery level as a percentage. */ | 3487 /// For BATTERY_LEVEL_COLLECTED events, the battery level as a percentage. |
| 3527 core.double batteryLevel; | 3488 core.double batteryLevel; |
| 3528 /** The creation time of the event. */ | 3489 |
| 3490 /// The creation time of the event. |
| 3529 core.String createTime; | 3491 core.String createTime; |
| 3530 /** | 3492 |
| 3531 * Event type. | 3493 /// Event type. |
| 3532 * Possible string values are: | 3494 /// Possible string values are: |
| 3533 * - "POWER_MANAGEMENT_EVENT_TYPE_UNSPECIFIED" : Unspecified. No events have | 3495 /// - "POWER_MANAGEMENT_EVENT_TYPE_UNSPECIFIED" : Unspecified. No events have |
| 3534 * this type. | 3496 /// this type. |
| 3535 * - "BATTERY_LEVEL_COLLECTED" : Battery level was measured. | 3497 /// - "BATTERY_LEVEL_COLLECTED" : Battery level was measured. |
| 3536 * - "POWER_CONNECTED" : The device started charging. | 3498 /// - "POWER_CONNECTED" : The device started charging. |
| 3537 * - "POWER_DISCONNECTED" : The device stopped charging. | 3499 /// - "POWER_DISCONNECTED" : The device stopped charging. |
| 3538 * - "BATTERY_LOW" : The device entered low-power mode. | 3500 /// - "BATTERY_LOW" : The device entered low-power mode. |
| 3539 * - "BATTERY_OKAY" : The device exited low-power mode. | 3501 /// - "BATTERY_OKAY" : The device exited low-power mode. |
| 3540 * - "BOOT_COMPLETED" : The device booted. | 3502 /// - "BOOT_COMPLETED" : The device booted. |
| 3541 * - "SHUTDOWN" : The device shut down. | 3503 /// - "SHUTDOWN" : The device shut down. |
| 3542 */ | |
| 3543 core.String eventType; | 3504 core.String eventType; |
| 3544 | 3505 |
| 3545 PowerManagementEvent(); | 3506 PowerManagementEvent(); |
| 3546 | 3507 |
| 3547 PowerManagementEvent.fromJson(core.Map _json) { | 3508 PowerManagementEvent.fromJson(core.Map _json) { |
| 3548 if (_json.containsKey("batteryLevel")) { | 3509 if (_json.containsKey("batteryLevel")) { |
| 3549 batteryLevel = _json["batteryLevel"]; | 3510 batteryLevel = _json["batteryLevel"]; |
| 3550 } | 3511 } |
| 3551 if (_json.containsKey("createTime")) { | 3512 if (_json.containsKey("createTime")) { |
| 3552 createTime = _json["createTime"]; | 3513 createTime = _json["createTime"]; |
| 3553 } | 3514 } |
| 3554 if (_json.containsKey("eventType")) { | 3515 if (_json.containsKey("eventType")) { |
| 3555 eventType = _json["eventType"]; | 3516 eventType = _json["eventType"]; |
| 3556 } | 3517 } |
| 3557 } | 3518 } |
| 3558 | 3519 |
| 3559 core.Map<core.String, core.Object> toJson() { | 3520 core.Map<core.String, core.Object> toJson() { |
| 3560 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3521 final core.Map<core.String, core.Object> _json = |
| 3522 new core.Map<core.String, core.Object>(); |
| 3561 if (batteryLevel != null) { | 3523 if (batteryLevel != null) { |
| 3562 _json["batteryLevel"] = batteryLevel; | 3524 _json["batteryLevel"] = batteryLevel; |
| 3563 } | 3525 } |
| 3564 if (createTime != null) { | 3526 if (createTime != null) { |
| 3565 _json["createTime"] = createTime; | 3527 _json["createTime"] = createTime; |
| 3566 } | 3528 } |
| 3567 if (eventType != null) { | 3529 if (eventType != null) { |
| 3568 _json["eventType"] = eventType; | 3530 _json["eventType"] = eventType; |
| 3569 } | 3531 } |
| 3570 return _json; | 3532 return _json; |
| 3571 } | 3533 } |
| 3572 } | 3534 } |
| 3573 | 3535 |
| 3574 /** An enterprise signup URL. */ | 3536 /// An enterprise signup URL. |
| 3575 class SignupUrl { | 3537 class SignupUrl { |
| 3576 /** | 3538 /// The name of the resource. This must be included in the create enterprise |
| 3577 * The name of the resource. This must be included in the create enterprise | 3539 /// request at the end of the signup flow. |
| 3578 * request at the end of the signup flow. | |
| 3579 */ | |
| 3580 core.String name; | 3540 core.String name; |
| 3581 /** | 3541 |
| 3582 * A URL under which the Admin can sign up for an enterprise. The page pointed | 3542 /// A URL under which the Admin can sign up for an enterprise. The page |
| 3583 * to cannot be rendered in an iframe. | 3543 /// pointed to cannot be rendered in an iframe. |
| 3584 */ | |
| 3585 core.String url; | 3544 core.String url; |
| 3586 | 3545 |
| 3587 SignupUrl(); | 3546 SignupUrl(); |
| 3588 | 3547 |
| 3589 SignupUrl.fromJson(core.Map _json) { | 3548 SignupUrl.fromJson(core.Map _json) { |
| 3590 if (_json.containsKey("name")) { | 3549 if (_json.containsKey("name")) { |
| 3591 name = _json["name"]; | 3550 name = _json["name"]; |
| 3592 } | 3551 } |
| 3593 if (_json.containsKey("url")) { | 3552 if (_json.containsKey("url")) { |
| 3594 url = _json["url"]; | 3553 url = _json["url"]; |
| 3595 } | 3554 } |
| 3596 } | 3555 } |
| 3597 | 3556 |
| 3598 core.Map<core.String, core.Object> toJson() { | 3557 core.Map<core.String, core.Object> toJson() { |
| 3599 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3558 final core.Map<core.String, core.Object> _json = |
| 3559 new core.Map<core.String, core.Object>(); |
| 3600 if (name != null) { | 3560 if (name != null) { |
| 3601 _json["name"] = name; | 3561 _json["name"] = name; |
| 3602 } | 3562 } |
| 3603 if (url != null) { | 3563 if (url != null) { |
| 3604 _json["url"] = url; | 3564 _json["url"] = url; |
| 3605 } | 3565 } |
| 3606 return _json; | 3566 return _json; |
| 3607 } | 3567 } |
| 3608 } | 3568 } |
| 3609 | 3569 |
| 3610 /** Information about device software. */ | 3570 /// Information about device software. |
| 3611 class SoftwareInfo { | 3571 class SoftwareInfo { |
| 3612 /** | 3572 /// Android build Id string meant for displaying to the user, e.g. |
| 3613 * Android build Id string meant for displaying to the user, e.g. | 3573 /// shamu-userdebug 6.0.1 MOB30I 2756745 dev-keys. |
| 3614 * shamu-userdebug 6.0.1 MOB30I 2756745 dev-keys. | |
| 3615 */ | |
| 3616 core.String androidBuildNumber; | 3574 core.String androidBuildNumber; |
| 3617 /** Build time. */ | 3575 |
| 3576 /// Build time. |
| 3618 core.String androidBuildTime; | 3577 core.String androidBuildTime; |
| 3619 /** The user visible Android version string, e.g. 6.0.1. */ | 3578 |
| 3579 /// The user visible Android version string, e.g. 6.0.1. |
| 3620 core.String androidVersion; | 3580 core.String androidVersion; |
| 3621 /** The system bootloader version number, e.g. 0.6.7. */ | 3581 |
| 3582 /// The system bootloader version number, e.g. 0.6.7. |
| 3622 core.String bootloaderVersion; | 3583 core.String bootloaderVersion; |
| 3623 /** Kernel version, e.g. 2.6.32.9-g103d848. */ | 3584 |
| 3585 /// Kernel version, e.g. 2.6.32.9-g103d848. |
| 3624 core.String deviceKernelVersion; | 3586 core.String deviceKernelVersion; |
| 3625 /** Security patch level, e.g. 2016-05-01. */ | 3587 |
| 3588 /// Security patch level, e.g. 2016-05-01. |
| 3626 core.String securityPatchLevel; | 3589 core.String securityPatchLevel; |
| 3627 | 3590 |
| 3628 SoftwareInfo(); | 3591 SoftwareInfo(); |
| 3629 | 3592 |
| 3630 SoftwareInfo.fromJson(core.Map _json) { | 3593 SoftwareInfo.fromJson(core.Map _json) { |
| 3631 if (_json.containsKey("androidBuildNumber")) { | 3594 if (_json.containsKey("androidBuildNumber")) { |
| 3632 androidBuildNumber = _json["androidBuildNumber"]; | 3595 androidBuildNumber = _json["androidBuildNumber"]; |
| 3633 } | 3596 } |
| 3634 if (_json.containsKey("androidBuildTime")) { | 3597 if (_json.containsKey("androidBuildTime")) { |
| 3635 androidBuildTime = _json["androidBuildTime"]; | 3598 androidBuildTime = _json["androidBuildTime"]; |
| 3636 } | 3599 } |
| 3637 if (_json.containsKey("androidVersion")) { | 3600 if (_json.containsKey("androidVersion")) { |
| 3638 androidVersion = _json["androidVersion"]; | 3601 androidVersion = _json["androidVersion"]; |
| 3639 } | 3602 } |
| 3640 if (_json.containsKey("bootloaderVersion")) { | 3603 if (_json.containsKey("bootloaderVersion")) { |
| 3641 bootloaderVersion = _json["bootloaderVersion"]; | 3604 bootloaderVersion = _json["bootloaderVersion"]; |
| 3642 } | 3605 } |
| 3643 if (_json.containsKey("deviceKernelVersion")) { | 3606 if (_json.containsKey("deviceKernelVersion")) { |
| 3644 deviceKernelVersion = _json["deviceKernelVersion"]; | 3607 deviceKernelVersion = _json["deviceKernelVersion"]; |
| 3645 } | 3608 } |
| 3646 if (_json.containsKey("securityPatchLevel")) { | 3609 if (_json.containsKey("securityPatchLevel")) { |
| 3647 securityPatchLevel = _json["securityPatchLevel"]; | 3610 securityPatchLevel = _json["securityPatchLevel"]; |
| 3648 } | 3611 } |
| 3649 } | 3612 } |
| 3650 | 3613 |
| 3651 core.Map<core.String, core.Object> toJson() { | 3614 core.Map<core.String, core.Object> toJson() { |
| 3652 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3615 final core.Map<core.String, core.Object> _json = |
| 3616 new core.Map<core.String, core.Object>(); |
| 3653 if (androidBuildNumber != null) { | 3617 if (androidBuildNumber != null) { |
| 3654 _json["androidBuildNumber"] = androidBuildNumber; | 3618 _json["androidBuildNumber"] = androidBuildNumber; |
| 3655 } | 3619 } |
| 3656 if (androidBuildTime != null) { | 3620 if (androidBuildTime != null) { |
| 3657 _json["androidBuildTime"] = androidBuildTime; | 3621 _json["androidBuildTime"] = androidBuildTime; |
| 3658 } | 3622 } |
| 3659 if (androidVersion != null) { | 3623 if (androidVersion != null) { |
| 3660 _json["androidVersion"] = androidVersion; | 3624 _json["androidVersion"] = androidVersion; |
| 3661 } | 3625 } |
| 3662 if (bootloaderVersion != null) { | 3626 if (bootloaderVersion != null) { |
| 3663 _json["bootloaderVersion"] = bootloaderVersion; | 3627 _json["bootloaderVersion"] = bootloaderVersion; |
| 3664 } | 3628 } |
| 3665 if (deviceKernelVersion != null) { | 3629 if (deviceKernelVersion != null) { |
| 3666 _json["deviceKernelVersion"] = deviceKernelVersion; | 3630 _json["deviceKernelVersion"] = deviceKernelVersion; |
| 3667 } | 3631 } |
| 3668 if (securityPatchLevel != null) { | 3632 if (securityPatchLevel != null) { |
| 3669 _json["securityPatchLevel"] = securityPatchLevel; | 3633 _json["securityPatchLevel"] = securityPatchLevel; |
| 3670 } | 3634 } |
| 3671 return _json; | 3635 return _json; |
| 3672 } | 3636 } |
| 3673 } | 3637 } |
| 3674 | 3638 |
| 3675 /** | 3639 /// The Status type defines a logical error model that is suitable for |
| 3676 * The Status type defines a logical error model that is suitable for different | 3640 /// different programming environments, including REST APIs and RPC APIs. It is |
| 3677 * programming environments, including REST APIs and RPC APIs. It is used by | 3641 /// used by gRPC (https://github.com/grpc). The error model is designed to be: |
| 3678 * gRPC (https://github.com/grpc). The error model is designed to be: | 3642 /// Simple to use and understand for most users |
| 3679 * Simple to use and understand for most users | 3643 /// Flexible enough to meet unexpected needsOverviewThe Status message contains |
| 3680 * Flexible enough to meet unexpected needsOverviewThe Status message contains | 3644 /// three pieces of data: error code, error message, and error details. The |
| 3681 * three pieces of data: error code, error message, and error details. The error | 3645 /// error code should be an enum value of google.rpc.Code, but it may accept |
| 3682 * code should be an enum value of google.rpc.Code, but it may accept additional | 3646 /// additional error codes if needed. The error message should be a |
| 3683 * error codes if needed. The error message should be a developer-facing English | 3647 /// developer-facing English message that helps developers understand and |
| 3684 * message that helps developers understand and resolve the error. If a | 3648 /// resolve the error. If a localized user-facing error message is needed, put |
| 3685 * localized user-facing error message is needed, put the localized message in | 3649 /// the localized message in the error details or localize it in the client. |
| 3686 * the error details or localize it in the client. The optional error details | 3650 /// The optional error details may contain arbitrary information about the |
| 3687 * may contain arbitrary information about the error. There is a predefined set | 3651 /// error. There is a predefined set of error detail types in the package |
| 3688 * of error detail types in the package google.rpc that can be used for common | 3652 /// google.rpc that can be used for common error conditions.Language mappingThe |
| 3689 * error conditions.Language mappingThe Status message is the logical | 3653 /// Status message is the logical representation of the error model, but it is |
| 3690 * representation of the error model, but it is not necessarily the actual wire | 3654 /// not necessarily the actual wire format. When the Status message is exposed |
| 3691 * format. When the Status message is exposed in different client libraries and | 3655 /// in different client libraries and different wire protocols, it can be |
| 3692 * different wire protocols, it can be mapped differently. For example, it will | 3656 /// mapped differently. For example, it will likely be mapped to some |
| 3693 * likely be mapped to some exceptions in Java, but more likely mapped to some | 3657 /// exceptions in Java, but more likely mapped to some error codes in C.Other |
| 3694 * error codes in C.Other usesThe error model and the Status message can be used | 3658 /// usesThe error model and the Status message can be used in a variety of |
| 3695 * in a variety of environments, either with or without APIs, to provide a | 3659 /// environments, either with or without APIs, to provide a consistent |
| 3696 * consistent developer experience across different environments.Example uses of | 3660 /// developer experience across different environments.Example uses of this |
| 3697 * this error model include: | 3661 /// error model include: |
| 3698 * Partial errors. If a service needs to return partial errors to the client, it | 3662 /// Partial errors. If a service needs to return partial errors to the client, |
| 3699 * may embed the Status in the normal response to indicate the partial errors. | 3663 /// it may embed the Status in the normal response to indicate the partial |
| 3700 * Workflow errors. A typical workflow has multiple steps. Each step may have a | 3664 /// errors. |
| 3701 * Status message for error reporting. | 3665 /// Workflow errors. A typical workflow has multiple steps. Each step may have |
| 3702 * Batch operations. If a client uses batch request and batch response, the | 3666 /// a Status message for error reporting. |
| 3703 * Status message should be used directly inside batch response, one for each | 3667 /// Batch operations. If a client uses batch request and batch response, the |
| 3704 * error sub-response. | 3668 /// Status message should be used directly inside batch response, one for each |
| 3705 * Asynchronous operations. If an API call embeds asynchronous operation results | 3669 /// error sub-response. |
| 3706 * in its response, the status of those operations should be represented | 3670 /// Asynchronous operations. If an API call embeds asynchronous operation |
| 3707 * directly using the Status message. | 3671 /// results in its response, the status of those operations should be |
| 3708 * Logging. If some API errors are stored in logs, the message Status could be | 3672 /// represented directly using the Status message. |
| 3709 * used directly after any stripping needed for security/privacy reasons. | 3673 /// Logging. If some API errors are stored in logs, the message Status could be |
| 3710 */ | 3674 /// used directly after any stripping needed for security/privacy reasons. |
| 3711 class Status { | 3675 class Status { |
| 3712 /** The status code, which should be an enum value of google.rpc.Code. */ | 3676 /// The status code, which should be an enum value of google.rpc.Code. |
| 3713 core.int code; | 3677 core.int code; |
| 3714 /** | 3678 |
| 3715 * A list of messages that carry the error details. There is a common set of | 3679 /// A list of messages that carry the error details. There is a common set of |
| 3716 * message types for APIs to use. | 3680 /// message types for APIs to use. |
| 3717 * | 3681 /// |
| 3718 * The values for Object must be JSON objects. It can consist of `num`, | 3682 /// The values for Object must be JSON objects. It can consist of `num`, |
| 3719 * `String`, `bool` and `null` as well as `Map` and `List` values. | 3683 /// `String`, `bool` and `null` as well as `Map` and `List` values. |
| 3720 */ | |
| 3721 core.List<core.Map<core.String, core.Object>> details; | 3684 core.List<core.Map<core.String, core.Object>> details; |
| 3722 /** | 3685 |
| 3723 * A developer-facing error message, which should be in English. Any | 3686 /// A developer-facing error message, which should be in English. Any |
| 3724 * user-facing error message should be localized and sent in the | 3687 /// user-facing error message should be localized and sent in the |
| 3725 * google.rpc.Status.details field, or localized by the client. | 3688 /// google.rpc.Status.details field, or localized by the client. |
| 3726 */ | |
| 3727 core.String message; | 3689 core.String message; |
| 3728 | 3690 |
| 3729 Status(); | 3691 Status(); |
| 3730 | 3692 |
| 3731 Status.fromJson(core.Map _json) { | 3693 Status.fromJson(core.Map _json) { |
| 3732 if (_json.containsKey("code")) { | 3694 if (_json.containsKey("code")) { |
| 3733 code = _json["code"]; | 3695 code = _json["code"]; |
| 3734 } | 3696 } |
| 3735 if (_json.containsKey("details")) { | 3697 if (_json.containsKey("details")) { |
| 3736 details = _json["details"]; | 3698 details = _json["details"]; |
| 3737 } | 3699 } |
| 3738 if (_json.containsKey("message")) { | 3700 if (_json.containsKey("message")) { |
| 3739 message = _json["message"]; | 3701 message = _json["message"]; |
| 3740 } | 3702 } |
| 3741 } | 3703 } |
| 3742 | 3704 |
| 3743 core.Map<core.String, core.Object> toJson() { | 3705 core.Map<core.String, core.Object> toJson() { |
| 3744 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3706 final core.Map<core.String, core.Object> _json = |
| 3707 new core.Map<core.String, core.Object>(); |
| 3745 if (code != null) { | 3708 if (code != null) { |
| 3746 _json["code"] = code; | 3709 _json["code"] = code; |
| 3747 } | 3710 } |
| 3748 if (details != null) { | 3711 if (details != null) { |
| 3749 _json["details"] = details; | 3712 _json["details"] = details; |
| 3750 } | 3713 } |
| 3751 if (message != null) { | 3714 if (message != null) { |
| 3752 _json["message"] = message; | 3715 _json["message"] = message; |
| 3753 } | 3716 } |
| 3754 return _json; | 3717 return _json; |
| 3755 } | 3718 } |
| 3756 } | 3719 } |
| 3757 | 3720 |
| 3758 /** Settings controlling the behavior of status reports. */ | 3721 /// Settings controlling the behavior of status reports. |
| 3759 class StatusReportingSettings { | 3722 class StatusReportingSettings { |
| 3760 /** Whether displays reporting is enabled. */ | 3723 /// Whether displays reporting is enabled. |
| 3761 core.bool displayInfoEnabled; | 3724 core.bool displayInfoEnabled; |
| 3762 /** Whether hardware status reporting is enabled. */ | 3725 |
| 3726 /// Whether hardware status reporting is enabled. |
| 3763 core.bool hardwareStatusEnabled; | 3727 core.bool hardwareStatusEnabled; |
| 3764 /** Whether memory info reporting is enabled. */ | 3728 |
| 3729 /// Whether memory info reporting is enabled. |
| 3765 core.bool memoryInfoEnabled; | 3730 core.bool memoryInfoEnabled; |
| 3766 /** Whether network info reporting is enabled. */ | 3731 |
| 3732 /// Whether network info reporting is enabled. |
| 3767 core.bool networkInfoEnabled; | 3733 core.bool networkInfoEnabled; |
| 3768 /** Whether power management event reporting is enabled. */ | 3734 |
| 3735 /// Whether power management event reporting is enabled. |
| 3769 core.bool powerManagementEventsEnabled; | 3736 core.bool powerManagementEventsEnabled; |
| 3770 /** Whether software info reporting is enabled. */ | 3737 |
| 3738 /// Whether software info reporting is enabled. |
| 3771 core.bool softwareInfoEnabled; | 3739 core.bool softwareInfoEnabled; |
| 3772 | 3740 |
| 3773 StatusReportingSettings(); | 3741 StatusReportingSettings(); |
| 3774 | 3742 |
| 3775 StatusReportingSettings.fromJson(core.Map _json) { | 3743 StatusReportingSettings.fromJson(core.Map _json) { |
| 3776 if (_json.containsKey("displayInfoEnabled")) { | 3744 if (_json.containsKey("displayInfoEnabled")) { |
| 3777 displayInfoEnabled = _json["displayInfoEnabled"]; | 3745 displayInfoEnabled = _json["displayInfoEnabled"]; |
| 3778 } | 3746 } |
| 3779 if (_json.containsKey("hardwareStatusEnabled")) { | 3747 if (_json.containsKey("hardwareStatusEnabled")) { |
| 3780 hardwareStatusEnabled = _json["hardwareStatusEnabled"]; | 3748 hardwareStatusEnabled = _json["hardwareStatusEnabled"]; |
| 3781 } | 3749 } |
| 3782 if (_json.containsKey("memoryInfoEnabled")) { | 3750 if (_json.containsKey("memoryInfoEnabled")) { |
| 3783 memoryInfoEnabled = _json["memoryInfoEnabled"]; | 3751 memoryInfoEnabled = _json["memoryInfoEnabled"]; |
| 3784 } | 3752 } |
| 3785 if (_json.containsKey("networkInfoEnabled")) { | 3753 if (_json.containsKey("networkInfoEnabled")) { |
| 3786 networkInfoEnabled = _json["networkInfoEnabled"]; | 3754 networkInfoEnabled = _json["networkInfoEnabled"]; |
| 3787 } | 3755 } |
| 3788 if (_json.containsKey("powerManagementEventsEnabled")) { | 3756 if (_json.containsKey("powerManagementEventsEnabled")) { |
| 3789 powerManagementEventsEnabled = _json["powerManagementEventsEnabled"]; | 3757 powerManagementEventsEnabled = _json["powerManagementEventsEnabled"]; |
| 3790 } | 3758 } |
| 3791 if (_json.containsKey("softwareInfoEnabled")) { | 3759 if (_json.containsKey("softwareInfoEnabled")) { |
| 3792 softwareInfoEnabled = _json["softwareInfoEnabled"]; | 3760 softwareInfoEnabled = _json["softwareInfoEnabled"]; |
| 3793 } | 3761 } |
| 3794 } | 3762 } |
| 3795 | 3763 |
| 3796 core.Map<core.String, core.Object> toJson() { | 3764 core.Map<core.String, core.Object> toJson() { |
| 3797 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3765 final core.Map<core.String, core.Object> _json = |
| 3766 new core.Map<core.String, core.Object>(); |
| 3798 if (displayInfoEnabled != null) { | 3767 if (displayInfoEnabled != null) { |
| 3799 _json["displayInfoEnabled"] = displayInfoEnabled; | 3768 _json["displayInfoEnabled"] = displayInfoEnabled; |
| 3800 } | 3769 } |
| 3801 if (hardwareStatusEnabled != null) { | 3770 if (hardwareStatusEnabled != null) { |
| 3802 _json["hardwareStatusEnabled"] = hardwareStatusEnabled; | 3771 _json["hardwareStatusEnabled"] = hardwareStatusEnabled; |
| 3803 } | 3772 } |
| 3804 if (memoryInfoEnabled != null) { | 3773 if (memoryInfoEnabled != null) { |
| 3805 _json["memoryInfoEnabled"] = memoryInfoEnabled; | 3774 _json["memoryInfoEnabled"] = memoryInfoEnabled; |
| 3806 } | 3775 } |
| 3807 if (networkInfoEnabled != null) { | 3776 if (networkInfoEnabled != null) { |
| 3808 _json["networkInfoEnabled"] = networkInfoEnabled; | 3777 _json["networkInfoEnabled"] = networkInfoEnabled; |
| 3809 } | 3778 } |
| 3810 if (powerManagementEventsEnabled != null) { | 3779 if (powerManagementEventsEnabled != null) { |
| 3811 _json["powerManagementEventsEnabled"] = powerManagementEventsEnabled; | 3780 _json["powerManagementEventsEnabled"] = powerManagementEventsEnabled; |
| 3812 } | 3781 } |
| 3813 if (softwareInfoEnabled != null) { | 3782 if (softwareInfoEnabled != null) { |
| 3814 _json["softwareInfoEnabled"] = softwareInfoEnabled; | 3783 _json["softwareInfoEnabled"] = softwareInfoEnabled; |
| 3815 } | 3784 } |
| 3816 return _json; | 3785 return _json; |
| 3817 } | 3786 } |
| 3818 } | 3787 } |
| 3819 | 3788 |
| 3820 /** Configuration for managing system updates */ | 3789 /// Configuration for managing system updates |
| 3821 class SystemUpdate { | 3790 class SystemUpdate { |
| 3822 /** | 3791 /// If the type is WINDOWED, the end of the maintenance window, measured as |
| 3823 * If the type is WINDOWED, the end of the maintenance window, measured as the | 3792 /// the number of minutes after midnight in device local time. This value |
| 3824 * number of minutes after midnight in device local time. This value must be | 3793 /// must be between 0 and 1439, inclusive. If this value is less than |
| 3825 * between 0 and 1439, inclusive. If this value is less than start_minutes, | 3794 /// start_minutes, then the maintenance window spans midnight. If the |
| 3826 * then the maintenance window spans midnight. If the maintenance window | 3795 /// maintenance window specified is smaller than 30 minutes, the actual |
| 3827 * specified is smaller than 30 minutes, the actual window is extended to 30 | 3796 /// window is extended to 30 minutes beyond the start time. |
| 3828 * minutes beyond the start time. | |
| 3829 */ | |
| 3830 core.int endMinutes; | 3797 core.int endMinutes; |
| 3831 /** | 3798 |
| 3832 * If the type is WINDOWED, the start of the maintenance window, measured as | 3799 /// If the type is WINDOWED, the start of the maintenance window, measured as |
| 3833 * the number of minutes after midnight in device local time. This value must | 3800 /// the number of minutes after midnight in device local time. This value |
| 3834 * be between 0 and 1439, inclusive. | 3801 /// must be between 0 and 1439, inclusive. |
| 3835 */ | |
| 3836 core.int startMinutes; | 3802 core.int startMinutes; |
| 3837 /** | 3803 |
| 3838 * The type of system update to configure. | 3804 /// The type of system update to configure. |
| 3839 * Possible string values are: | 3805 /// Possible string values are: |
| 3840 * - "SYSTEM_UPDATE_TYPE_UNSPECIFIED" : Follow the default update behavior for | 3806 /// - "SYSTEM_UPDATE_TYPE_UNSPECIFIED" : Follow the default update behavior |
| 3841 * the device, which typically requires the user to accept system updates. | 3807 /// for the device, which typically requires the user to accept system |
| 3842 * - "AUTOMATIC" : Install automatically as soon as an update is available. | 3808 /// updates. |
| 3843 * - "WINDOWED" : Install automatically within a daily maintenance window. If | 3809 /// - "AUTOMATIC" : Install automatically as soon as an update is available. |
| 3844 * the device has a device account, this also configures Play apps to be | 3810 /// - "WINDOWED" : Install automatically within a daily maintenance window. |
| 3845 * updated within the window. This is strongly recommended for kiosk devices | 3811 /// If the device has a device account, this also configures Play apps to be |
| 3846 * because this is the only way apps persistently pinned to the foreground can | 3812 /// updated within the window. This is strongly recommended for kiosk devices |
| 3847 * be updated by Play. | 3813 /// because this is the only way apps persistently pinned to the foreground |
| 3848 * - "POSTPONE" : Postpone automatic install up to a maximum of 30 days. | 3814 /// can be updated by Play. |
| 3849 */ | 3815 /// - "POSTPONE" : Postpone automatic install up to a maximum of 30 days. |
| 3850 core.String type; | 3816 core.String type; |
| 3851 | 3817 |
| 3852 SystemUpdate(); | 3818 SystemUpdate(); |
| 3853 | 3819 |
| 3854 SystemUpdate.fromJson(core.Map _json) { | 3820 SystemUpdate.fromJson(core.Map _json) { |
| 3855 if (_json.containsKey("endMinutes")) { | 3821 if (_json.containsKey("endMinutes")) { |
| 3856 endMinutes = _json["endMinutes"]; | 3822 endMinutes = _json["endMinutes"]; |
| 3857 } | 3823 } |
| 3858 if (_json.containsKey("startMinutes")) { | 3824 if (_json.containsKey("startMinutes")) { |
| 3859 startMinutes = _json["startMinutes"]; | 3825 startMinutes = _json["startMinutes"]; |
| 3860 } | 3826 } |
| 3861 if (_json.containsKey("type")) { | 3827 if (_json.containsKey("type")) { |
| 3862 type = _json["type"]; | 3828 type = _json["type"]; |
| 3863 } | 3829 } |
| 3864 } | 3830 } |
| 3865 | 3831 |
| 3866 core.Map<core.String, core.Object> toJson() { | 3832 core.Map<core.String, core.Object> toJson() { |
| 3867 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3833 final core.Map<core.String, core.Object> _json = |
| 3834 new core.Map<core.String, core.Object>(); |
| 3868 if (endMinutes != null) { | 3835 if (endMinutes != null) { |
| 3869 _json["endMinutes"] = endMinutes; | 3836 _json["endMinutes"] = endMinutes; |
| 3870 } | 3837 } |
| 3871 if (startMinutes != null) { | 3838 if (startMinutes != null) { |
| 3872 _json["startMinutes"] = startMinutes; | 3839 _json["startMinutes"] = startMinutes; |
| 3873 } | 3840 } |
| 3874 if (type != null) { | 3841 if (type != null) { |
| 3875 _json["type"] = type; | 3842 _json["type"] = type; |
| 3876 } | 3843 } |
| 3877 return _json; | 3844 return _json; |
| 3878 } | 3845 } |
| 3879 } | 3846 } |
| 3880 | 3847 |
| 3881 /** | 3848 /// Provides user facing message with locale info. The maximum message length |
| 3882 * Provides user facing message with locale info. The maximum message length is | 3849 /// is 4096 characters. |
| 3883 * 4096 characters. | |
| 3884 */ | |
| 3885 class UserFacingMessage { | 3850 class UserFacingMessage { |
| 3886 /** | 3851 /// The default message that gets displayed if no localized message is |
| 3887 * The default message that gets displayed if no localized message is | 3852 /// specified, or the user's locale does not match with any of the localized |
| 3888 * specified, or the user's locale does not match with any of the localized | 3853 /// messages. A default message must be provided if any localized messages |
| 3889 * messages. A default message must be provided if any localized messages are | 3854 /// are provided. |
| 3890 * provided. | |
| 3891 */ | |
| 3892 core.String defaultMessage; | 3855 core.String defaultMessage; |
| 3893 /** | 3856 |
| 3894 * A map which contains <locale, message> pairs. The locale is a BCP 47 | 3857 /// A map which contains <locale, message> pairs. The locale is a BCP 47 |
| 3895 * language code, e.g. en-US, es-ES, fr. | 3858 /// language code, e.g. en-US, es-ES, fr. |
| 3896 */ | |
| 3897 core.Map<core.String, core.String> localizedMessages; | 3859 core.Map<core.String, core.String> localizedMessages; |
| 3898 | 3860 |
| 3899 UserFacingMessage(); | 3861 UserFacingMessage(); |
| 3900 | 3862 |
| 3901 UserFacingMessage.fromJson(core.Map _json) { | 3863 UserFacingMessage.fromJson(core.Map _json) { |
| 3902 if (_json.containsKey("defaultMessage")) { | 3864 if (_json.containsKey("defaultMessage")) { |
| 3903 defaultMessage = _json["defaultMessage"]; | 3865 defaultMessage = _json["defaultMessage"]; |
| 3904 } | 3866 } |
| 3905 if (_json.containsKey("localizedMessages")) { | 3867 if (_json.containsKey("localizedMessages")) { |
| 3906 localizedMessages = _json["localizedMessages"]; | 3868 localizedMessages = _json["localizedMessages"]; |
| 3907 } | 3869 } |
| 3908 } | 3870 } |
| 3909 | 3871 |
| 3910 core.Map<core.String, core.Object> toJson() { | 3872 core.Map<core.String, core.Object> toJson() { |
| 3911 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3873 final core.Map<core.String, core.Object> _json = |
| 3874 new core.Map<core.String, core.Object>(); |
| 3912 if (defaultMessage != null) { | 3875 if (defaultMessage != null) { |
| 3913 _json["defaultMessage"] = defaultMessage; | 3876 _json["defaultMessage"] = defaultMessage; |
| 3914 } | 3877 } |
| 3915 if (localizedMessages != null) { | 3878 if (localizedMessages != null) { |
| 3916 _json["localizedMessages"] = localizedMessages; | 3879 _json["localizedMessages"] = localizedMessages; |
| 3917 } | 3880 } |
| 3918 return _json; | 3881 return _json; |
| 3919 } | 3882 } |
| 3920 } | 3883 } |
| 3921 | 3884 |
| 3922 /** A web token used to access an embeddable managed Google Play web UI. */ | 3885 /// A web token used to access an embeddable managed Google Play web UI. |
| 3923 class WebToken { | 3886 class WebToken { |
| 3924 /** | 3887 /// The name of the web token, which is generated by the server during |
| 3925 * The name of the web token, which is generated by the server during | 3888 /// creation, in the form enterprises/{enterpriseId}/webTokens/{webTokenId}. |
| 3926 * creation, in the form enterprises/{enterpriseId}/webTokens/{webTokenId}. | |
| 3927 */ | |
| 3928 core.String name; | 3889 core.String name; |
| 3929 /** | 3890 |
| 3930 * The URL of the parent frame hosting the iframe with the embedded UI. To | 3891 /// The URL of the parent frame hosting the iframe with the embedded UI. To |
| 3931 * prevent XSS, the iframe may not be hosted at other URLs. The URL must use | 3892 /// prevent XSS, the iframe may not be hosted at other URLs. The URL must use |
| 3932 * the https scheme. | 3893 /// the https scheme. |
| 3933 */ | |
| 3934 core.String parentFrameUrl; | 3894 core.String parentFrameUrl; |
| 3935 /** | 3895 |
| 3936 * Permissions the admin may exercise in the embedded UI. The admin must have | 3896 /// Permissions the admin may exercise in the embedded UI. The admin must |
| 3937 * all of these permissions in order to view the UI. | 3897 /// have all of these permissions in order to view the UI. |
| 3938 */ | |
| 3939 core.List<core.String> permissions; | 3898 core.List<core.String> permissions; |
| 3940 /** | 3899 |
| 3941 * The token value which is used in the hosting page to generate the iframe | 3900 /// The token value which is used in the hosting page to generate the iframe |
| 3942 * with the embedded UI. This is a read-only field generated by the server. | 3901 /// with the embedded UI. This is a read-only field generated by the server. |
| 3943 */ | |
| 3944 core.String value; | 3902 core.String value; |
| 3945 | 3903 |
| 3946 WebToken(); | 3904 WebToken(); |
| 3947 | 3905 |
| 3948 WebToken.fromJson(core.Map _json) { | 3906 WebToken.fromJson(core.Map _json) { |
| 3949 if (_json.containsKey("name")) { | 3907 if (_json.containsKey("name")) { |
| 3950 name = _json["name"]; | 3908 name = _json["name"]; |
| 3951 } | 3909 } |
| 3952 if (_json.containsKey("parentFrameUrl")) { | 3910 if (_json.containsKey("parentFrameUrl")) { |
| 3953 parentFrameUrl = _json["parentFrameUrl"]; | 3911 parentFrameUrl = _json["parentFrameUrl"]; |
| 3954 } | 3912 } |
| 3955 if (_json.containsKey("permissions")) { | 3913 if (_json.containsKey("permissions")) { |
| 3956 permissions = _json["permissions"]; | 3914 permissions = _json["permissions"]; |
| 3957 } | 3915 } |
| 3958 if (_json.containsKey("value")) { | 3916 if (_json.containsKey("value")) { |
| 3959 value = _json["value"]; | 3917 value = _json["value"]; |
| 3960 } | 3918 } |
| 3961 } | 3919 } |
| 3962 | 3920 |
| 3963 core.Map<core.String, core.Object> toJson() { | 3921 core.Map<core.String, core.Object> toJson() { |
| 3964 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 3922 final core.Map<core.String, core.Object> _json = |
| 3923 new core.Map<core.String, core.Object>(); |
| 3965 if (name != null) { | 3924 if (name != null) { |
| 3966 _json["name"] = name; | 3925 _json["name"] = name; |
| 3967 } | 3926 } |
| 3968 if (parentFrameUrl != null) { | 3927 if (parentFrameUrl != null) { |
| 3969 _json["parentFrameUrl"] = parentFrameUrl; | 3928 _json["parentFrameUrl"] = parentFrameUrl; |
| 3970 } | 3929 } |
| 3971 if (permissions != null) { | 3930 if (permissions != null) { |
| 3972 _json["permissions"] = permissions; | 3931 _json["permissions"] = permissions; |
| 3973 } | 3932 } |
| 3974 if (value != null) { | 3933 if (value != null) { |
| 3975 _json["value"] = value; | 3934 _json["value"] = value; |
| 3976 } | 3935 } |
| 3977 return _json; | 3936 return _json; |
| 3978 } | 3937 } |
| 3979 } | 3938 } |
| OLD | NEW |