OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 /** @fileoverview Externs generated from namespace: usersPrivate */ |
| 6 |
| 7 /** |
| 8 * @const |
| 9 */ |
| 10 chrome.usersPrivate = {}; |
| 11 |
| 12 /** |
| 13 * @typedef {{ |
| 14 * email: string, |
| 15 * isOwner: boolean |
| 16 * }} |
| 17 * @see https://developer.chrome.com/extensions/usersPrivate#type-User |
| 18 */ |
| 19 var User; |
| 20 |
| 21 /** |
| 22 * Gets a list of the currently whitelisted users. |
| 23 * @param {function(!Array<User>):void} callback |
| 24 * @see https://developer.chrome.com/extensions/usersPrivate#method-getWhitelist
edUsers |
| 25 */ |
| 26 chrome.usersPrivate.getWhitelistedUsers = function(callback) {}; |
| 27 |
| 28 /** |
| 29 * Adds a new user with the given email to the whitelist. The callback is called |
| 30 * with true if the user was added succesfully, or with false if not (e.g. |
| 31 * because the user was already present, or the current user isn't the owner). |
| 32 * @param {string} email |
| 33 * @param {function(boolean):void} callback |
| 34 * @see https://developer.chrome.com/extensions/usersPrivate#method-addWhitelist
edUser |
| 35 */ |
| 36 chrome.usersPrivate.addWhitelistedUser = function(email, callback) {}; |
| 37 |
| 38 /** |
| 39 * Removes the user with the given email from the whitelist. The callback is |
| 40 * called with true if the user was removed succesfully, or with false if not |
| 41 * (e.g. because the user was not already present, or the current user isn't the |
| 42 * owner). |
| 43 * @param {string} email |
| 44 * @param {function(boolean):void} callback |
| 45 * @see https://developer.chrome.com/extensions/usersPrivate#method-removeWhitel
istedUser |
| 46 */ |
| 47 chrome.usersPrivate.removeWhitelistedUser = function(email, callback) {}; |
| 48 |
| 49 /** |
| 50 * Whether the current user is the owner of the device. |
| 51 * @param {function(boolean):void} callback |
| 52 * @see https://developer.chrome.com/extensions/usersPrivate#method-isCurrentUse
rOwner |
| 53 */ |
| 54 chrome.usersPrivate.isCurrentUserOwner = function(callback) {}; |
| 55 |
| 56 /** |
| 57 * Whether the whitelist is managed by enterprise. |
| 58 * @param {function(boolean):void} callback |
| 59 * @see https://developer.chrome.com/extensions/usersPrivate#method-isWhitelistM
anaged |
| 60 */ |
| 61 chrome.usersPrivate.isWhitelistManaged = function(callback) {}; |
OLD | NEW |