Skip to content

Commit c7c5afd

Browse files
committed
Merge pull request #288 from BranchMetrics/remove-alternate-init
launchOptions are required
2 parents eb3689d + 9c0846c commit c7c5afd

File tree

2 files changed

+0
-100
lines changed

2 files changed

+0
-100
lines changed

Branch-SDK/Branch-SDK/Branch.h

Lines changed: 0 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -241,13 +241,6 @@ typedef NS_ENUM(NSUInteger, BranchPromoCodeUsageType) {
241241
/// @name Initialization
242242
///---------------------
243243

244-
/**
245-
Just initialize the Branch session.
246-
247-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info, and any ability to do anything with the callback.
248-
*/
249-
- (void)initSession;
250-
251244
/**
252245
Just initialize the Branch session with the app launch options.
253246
@@ -256,30 +249,6 @@ typedef NS_ENUM(NSUInteger, BranchPromoCodeUsageType) {
256249
*/
257250
- (void)initSessionWithLaunchOptions:(NSDictionary *)options;
258251

259-
/**
260-
Just initialize the Branch session, specifying whether to allow it to be treated as a referral.
261-
262-
@param isReferrable Boolean representing whether to allow the session to be marked as referred, overriding the default behavior.
263-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info, and any ability to do anything with the callback.
264-
*/
265-
- (void)initSession:(BOOL)isReferrable;
266-
267-
/**
268-
Just initialize the Branch session, specifying whether to allow it to automatically display matching deep linked controllers
269-
270-
@param automaticallyDisplayController Boolean indicating whether we will automatically launch into deep linked controller matched in the init session dictionary.
271-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info by not passing the launch options.
272-
*/
273-
- (void)initSessionAndAutomaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController;
274-
275-
/**
276-
Initialize the Branch session and handle the completion with a callback
277-
278-
@param callback A callback that is called when the session is opened. This will be called multiple times during the apps life, including any time the app goes through a background / foreground cycle.
279-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info by not passing the launch options.
280-
*/
281-
- (void)initSessionAndRegisterDeepLinkHandler:(callbackWithParams)callback;
282-
283252
/**
284253
Just initialize the Branch session with the app launch options, specifying whether to allow it to be treated as a referral.
285254
@@ -289,15 +258,6 @@ typedef NS_ENUM(NSUInteger, BranchPromoCodeUsageType) {
289258
*/
290259
- (void)initSessionWithLaunchOptions:(NSDictionary *)options isReferrable:(BOOL)isReferrable;
291260

292-
/**
293-
Initialize the Branch session and handle the completion with a callback
294-
295-
@param isReferrable Boolean representing whether to allow the session to be marked as referred, overriding the default behavior.
296-
@param callback A callback that is called when the session is opened. This will be called multiple times during the apps life, including any time the app goes through a background / foreground cycle.
297-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info by not passing the launch options.
298-
*/
299-
- (void)initSession:(BOOL)isReferrable andRegisterDeepLinkHandler:(callbackWithParams)callback;
300-
301261
/**
302262
Initialize the Branch session with the app launch options and handle the completion with a callback
303263
@@ -322,24 +282,6 @@ typedef NS_ENUM(NSUInteger, BranchPromoCodeUsageType) {
322282
*/
323283
- (void)initSessionWithLaunchOptions:(NSDictionary *)options automaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController;
324284

325-
/**
326-
Initialize the Branch session and handle the completion with a callback
327-
328-
@param isReferrable Boolean representing whether to allow the session to be marked as referred, overriding the default behavior.
329-
@param automaticallyDisplayController Boolean indicating whether we will automatically launch into deep linked controller matched in the init session dictionary.
330-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info by not passing the launch options.
331-
*/
332-
- (void)initSession:(BOOL)isReferrable automaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController;
333-
334-
/**
335-
Initialize the Branch session and handle the completion with a callback
336-
337-
@param automaticallyDisplayController Boolean indicating whether we will automatically launch into deep linked controller matched in the init session dictionary.
338-
@param callback A callback that is called when the session is opened. This will be called multiple times during the apps life, including any time the app goes through a background / foreground cycle.
339-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info by not passing the launch options.
340-
*/
341-
- (void)initSessionAndAutomaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController deepLinkHandler:(callbackWithParams)callback;
342-
343285
/**
344286
Initialize the Branch session with the app launch options and handle the completion with a callback
345287
@@ -367,16 +309,6 @@ typedef NS_ENUM(NSUInteger, BranchPromoCodeUsageType) {
367309
*/
368310
- (void)initSessionWithLaunchOptions:(NSDictionary *)options automaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController deepLinkHandler:(callbackWithParams)callback;
369311

370-
/**
371-
Initialize the Branch session with the app launch options and handle the completion with a callback
372-
373-
@param automaticallyDisplayController Boolean indicating whether we will automatically launch into deep linked controller matched in the init session dictionary.
374-
@param isReferrable Boolean representing whether to allow the session to be marked as referred, overriding the default behavior.
375-
@param callback A callback that is called when the session is opened. This will be called multiple times during the apps life, including any time the app goes through a background / foreground cycle.
376-
@warning This is not the recommended method of initializing Branch, as you potentially lose deep linking info by not passing the launch options.
377-
*/
378-
- (void)initSessionAndAutomaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController isReferrable:(BOOL)isReferrable deepLinkHandler:(callbackWithParams)callback;
379-
380312
/**
381313
Initialize the Branch session with the app launch options and handle the completion with a callback
382314

Branch-SDK/Branch-SDK/Branch.m

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -261,26 +261,10 @@ - (void)accountForFacebookSDKPreventingAppLaunch {
261261

262262
#pragma mark - InitSession Permutation methods
263263

264-
- (void)initSession {
265-
[self initSessionWithLaunchOptions:nil isReferrable:YES explicitlyRequestedReferrable:NO automaticallyDisplayController:NO registerDeepLinkHandler:nil];
266-
}
267-
268-
- (void)initSessionAndAutomaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController {
269-
[self initSessionWithLaunchOptions:nil isReferrable:YES explicitlyRequestedReferrable:NO automaticallyDisplayController:automaticallyDisplayController registerDeepLinkHandler:nil];
270-
}
271-
272264
- (void)initSessionWithLaunchOptions:(NSDictionary *)options {
273265
[self initSessionWithLaunchOptions:options isReferrable:YES explicitlyRequestedReferrable:NO automaticallyDisplayController:NO registerDeepLinkHandler:nil];
274266
}
275267

276-
- (void)initSession:(BOOL)isReferrable {
277-
[self initSessionWithLaunchOptions:nil isReferrable:isReferrable explicitlyRequestedReferrable:YES automaticallyDisplayController:NO registerDeepLinkHandler:nil];
278-
}
279-
280-
- (void)initSessionAndRegisterDeepLinkHandler:(callbackWithParams)callback {
281-
[self initSessionWithLaunchOptions:nil isReferrable:YES explicitlyRequestedReferrable:NO automaticallyDisplayController:NO registerDeepLinkHandler:callback];
282-
}
283-
284268
- (void)initSessionWithLaunchOptions:(NSDictionary *)options andRegisterDeepLinkHandler:(callbackWithParams)callback {
285269
[self initSessionWithLaunchOptions:options isReferrable:YES explicitlyRequestedReferrable:NO automaticallyDisplayController:NO registerDeepLinkHandler:callback];
286270
}
@@ -297,18 +281,6 @@ - (void)initSessionWithLaunchOptions:(NSDictionary *)options automaticallyDispla
297281
[self initSessionWithLaunchOptions:options isReferrable:YES explicitlyRequestedReferrable:NO automaticallyDisplayController:automaticallyDisplayController registerDeepLinkHandler:nil];
298282
}
299283

300-
- (void)initSession:(BOOL)isReferrable andRegisterDeepLinkHandler:(callbackWithParams)callback {
301-
[self initSessionWithLaunchOptions:nil isReferrable:isReferrable explicitlyRequestedReferrable:YES automaticallyDisplayController:NO registerDeepLinkHandler:callback];
302-
}
303-
304-
- (void)initSession:(BOOL)isReferrable automaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController {
305-
[self initSessionWithLaunchOptions:nil isReferrable:isReferrable explicitlyRequestedReferrable:YES automaticallyDisplayController:automaticallyDisplayController registerDeepLinkHandler:nil];
306-
}
307-
308-
- (void)initSessionAndAutomaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController deepLinkHandler:(callbackWithParams)callback {
309-
[self initSessionWithLaunchOptions:nil isReferrable:YES explicitlyRequestedReferrable:NO automaticallyDisplayController:automaticallyDisplayController registerDeepLinkHandler:callback];
310-
}
311-
312284
- (void)initSessionWithLaunchOptions:(NSDictionary *)options isReferrable:(BOOL)isReferrable andRegisterDeepLinkHandler:(callbackWithParams)callback {
313285
[self initSessionWithLaunchOptions:options isReferrable:isReferrable explicitlyRequestedReferrable:YES automaticallyDisplayController:NO registerDeepLinkHandler:callback];
314286
}
@@ -321,10 +293,6 @@ - (void)initSessionWithLaunchOptions:(NSDictionary *)options isReferrable:(BOOL)
321293
[self initSessionWithLaunchOptions:options isReferrable:isReferrable explicitlyRequestedReferrable:YES automaticallyDisplayController:automaticallyDisplayController registerDeepLinkHandler:nil];
322294
}
323295

324-
- (void)initSessionAndAutomaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController isReferrable:(BOOL)isReferrable deepLinkHandler:(callbackWithParams)callback {
325-
[self initSessionWithLaunchOptions:nil isReferrable:isReferrable explicitlyRequestedReferrable:YES automaticallyDisplayController:automaticallyDisplayController registerDeepLinkHandler:callback];
326-
}
327-
328296
- (void)initSessionWithLaunchOptions:(NSDictionary *)options automaticallyDisplayDeepLinkController:(BOOL)automaticallyDisplayController isReferrable:(BOOL)isReferrable deepLinkHandler:(callbackWithParams)callback {
329297
[self initSessionWithLaunchOptions:options isReferrable:isReferrable explicitlyRequestedReferrable:YES automaticallyDisplayController:automaticallyDisplayController registerDeepLinkHandler:callback];
330298
}

0 commit comments

Comments
 (0)