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

Side by Side Diff: components/autofill/content/browser/wallet/wallet_client_delegate.h

Issue 17970003: New encryption/escrow endpoints for Wallet (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebasing again... Created 7 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef COMPONENTS_AUTOFILL_BROWSER_WALLET_WALLET_CLIENT_OBSERVER_H_ 5 #ifndef COMPONENTS_AUTOFILL_BROWSER_WALLET_WALLET_CLIENT_OBSERVER_H_
6 #define COMPONENTS_AUTOFILL_BROWSER_WALLET_WALLET_CLIENT_OBSERVER_H_ 6 #define COMPONENTS_AUTOFILL_BROWSER_WALLET_WALLET_CLIENT_OBSERVER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 virtual void OnDidAuthenticateInstrument(bool success) = 0; 54 virtual void OnDidAuthenticateInstrument(bool success) = 0;
55 55
56 // Called when a GetFullWallet request finishes successfully. Ownership is 56 // Called when a GetFullWallet request finishes successfully. Ownership is
57 // transferred to implementer of this interface. 57 // transferred to implementer of this interface.
58 virtual void OnDidGetFullWallet(scoped_ptr<FullWallet> full_wallet) = 0; 58 virtual void OnDidGetFullWallet(scoped_ptr<FullWallet> full_wallet) = 0;
59 59
60 // Called when a GetWalletItems request finishes successfully. Ownership is 60 // Called when a GetWalletItems request finishes successfully. Ownership is
61 // transferred to implementer of this interface. 61 // transferred to implementer of this interface.
62 virtual void OnDidGetWalletItems(scoped_ptr<WalletItems> wallet_items) = 0; 62 virtual void OnDidGetWalletItems(scoped_ptr<WalletItems> wallet_items) = 0;
63 63
64 // Called when a SaveAddress request finishes successfully. |address_id| can 64 // Called when a SaveToWallet request finishes succesfully.
65 // be used in subsequent GetFullWallet calls. |required_actions| is populated
66 // if there was a validation error with the data being saved.
67 // |form_field_errors| is populated with the actual form fields that are
68 // failing validation.
69 virtual void OnDidSaveAddress(
70 const std::string& address_id,
71 const std::vector<RequiredAction>& required_actions,
72 const std::vector<FormFieldError>& form_field_errors) = 0;
73
74 // Called when a SaveInstrument request finishes sucessfully. |instrument_id|
75 // can be used in subsequent GetFullWallet calls. |required_actions| is
76 // populated if there was a validation error with the data being saved.
77 // |form_field_errors| is populated with the actual form fields that are
78 // failing validation.
79 virtual void OnDidSaveInstrument(
80 const std::string& instrument_id,
81 const std::vector<RequiredAction>& required_actions,
82 const std::vector<FormFieldError>& form_field_errors) = 0;
83
84 // Called when a SaveInstrumentAndAddress request finishes succesfully.
85 // |instrument_id| and |address_id| can be used in subsequent 65 // |instrument_id| and |address_id| can be used in subsequent
86 // GetFullWallet calls. |required_actions| is populated if there was a 66 // GetFullWallet calls. |required_actions| is populated if there was a
87 // validation error with the data being saved. |form_field_errors| is 67 // validation error with the data being saved. |form_field_errors| is
88 // populated with the actual form fields that are failing validation. 68 // populated with the actual form fields that are failing validation.
89 virtual void OnDidSaveInstrumentAndAddress( 69 virtual void OnDidSaveToWallet(
90 const std::string& instrument_id, 70 const std::string& instrument_id,
91 const std::string& address_id, 71 const std::string& address_id,
92 const std::vector<RequiredAction>& required_actions, 72 const std::vector<RequiredAction>& required_actions,
93 const std::vector<FormFieldError>& form_field_errors) = 0; 73 const std::vector<FormFieldError>& form_field_errors) = 0;
94 74
95 // Called when an UpdateAddress request finishes successfully.
96 // |required_actions| is populated if there was a validation error with the
97 // data being saved. |form_field_errors| is populated with the actual form
98 // fields that are failing validation.
99 virtual void OnDidUpdateAddress(
100 const std::string& address_id,
101 const std::vector<RequiredAction>& required_actions,
102 const std::vector<FormFieldError>& form_field_errors) = 0;
103
104 // Called when an UpdateInstrument request finishes successfully.
105 // |required_actions| is populated if there was a validation error with the
106 // data being saved. |form_field_errors| is populated with the actual form
107 // fields that are failing validation.
108 virtual void OnDidUpdateInstrument(
109 const std::string& instrument_id,
110 const std::vector<RequiredAction>& required_actions,
111 const std::vector<FormFieldError>& form_field_errors) = 0;
112
113 // Called when a request fails. 75 // Called when a request fails.
114 virtual void OnWalletError(WalletClient::ErrorType error_type) = 0; 76 virtual void OnWalletError(WalletClient::ErrorType error_type) = 0;
115 77
116 protected: 78 protected:
117 virtual ~WalletClientDelegate() {} 79 virtual ~WalletClientDelegate() {}
118 }; 80 };
119 81
120 } // namespace wallet 82 } // namespace wallet
121 } // namespace autofill 83 } // namespace autofill
122 84
123 #endif // COMPONENTS_AUTOFILL_BROWSER_WALLET_WALLET_CLIENT_OBSERVER_H_ 85 #endif // COMPONENTS_AUTOFILL_BROWSER_WALLET_WALLET_CLIENT_OBSERVER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698