| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // This file was generated by: |
| 6 // tools/json_schema_compiler/compiler.py. |
| 7 // NOTE: The format of types has changed. 'FooType' is now |
| 8 // 'chrome.autofillPrivate.FooType'. |
| 9 // Please run the closure compiler before committing changes. |
| 10 // See https://chromium.googlesource.com/chromium/src/+/master/docs/closure_comp
ilation.md |
| 11 |
| 5 /** @fileoverview Externs generated from namespace: autofillPrivate */ | 12 /** @fileoverview Externs generated from namespace: autofillPrivate */ |
| 6 | 13 |
| 7 /** | 14 /** |
| 8 * @const | 15 * @const |
| 9 */ | 16 */ |
| 10 chrome.autofillPrivate = {}; | 17 chrome.autofillPrivate = {}; |
| 11 | 18 |
| 12 /** | 19 /** |
| 13 * @enum {string} | 20 * @enum {string} |
| 14 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressFiel
d | 21 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressFiel
d |
| (...skipping 12 matching lines...) Expand all Loading... |
| 27 | 34 |
| 28 /** | 35 /** |
| 29 * @typedef {{ | 36 * @typedef {{ |
| 30 * summaryLabel: string, | 37 * summaryLabel: string, |
| 31 * summarySublabel: (string|undefined), | 38 * summarySublabel: (string|undefined), |
| 32 * isLocal: (boolean|undefined), | 39 * isLocal: (boolean|undefined), |
| 33 * isCached: (boolean|undefined) | 40 * isCached: (boolean|undefined) |
| 34 * }} | 41 * }} |
| 35 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AutofillMet
adata | 42 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AutofillMet
adata |
| 36 */ | 43 */ |
| 37 var AutofillMetadata; | 44 chrome.autofillPrivate.AutofillMetadata; |
| 38 | 45 |
| 39 /** | 46 /** |
| 40 * @typedef {{ | 47 * @typedef {{ |
| 41 * guid: (string|undefined), | 48 * guid: (string|undefined), |
| 42 * fullNames: (!Array<string>|undefined), | 49 * fullNames: (!Array<string>|undefined), |
| 43 * companyName: (string|undefined), | 50 * companyName: (string|undefined), |
| 44 * addressLines: (string|undefined), | 51 * addressLines: (string|undefined), |
| 45 * addressLevel1: (string|undefined), | 52 * addressLevel1: (string|undefined), |
| 46 * addressLevel2: (string|undefined), | 53 * addressLevel2: (string|undefined), |
| 47 * addressLevel3: (string|undefined), | 54 * addressLevel3: (string|undefined), |
| 48 * postalCode: (string|undefined), | 55 * postalCode: (string|undefined), |
| 49 * sortingCode: (string|undefined), | 56 * sortingCode: (string|undefined), |
| 50 * countryCode: (string|undefined), | 57 * countryCode: (string|undefined), |
| 51 * phoneNumbers: (!Array<string>|undefined), | 58 * phoneNumbers: (!Array<string>|undefined), |
| 52 * emailAddresses: (!Array<string>|undefined), | 59 * emailAddresses: (!Array<string>|undefined), |
| 53 * languageCode: (string|undefined), | 60 * languageCode: (string|undefined), |
| 54 * metadata: (AutofillMetadata|undefined) | 61 * metadata: (!chrome.autofillPrivate.AutofillMetadata|undefined) |
| 55 * }} | 62 * }} |
| 56 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressEntr
y | 63 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressEntr
y |
| 57 */ | 64 */ |
| 58 var AddressEntry; | 65 chrome.autofillPrivate.AddressEntry; |
| 59 | 66 |
| 60 /** | 67 /** |
| 61 * @typedef {{ | 68 * @typedef {{ |
| 62 * field: !chrome.autofillPrivate.AddressField, | 69 * field: !chrome.autofillPrivate.AddressField, |
| 63 * fieldName: string, | 70 * fieldName: string, |
| 64 * isLongField: boolean, | 71 * isLongField: boolean, |
| 65 * placeholder: (string|undefined) | 72 * placeholder: (string|undefined) |
| 66 * }} | 73 * }} |
| 67 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressComp
onent | 74 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressComp
onent |
| 68 */ | 75 */ |
| 69 var AddressComponent; | 76 chrome.autofillPrivate.AddressComponent; |
| 70 | 77 |
| 71 /** | 78 /** |
| 72 * @typedef {{ | 79 * @typedef {{ |
| 73 * row: !Array<AddressComponent> | 80 * row: !Array<!chrome.autofillPrivate.AddressComponent> |
| 74 * }} | 81 * }} |
| 75 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressComp
onentRow | 82 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressComp
onentRow |
| 76 */ | 83 */ |
| 77 var AddressComponentRow; | 84 chrome.autofillPrivate.AddressComponentRow; |
| 78 | 85 |
| 79 /** | 86 /** |
| 80 * @typedef {{ | 87 * @typedef {{ |
| 81 * components: !Array<AddressComponentRow>, | 88 * components: !Array<!chrome.autofillPrivate.AddressComponentRow>, |
| 82 * languageCode: string | 89 * languageCode: string |
| 83 * }} | 90 * }} |
| 84 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressComp
onents | 91 * @see https://developer.chrome.com/extensions/autofillPrivate#type-AddressComp
onents |
| 85 */ | 92 */ |
| 86 var AddressComponents; | 93 chrome.autofillPrivate.AddressComponents; |
| 87 | 94 |
| 88 /** | 95 /** |
| 89 * @typedef {{ | 96 * @typedef {{ |
| 90 * guid: (string|undefined), | 97 * guid: (string|undefined), |
| 91 * name: (string|undefined), | 98 * name: (string|undefined), |
| 92 * cardNumber: (string|undefined), | 99 * cardNumber: (string|undefined), |
| 93 * expirationMonth: (string|undefined), | 100 * expirationMonth: (string|undefined), |
| 94 * expirationYear: (string|undefined), | 101 * expirationYear: (string|undefined), |
| 95 * metadata: (AutofillMetadata|undefined) | 102 * metadata: (!chrome.autofillPrivate.AutofillMetadata|undefined) |
| 96 * }} | 103 * }} |
| 97 * @see https://developer.chrome.com/extensions/autofillPrivate#type-CreditCardE
ntry | 104 * @see https://developer.chrome.com/extensions/autofillPrivate#type-CreditCardE
ntry |
| 98 */ | 105 */ |
| 99 var CreditCardEntry; | 106 chrome.autofillPrivate.CreditCardEntry; |
| 100 | 107 |
| 101 /** | 108 /** |
| 102 * @typedef {{ | 109 * @typedef {{ |
| 103 * phoneNumbers: !Array<string>, | 110 * phoneNumbers: !Array<string>, |
| 104 * indexOfNewNumber: number, | 111 * indexOfNewNumber: number, |
| 105 * countryCode: string | 112 * countryCode: string |
| 106 * }} | 113 * }} |
| 107 * @see https://developer.chrome.com/extensions/autofillPrivate#type-ValidatePho
neParams | 114 * @see https://developer.chrome.com/extensions/autofillPrivate#type-ValidatePho
neParams |
| 108 */ | 115 */ |
| 109 var ValidatePhoneParams; | 116 chrome.autofillPrivate.ValidatePhoneParams; |
| 110 | 117 |
| 111 /** | 118 /** |
| 112 * Saves the given address. If |address| has an empty string as its ID, it will | 119 * Saves the given address. If |address| has an empty string as its ID, it will |
| 113 * be assigned a new one and added as a new entry. | 120 * be assigned a new one and added as a new entry. |
| 114 * @param {AddressEntry} address The address entry to save. | 121 * @param {!chrome.autofillPrivate.AddressEntry} address The address entry to |
| 122 * save. |
| 115 * @see https://developer.chrome.com/extensions/autofillPrivate#method-saveAddre
ss | 123 * @see https://developer.chrome.com/extensions/autofillPrivate#method-saveAddre
ss |
| 116 */ | 124 */ |
| 117 chrome.autofillPrivate.saveAddress = function(address) {}; | 125 chrome.autofillPrivate.saveAddress = function(address) {}; |
| 118 | 126 |
| 119 /** | 127 /** |
| 120 * Gets the address components for a given country code. | 128 * Gets the address components for a given country code. |
| 121 * @param {string} countryCode A two-character string representing the address' | 129 * @param {string} countryCode A two-character string representing the address' |
| 122 * country whose components should be returned. See autofill_country.cc | 130 * country whose components should be returned. See autofill_country.cc |
| 123 * for a list of valid codes. | 131 * for a list of valid codes. |
| 124 * @param {function(AddressComponents):void} callback Callback which will be | 132 * @param {function(!chrome.autofillPrivate.AddressComponents):void} callback |
| 125 * called with components. | 133 * Callback which will be called with components. |
| 126 * @see https://developer.chrome.com/extensions/autofillPrivate#method-getAddres
sComponents | 134 * @see https://developer.chrome.com/extensions/autofillPrivate#method-getAddres
sComponents |
| 127 */ | 135 */ |
| 128 chrome.autofillPrivate.getAddressComponents = function(countryCode, callback) {}
; | 136 chrome.autofillPrivate.getAddressComponents = function(countryCode, callback) {}
; |
| 129 | 137 |
| 130 /** | 138 /** |
| 131 * Saves the given credit card. If |card| has an empty string as its ID, it will | 139 * Saves the given credit card. If |card| has an empty string as its ID, it will |
| 132 * be assigned a new one and added as a new entry. | 140 * be assigned a new one and added as a new entry. |
| 133 * @param {CreditCardEntry} card The card entry to save. | 141 * @param {!chrome.autofillPrivate.CreditCardEntry} card The card entry to save. |
| 134 * @see https://developer.chrome.com/extensions/autofillPrivate#method-saveCredi
tCard | 142 * @see https://developer.chrome.com/extensions/autofillPrivate#method-saveCredi
tCard |
| 135 */ | 143 */ |
| 136 chrome.autofillPrivate.saveCreditCard = function(card) {}; | 144 chrome.autofillPrivate.saveCreditCard = function(card) {}; |
| 137 | 145 |
| 138 /** | 146 /** |
| 139 * Removes the entry (address or credit card) with the given ID. | 147 * Removes the entry (address or credit card) with the given ID. |
| 140 * @param {string} guid ID of the entry to remove. | 148 * @param {string} guid ID of the entry to remove. |
| 141 * @see https://developer.chrome.com/extensions/autofillPrivate#method-removeEnt
ry | 149 * @see https://developer.chrome.com/extensions/autofillPrivate#method-removeEnt
ry |
| 142 */ | 150 */ |
| 143 chrome.autofillPrivate.removeEntry = function(guid) {}; | 151 chrome.autofillPrivate.removeEntry = function(guid) {}; |
| 144 | 152 |
| 145 /** | 153 /** |
| 146 * Validates a newly-added phone number and invokes the callback with a list of | 154 * Validates a newly-added phone number and invokes the callback with a list of |
| 147 * validated numbers. Note that if the newly-added number was invalid, it will | 155 * validated numbers. Note that if the newly-added number was invalid, it will |
| 148 * not be returned in the list of valid numbers. | 156 * not be returned in the list of valid numbers. |
| 149 * @param {ValidatePhoneParams} params The parameters to this function. | 157 * @param {!chrome.autofillPrivate.ValidatePhoneParams} params The parameters to |
| 158 * this function. |
| 150 * @param {function(!Array<string>):void} callback Callback which will be called | 159 * @param {function(!Array<string>):void} callback Callback which will be called |
| 151 * with validated phone numbers. | 160 * with validated phone numbers. |
| 152 * @see https://developer.chrome.com/extensions/autofillPrivate#method-validateP
honeNumbers | 161 * @see https://developer.chrome.com/extensions/autofillPrivate#method-validateP
honeNumbers |
| 153 */ | 162 */ |
| 154 chrome.autofillPrivate.validatePhoneNumbers = function(params, callback) {}; | 163 chrome.autofillPrivate.validatePhoneNumbers = function(params, callback) {}; |
| 155 | 164 |
| 156 /** | 165 /** |
| 157 * Clears the data associated with a wallet card which was saved locally so that | 166 * Clears the data associated with a wallet card which was saved locally so that |
| 158 * the saved copy is masked (e.g., "Card ending in 1234"). | 167 * the saved copy is masked (e.g., "Card ending in 1234"). |
| 159 * @param {string} guid GUID of the credit card to mask. | 168 * @param {string} guid GUID of the credit card to mask. |
| 160 * @see https://developer.chrome.com/extensions/autofillPrivate#method-maskCredi
tCard | 169 * @see https://developer.chrome.com/extensions/autofillPrivate#method-maskCredi
tCard |
| 161 */ | 170 */ |
| 162 chrome.autofillPrivate.maskCreditCard = function(guid) {}; | 171 chrome.autofillPrivate.maskCreditCard = function(guid) {}; |
| 163 | 172 |
| 164 /** | 173 /** |
| 165 * Fired when the address list has changed, meaning that an entry has been | 174 * Fired when the address list has changed, meaning that an entry has been |
| 166 * added, removed, or changed. |entries| The updated list of entries. | 175 * added, removed, or changed. |entries| The updated list of entries. |
| 167 * @type {!ChromeEvent} | 176 * @type {!ChromeEvent} |
| 168 * @see https://developer.chrome.com/extensions/autofillPrivate#event-onAddressL
istChanged | 177 * @see https://developer.chrome.com/extensions/autofillPrivate#event-onAddressL
istChanged |
| 169 */ | 178 */ |
| 170 chrome.autofillPrivate.onAddressListChanged; | 179 chrome.autofillPrivate.onAddressListChanged; |
| 171 | 180 |
| 172 /** | 181 /** |
| 173 * Fired when the credit card list has changed, meaning that an entry has been | 182 * Fired when the credit card list has changed, meaning that an entry has been |
| 174 * added, removed, or changed. |entries| The updated list of entries. | 183 * added, removed, or changed. |entries| The updated list of entries. |
| 175 * @type {!ChromeEvent} | 184 * @type {!ChromeEvent} |
| 176 * @see https://developer.chrome.com/extensions/autofillPrivate#event-onCreditCa
rdListChanged | 185 * @see https://developer.chrome.com/extensions/autofillPrivate#event-onCreditCa
rdListChanged |
| 177 */ | 186 */ |
| 178 chrome.autofillPrivate.onCreditCardListChanged; | 187 chrome.autofillPrivate.onCreditCardListChanged; |
| 179 | |
| 180 | |
| OLD | NEW |