| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 IOS_CHROME_BROWSER_UI_PAYMENTS_CONTACT_INFO_EDIT_MEDIATOR_H_ | 5 #ifndef IOS_CHROME_BROWSER_UI_PAYMENTS_CONTACT_INFO_EDIT_MEDIATOR_H_ |
| 6 #define IOS_CHROME_BROWSER_UI_PAYMENTS_CONTACT_INFO_EDIT_MEDIATOR_H_ | 6 #define IOS_CHROME_BROWSER_UI_PAYMENTS_CONTACT_INFO_EDIT_MEDIATOR_H_ |
| 7 | 7 |
| 8 #import <Foundation/Foundation.h> | 8 #import <Foundation/Foundation.h> |
| 9 | 9 |
| 10 #import "ios/chrome/browser/ui/payments/payment_request_edit_view_controller_dat
a_source.h" | 10 #import "ios/chrome/browser/ui/payments/payment_request_edit_view_controller_dat
a_source.h" |
| 11 | 11 |
| 12 class PaymentRequest; | |
| 13 @protocol PaymentRequestEditConsumer; | 12 @protocol PaymentRequestEditConsumer; |
| 14 | 13 |
| 15 namespace autofill { | 14 namespace autofill { |
| 16 class AutofillProfile; | 15 class AutofillProfile; |
| 17 } // namespace autofill | 16 } // namespace autofill |
| 18 | 17 |
| 18 namespace payments { |
| 19 class PaymentRequest; |
| 20 } // namespace payments |
| 21 |
| 19 // Serves as data source for AddressEditViewController. | 22 // Serves as data source for AddressEditViewController. |
| 20 @interface ContactInfoEditMediator | 23 @interface ContactInfoEditMediator |
| 21 : NSObject<PaymentRequestEditViewControllerDataSource> | 24 : NSObject<PaymentRequestEditViewControllerDataSource> |
| 22 | 25 |
| 23 // The consumer for this object. This can change during the lifetime of this | 26 // The consumer for this object. This can change during the lifetime of this |
| 24 // object and may be nil. | 27 // object and may be nil. |
| 25 @property(nonatomic, weak) id<PaymentRequestEditConsumer> consumer; | 28 @property(nonatomic, weak) id<PaymentRequestEditConsumer> consumer; |
| 26 | 29 |
| 27 // Initializes this object with an instance of PaymentRequest which has a copy | 30 // Initializes this object with an instance of PaymentRequest which has a copy |
| 28 // of web::PaymentRequest as provided by the page invoking the Payment Request | 31 // of web::PaymentRequest as provided by the page invoking the Payment Request |
| 29 // API as well as |profile| which is the profile to be edited, if any. | 32 // API as well as |profile| which is the profile to be edited, if any. |
| 30 // This object will not take ownership of |paymentRequest| or |profile|. | 33 // This object will not take ownership of |paymentRequest| or |profile|. |
| 31 - (instancetype)initWithPaymentRequest:(PaymentRequest*)paymentRequest | 34 - (instancetype)initWithPaymentRequest:(payments::PaymentRequest*)paymentRequest |
| 32 profile:(autofill::AutofillProfile*)profile | 35 profile:(autofill::AutofillProfile*)profile |
| 33 NS_DESIGNATED_INITIALIZER; | 36 NS_DESIGNATED_INITIALIZER; |
| 34 | 37 |
| 35 - (instancetype)init NS_UNAVAILABLE; | 38 - (instancetype)init NS_UNAVAILABLE; |
| 36 | 39 |
| 37 @end | 40 @end |
| 38 | 41 |
| 39 #endif // IOS_CHROME_BROWSER_UI_PAYMENTS_CONTACT_INFO_EDIT_MEDIATOR_H_ | 42 #endif // IOS_CHROME_BROWSER_UI_PAYMENTS_CONTACT_INFO_EDIT_MEDIATOR_H_ |
| OLD | NEW |