diff options
author | sdefresne <sdefresne@chromium.org> | 2015-04-24 07:43:30 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-04-24 14:44:10 +0000 |
commit | 9816d5ee8bd97ac1a9432209342d9cf02fba3c3e (patch) | |
tree | 2da43eaa6410b013aad05034693755deacf0ca5a /ios/chrome/browser/xcallback_parameters.h | |
parent | 36b5175060ed76723abb89a0aa7f1563c43ff4c5 (diff) | |
download | chromium_src-9816d5ee8bd97ac1a9432209342d9cf02fba3c3e.zip chromium_src-9816d5ee8bd97ac1a9432209342d9cf02fba3c3e.tar.gz chromium_src-9816d5ee8bd97ac1a9432209342d9cf02fba3c3e.tar.bz2 |
[iOS] Upstream XCallbackParameters
XCallbackParameters holds the information about an x-callback request from
another application.
BUG=429756
Review URL: https://codereview.chromium.org/1095203006
Cr-Commit-Position: refs/heads/master@{#326793}
Diffstat (limited to 'ios/chrome/browser/xcallback_parameters.h')
-rw-r--r-- | ios/chrome/browser/xcallback_parameters.h | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/ios/chrome/browser/xcallback_parameters.h b/ios/chrome/browser/xcallback_parameters.h new file mode 100644 index 0000000..82b8996 --- /dev/null +++ b/ios/chrome/browser/xcallback_parameters.h @@ -0,0 +1,38 @@ +// Copyright 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef IOS_CHROME_BROWSER_XCALLBACK_PARAMETERS_H_ +#define IOS_CHROME_BROWSER_XCALLBACK_PARAMETERS_H_ + +#import <Foundation/Foundation.h> + +#include "url/gurl.h" + +// This class contains the defining parameters for an XCallback request from +// another app. +@interface XCallbackParameters : NSObject<NSCoding, NSCopying> + +// The id of the calling app. +@property(nonatomic, readonly, copy) NSString* sourceAppId; + +// The user visible name of the calling app. Can be nil. +@property(nonatomic, readonly, copy) NSString* sourceAppName; + +// x-callback-url::x-success URL. If the app is opened using a x-callback-url +// compliant URL, the value of this parameter is used as callback URL when the +// user taps the back button. +@property(nonatomic, readonly) const GURL& successURL; + +// Flag to force the creation of a new tab. Default YES. +@property(nonatomic, readonly) BOOL createNewTab; + +- (instancetype)initWithSourceAppId:(NSString*)sourceAppId + sourceAppName:(NSString*)sourceAppName + successURL:(const GURL&)successURL + createNewTab:(BOOL)createNewTab + NS_DESIGNATED_INITIALIZER; + +@end + +#endif // IOS_CHROME_BROWSER_XCALLBACK_PARAMETERS_H_ |