Skip to content

Commit 0962271

Browse files
committed
⬆️ Upgrade native iOS frameworks for the new APIs
1 parent 74331c9 commit 0962271

23 files changed

+178
-57
lines changed

ios/Instabug.framework/Headers/Instabug.h

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,15 @@ NS_ASSUME_NONNULL_BEGIN
2121

2222
@interface Instabug : NSObject
2323

24+
@property (class, atomic, assign) IBGUserStepsMode trackUserSteps;
25+
@property (class, atomic, assign) BOOL autoScreenRecordingEnabled;
26+
@property (class, atomic, assign) CGFloat autoScreenRecordingDuration;
27+
@property (class, atomic, assign) BOOL shouldCaptureViewHierarchy;
28+
@property (class, atomic, strong) UIColor *tintColor;
29+
@property (class, atomic, strong) void (^didRecieveReplyHandler)(void);
30+
@property (class, atomic, assign) BOOL replyNotificationsEnabled;
31+
@property (class, atomic, assign) NSInteger unreadMessagesCount;
32+
2433
typedef void (^NetworkObfuscationCompletionBlock)(NSData *data, NSURLResponse *response);
2534

2635
/// ------------------------
@@ -38,7 +47,7 @@ typedef void (^NetworkObfuscationCompletionBlock)(NSData *data, NSURLResponse *r
3847
3948
@see IBGInvocationEvent
4049
*/
41-
+ (void)startWithToken:(NSString *)token invocationEvent:(IBGInvocationEvent)invocationEvent;
50+
+ (void)startWithToken:(NSString *)token invocationEvents:(IBGInvocationEvent)invocationEvent;
4251

4352
/// ---------------------------
4453
/// @name SDK Manual Invocation

ios/Instabug.framework/Info.plist

0 Bytes
Binary file not shown.

ios/Instabug.framework/Instabug

1.27 KB
Binary file not shown.

ios/Instabug.framework/_CodeSignature/CodeResources

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
<dict>
77
<key>Headers/Instabug.h</key>
88
<data>
9-
SGNYZhDFT2EX7GCTETfClZTQXJY=
9+
LHkO7JX4Jl8NY9ARKTJkWW8uFcY=
1010
</data>
1111
<key>Info.plist</key>
1212
<data>
13-
/nPkkrY39eMx9p9uHRbBsHajFMw=
13+
xP32eQS6UDAG+qlWM0PaXUkv7mQ=
1414
</data>
1515
<key>Modules/module.modulemap</key>
1616
<data>
@@ -23,11 +23,11 @@
2323
<dict>
2424
<key>hash</key>
2525
<data>
26-
SGNYZhDFT2EX7GCTETfClZTQXJY=
26+
LHkO7JX4Jl8NY9ARKTJkWW8uFcY=
2727
</data>
2828
<key>hash2</key>
2929
<data>
30-
WKOlkyFQLVjgThj0Q+rMJ+iJKaRVVs+lV56Ly76ap58=
30+
Hniald2Oa2/LXCGILyb4q44oTNkq1Ml9mHa2tnhUjuY=
3131
</data>
3232
</dict>
3333
<key>Modules/module.modulemap</key>
Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
//
2+
// IBGNetworkLogger.h
3+
// InstabugCore
4+
//
5+
// Created by Yousef Hamza on 5/17/18.
6+
// Copyright © 2018 Instabug. All rights reserved.
7+
//
8+
9+
#import <Foundation/Foundation.h>
10+
#import "IBGTypes.h"
11+
12+
@interface IBGNetworkLogger : NSObject
13+
14+
@property (class, atomic, assign) BOOL enabled;
15+
16+
/* CHECK NULLABILITY! */
17+
typedef void (^NetworkObfuscationCompletionBlock)(NSData * _Nullable data, NSURLResponse * _Nonnull response);
18+
19+
20+
/**
21+
@brief Enable logging for network requests and responses on a custom NSURLSessionConfiguration.
22+
23+
@discussion Logging for network requests and responses may not work if you're using a custom `NSURLSession` object.
24+
If this is the case, call this method passing in your custom NSURLSessions's configuration to enable logging for it.
25+
26+
@param URLSessionConfiguration The NSURLSessionConfiguration of your custom NSURLSession.
27+
*/
28+
+ (void)enableLoggingForURLSessionConfiguration:(NSURLSessionConfiguration *_Nonnull)URLSessionConfiguration;
29+
30+
31+
/**
32+
@brief Use to obfuscate a request that's going to be included in network logs.
33+
34+
@discussion Use this method if you want to make any modifications to requests before it is added to the network log.
35+
This won't be applied to already filtered requests
36+
37+
Note that thsese changes doesn't affect the actual request.
38+
39+
The provided block will be called for every request. You should do whatever processing you need to do on the request inside
40+
that block, then return a request to be included in network logs.
41+
42+
This method usage overrides modifications made by `setNetworkLoggingURLObfuscationHandler:`.
43+
44+
@param obfuscationHandler A block that takes a request and returns a new modified one to be logged..
45+
*/
46+
+ (void)setRequestObfuscationHandler:(nonnull NSURLRequest * _Nonnull (^)(NSURLRequest * _Nonnull request))obfuscationHandler;
47+
48+
/**
49+
@brief Use to obfuscate a request's response that's going to be included in network logs.
50+
51+
@discussion Use this method if you want to make any modifications to a request's respone and its data before it's
52+
added to network logs.
53+
54+
The provided block will be called for every response. You should do whatever processing you need to do on the response
55+
and data inside that block, then return response and data to be included in network logs. Changes you make to the
56+
response and its data only affect network logs, not the actual response.
57+
58+
@param obfuscationHandler A block that takes the original response, its data and a return block as parameters. The
59+
return block should be called with the modified data and response.
60+
*/
61+
+ (void)setResponseObfuscationHandler:(void (^_Nonnull)(NSData * _Nullable responseData, NSURLResponse * _Nonnull response, NetworkObfuscationCompletionBlock _Nonnull returnBlock))obfuscationHandler;
62+
63+
/**
64+
@brief Use to get callbacks about progress of sending body content of a particular request when networking logging is
65+
enabled.
66+
67+
@discussion The provided block will get periodical callbacks about the progress of sending the body content of a request.
68+
69+
@param URL URL which will be attached with requestProgressHandler.
70+
@param requestProgressHandler A block that will be called for the requestURL when SDK intercept that request.
71+
72+
*/
73+
+ (void)setProgressHandlerForRequestURL:(nonnull NSURL *)URL
74+
progressHandler:(nonnull void (^)(NSURLSessionTask * _Nonnull task, int64_t bytesSent, int64_t totalBytesSent, int64_t totalBytesExpectedToSend))requestProgressHandler;
75+
76+
77+
/**
78+
@brief Used to ask whether your app is prepared to handle a particular authentication challenge. Can be called on any thread.
79+
80+
@discussion Set this block if your app implements SSL pinning and you have network logging enabled.
81+
82+
@param protectionSpaceHandler A block that takes the protection space for the authentication challenge and should return
83+
true or false.
84+
*/
85+
+ (void)setCanAuthenticateAgainstProtectionSpaceHandler:(BOOL(^_Nonnull)(NSURLProtectionSpace * _Nonnull protectionSpace))protectionSpaceHandler;
86+
87+
88+
/**
89+
@brief Used to process an authentication challenge and return an NSURLCredential object.
90+
91+
@discussion Set this block if your app implements SSL pinning and you have network logging enabled.
92+
93+
@param reciveChallengeHandler A block that takes the authentication challenge and returns NSURLCredential.
94+
*/
95+
+ (void)setDidReceiveAuthenticationChallengeHandler:(NSURLCredential* _Nonnull (^_Nonnull)(NSURLAuthenticationChallenge * _Nonnull challenge))reciveChallengeHandler;
96+
97+
@end

ios/InstabugCore.framework/Headers/IBGTypes.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -138,9 +138,7 @@ extern NSString * const kIBGReplyButtonTitleStringName;
138138
/**
139139
The event used to invoke the feedback form.
140140
*/
141-
typedef NS_ENUM(NSInteger, IBGInvocationEvent) {
142-
/** No event will be registered to show the feedback form, you'll need to code your own and call the method showFeedbackForm. */
143-
IBGInvocationEventNone,
141+
typedef NS_OPTIONS(NSInteger, IBGInvocationEvent) {
144142
/** Shaking the device while in any screen to show the feedback form. */
145143
IBGInvocationEventShake,
146144
/** Taking a screenshot using the Home+Lock buttons while in any screen to show the feedback form. */
@@ -150,7 +148,9 @@ typedef NS_ENUM(NSInteger, IBGInvocationEvent) {
150148
/** Swiping one finger left from the right edge of the screen to show the feedback form, substituted with IBGInvocationEventTwoFingersSwipeLeft on iOS 6.1.3 and earlier. */
151149
IBGInvocationEventRightEdgePan,
152150
/** Shows a floating button on top of all views, when pressed it takes a screenshot. */
153-
IBGInvocationEventFloatingButton
151+
IBGInvocationEventFloatingButton,
152+
/** No event will be registered to show the feedback form, you'll need to code your own and call the method showFeedbackForm. */
153+
IBGInvocationEventNone,
154154
};
155155

156156
/**
Binary file not shown.
Binary file not shown.
12 Bytes
Binary file not shown.
-2 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)