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

Side by Side Diff: sync/protocol/autofill_specifics.proto

Issue 2130453004: [Sync] Move //sync to //components/sync. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « sync/protocol/attachments.proto ('k') | sync/protocol/bookmark_specifics.proto » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2012 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 // Sync protocol datatype extension for autofill.
6
7 // Update proto_value_conversions{.h,.cc,_unittest.cc} if you change
8 // any fields in this file.
9
10 syntax = "proto2";
11
12 option optimize_for = LITE_RUNTIME;
13 option retain_unknown_fields = true;
14
15 package sync_pb;
16
17 // Properties of autofill sync objects.
18
19 // An AutofillProfile.
20 message AutofillProfileSpecifics {
21 optional string guid = 15;
22 optional string origin = 16;
23 optional int64 use_count = 22;
24
25 // The time_t value of the last time this profile was used. This
26 // value makes sense wrt base::Time::To/FromTimeT, which measures
27 // from the Windows epoch.
28 optional int64 use_date = 23;
29
30 // Contact info.
31 repeated string name_first = 2;
32 repeated string name_middle = 3;
33 repeated string name_last = 4;
34 repeated string name_full = 21;
35 repeated string email_address = 5;
36 optional string company_name = 6;
37
38 // Address.
39 optional string address_home_line1 = 7;
40 optional string address_home_line2 = 8;
41 optional string address_home_city = 9;
42 optional string address_home_state = 10;
43 optional string address_home_zip = 11;
44 optional string address_home_country = 12;
45
46 // Additional address fields for i18n.
47 optional string address_home_street_address = 17;
48 optional string address_home_sorting_code = 18;
49 optional string address_home_dependent_locality = 19;
50 optional string address_home_language_code = 20;
51
52 // Phone.
53 repeated string phone_home_whole_number = 13;
54
55 // Deprecated.
56 optional string label = 1 [deprecated=true];
57 optional string phone_fax_whole_number = 14 [deprecated=true];
58 }
59
60 message AutofillSpecifics {
61 // If any of these 3 fields are present, then all 3 should be, and it implies
62 // that this entity represents a classic autofill object. In this case,
63 // none of the autofill++ objects below should be present.
64 optional string name = 1;
65 optional string value = 2;
66 repeated int64 usage_timestamp = 3;
67
68 // An autofill++ profile object. If present, indicates this entity
69 // represents an AutofillProfile exclusively, and no other fields (such as
70 // name/value or credit_card) should be present.
71 optional AutofillProfileSpecifics profile = 4;
72
73 // Obsolete credit card fields.
74 // optional bytes deprecated_encrypted_credit_card = 5;
75 // optional AutofillCreditCardSpecifics deprecated_credit_card = 6;
76 }
77
78 message WalletMaskedCreditCard {
79 enum WalletCardStatus {
80 VALID = 0;
81 EXPIRED = 1;
82 }
83
84 enum WalletCardType {
85 UNKNOWN = 0;
86 AMEX = 1;
87 DISCOVER = 2;
88 JCB = 3;
89 MAESTRO = 4;
90 MASTER_CARD = 5;
91 SOLO = 6;
92 SWITCH = 7;
93 VISA = 8;
94 }
95
96 // Server-generated unique ID string. This is opaque to the client.
97 optional string id = 1;
98
99 // What the server thinks of this card.
100 optional WalletCardStatus status = 2;
101
102 optional string name_on_card = 3;
103
104 optional WalletCardType type = 4;
105
106 // Last 4 digits of the credit card number.
107 optional string last_four = 5;
108
109 // Month number 1-12.
110 optional int32 exp_month = 6;
111
112 // Four-digit year (e.g. 2017).
113 optional int32 exp_year = 7;
114
115 // The WalletPostalAddress.id of the billing address.
116 optional string billing_address_id = 8;
117 }
118
119 // Different than an AutofillProfile because this represents some known address
120 // on the server that is pulled down rather than synced between Chromes.
121 message WalletPostalAddress {
122 optional string id = 1;
123
124 optional string recipient_name = 12;
125 optional string company_name = 2;
126
127 // This is the street address, of which there may be multiple lines. This
128 // corresponds to "address_home_line[1|2] in the AutofillProfileSpecifics
129 // message above. In some locales there may be more than two lines.
130 repeated string street_address = 3;
131
132 // Also known as "administrative area". This is normally the state or
133 // province in most countries.
134 optional string address_1 = 4;
135
136 // Also known as "locality". In the US this is the city.
137 optional string address_2 = 5;
138
139 // A sub-classification beneath the city, e.g. an inner-city district or
140 // suburb. Also known as "dependent_locality"
141 optional string address_3 = 6;
142
143 // Used in certain countries. Also known as "sub_dependent_locality".
144 optional string address_4 = 7;
145
146 optional string postal_code = 8;
147
148 // Similar to the zipcode column, but used for businesses or organizations
149 // that might not be geographically contiguous. The canonical example is
150 // CEDEX in France.
151 optional string sorting_code = 9;
152
153 optional string country_code = 10;
154 optional string language_code = 11;
155
156 // Phone number. The format is unspecified and will be explicitly ignored.
157 optional string phone_number = 13;
158 }
159
160 message AutofillWalletSpecifics {
161 enum WalletInfoType {
162 UNKNOWN = 0;
163 MASKED_CREDIT_CARD = 1;
164 POSTAL_ADDRESS = 2;
165 }
166
167 optional WalletInfoType type = 1;
168
169 // This field exists if and only if the "type" field equals to
170 // MASKED_CREDIT_CARD.
171 optional WalletMaskedCreditCard masked_card = 2;
172
173 // This field exists if and only if the "type" field equals to ADDRESS.
174 optional WalletPostalAddress address = 3;
175 }
176
177 // Wallet card and address usage information that can be synced.
178 message WalletMetadataSpecifics {
179 enum Type {
180 UNKNOWN = 0;
181 CARD = 1;
182 ADDRESS = 2;
183 }
184
185 // The type of the Wallet metadata.
186 optional Type type = 1;
187
188 // Base64 encoding of the unique ID string of the corresponding Wallet data.
189 // For Wallet cards, this value is server generated and opaque to Chrome.
190 // For Wallet addresses, this is a SHA1 hash of the following fields:
191 //
192 // - First name
193 // - Middle name
194 // - Last name
195 // - Company name
196 // - Street address
197 // - Dependent locality
198 // - City
199 // - State
200 // - Zip code
201 // - Sorting code
202 // - Country
203 // - Phone number
204 // - Language code
205 optional string id = 2;
206
207 // The number of times that this Wallet card or address was used.
208 optional int64 use_count = 3;
209
210 // The last use date of this Wallet card or address. Measured in microseconds
211 // since the Windows epoch (1601).
212 optional int64 use_date = 4;
213 }
OLDNEW
« no previous file with comments | « sync/protocol/attachments.proto ('k') | sync/protocol/bookmark_specifics.proto » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698