react-native-blob-util 0.17.2 → 0.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -5
- package/android/src/main/java/com/ReactNativeBlobUtil/ReactNativeBlobUtilConst.java +1 -0
- package/android/src/main/java/com/ReactNativeBlobUtil/ReactNativeBlobUtilFS.java +2 -3
- package/android/src/main/java/com/ReactNativeBlobUtil/ReactNativeBlobUtilReq.java +29 -12
- package/android/src/main/java/com/ReactNativeBlobUtil/ReactNativeBlobUtilStream.java +8 -3
- package/android/src/newarch/java/com/ReactNativeBlobUtil/ReactNativeBlobUtil.java +11 -0
- package/android/src/oldarch/java/com/ReactNativeBlobUtil/ReactNativeBlobUtil.java +11 -0
- package/class/ReactNativeBlobUtilReadStream.js +66 -62
- package/class/ReactNativeBlobUtilSession.js +6 -11
- package/class/ReactNativeBlobUtilWriteStream.js +4 -9
- package/codegenSpecs/NativeBlobUtils.js +6 -9
- package/fetch.js +30 -23
- package/index.d.ts +4 -0
- package/index.js +2 -14
- package/ios/ReactNativeBlobUtil/ReactNativeBlobUtil.h +5 -4
- package/ios/ReactNativeBlobUtil/ReactNativeBlobUtil.mm +44 -26
- package/ios/ReactNativeBlobUtil.xcodeproj/project.pbxproj +117 -36
- package/ios/ReactNativeBlobUtilConst.h +1 -0
- package/ios/ReactNativeBlobUtilConst.mm +1 -0
- package/ios/ReactNativeBlobUtilFS.h +1 -4
- package/ios/ReactNativeBlobUtilFS.mm +24 -30
- package/ios/ReactNativeBlobUtilNetwork.h +1 -2
- package/ios/ReactNativeBlobUtilNetwork.mm +2 -24
- package/ios/ReactNativeBlobUtilRequest.h +3 -4
- package/ios/ReactNativeBlobUtilRequest.mm +8 -17
- package/package.json +4 -4
- package/windows/ReactNativeBlobUtil/ReactNativeBlobUtil.vcxproj +2 -1
package/index.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
// Use of this source code is governed by a MIT-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
-
import {AppState, DeviceEventEmitter, Platform,} from 'react-native';
|
|
6
5
|
import ReactNativeBlobUtil from './codegenSpecs/NativeBlobUtils';
|
|
7
6
|
|
|
8
7
|
//import StatefulPromise from './class/StatefulPromise.js'
|
|
@@ -14,8 +13,8 @@ import android from './android';
|
|
|
14
13
|
import ios from './ios';
|
|
15
14
|
import JSONStream from './json-stream';
|
|
16
15
|
import {config, fetch} from './fetch';
|
|
17
|
-
import URIUtil from
|
|
18
|
-
import CanceledFetchError from
|
|
16
|
+
import URIUtil from './utils/uri';
|
|
17
|
+
import CanceledFetchError from './class/ReactNativeBlobUtilCanceledFetchError';
|
|
19
18
|
|
|
20
19
|
const {
|
|
21
20
|
ReactNativeBlobUtilSession,
|
|
@@ -34,19 +33,8 @@ const {
|
|
|
34
33
|
} = fs;
|
|
35
34
|
|
|
36
35
|
const Blob = polyfill.Blob;
|
|
37
|
-
const emitter = DeviceEventEmitter;
|
|
38
36
|
const wrap = URIUtil.wrap;
|
|
39
37
|
|
|
40
|
-
// when app resumes, check if there's any expired network task and trigger
|
|
41
|
-
// their .expire event
|
|
42
|
-
if (Platform.OS === 'ios') {
|
|
43
|
-
AppState.addEventListener('change', (e) => {
|
|
44
|
-
if (e === 'active')
|
|
45
|
-
ReactNativeBlobUtil.emitExpiredEvent(() => {
|
|
46
|
-
});
|
|
47
|
-
});
|
|
48
|
-
}
|
|
49
|
-
|
|
50
38
|
// Show warning if native module not detected
|
|
51
39
|
if (!ReactNativeBlobUtil || !ReactNativeBlobUtil.fetchBlobForm || !ReactNativeBlobUtil.fetchBlob) {
|
|
52
40
|
console.warn(
|
|
@@ -16,14 +16,14 @@
|
|
|
16
16
|
#import <React/RCTLog.h>
|
|
17
17
|
#import <React/RCTRootView.h>
|
|
18
18
|
#import <React/RCTBridge.h>
|
|
19
|
-
#import <React/RCTEventDispatcher.h>
|
|
20
19
|
#import <React/RCTBridgeModule.h>
|
|
20
|
+
#import <React/RCTEventEmitter.h>
|
|
21
21
|
#else
|
|
22
22
|
#import "RCTBridgeModule.h"
|
|
23
23
|
#import "RCTLog.h"
|
|
24
24
|
#import "RCTRootView.h"
|
|
25
25
|
#import "RCTBridge.h"
|
|
26
|
-
#import "
|
|
26
|
+
#import "RCTEventEmitter.h"
|
|
27
27
|
#endif
|
|
28
28
|
|
|
29
29
|
#import <UIKit/UIKit.h>
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
#endif
|
|
34
34
|
|
|
35
35
|
|
|
36
|
-
@interface ReactNativeBlobUtil :
|
|
36
|
+
@interface ReactNativeBlobUtil : RCTEventEmitter <RCTBridgeModule, UIDocumentInteractionControllerDelegate> {
|
|
37
37
|
|
|
38
38
|
NSString * filePathPrefix;
|
|
39
39
|
|
|
@@ -42,7 +42,8 @@
|
|
|
42
42
|
@property (nonatomic) NSString * filePathPrefix;
|
|
43
43
|
@property (retain) UIDocumentInteractionController * documentController;
|
|
44
44
|
|
|
45
|
-
|
|
45
|
+
-(void) emitEvent:(NSString *)name body:(NSString *) body;
|
|
46
|
+
-(void) emitEventDict:(NSString *)name body:(NSDictionary *) body;
|
|
46
47
|
|
|
47
48
|
@end
|
|
48
49
|
|
|
@@ -15,7 +15,6 @@
|
|
|
15
15
|
#import <ReactNativeBlobUtilSpec/ReactNativeBlobUtilSpec.h>
|
|
16
16
|
#endif
|
|
17
17
|
|
|
18
|
-
__strong RCTEventDispatcher * eventDispatcherRef;
|
|
19
18
|
dispatch_queue_t commonTaskQueue;
|
|
20
19
|
dispatch_queue_t fsQueue;
|
|
21
20
|
|
|
@@ -31,6 +30,45 @@ dispatch_queue_t fsQueue;
|
|
|
31
30
|
|
|
32
31
|
@synthesize filePathPrefix;
|
|
33
32
|
@synthesize documentController;
|
|
33
|
+
@synthesize bridge;
|
|
34
|
+
bool hasListeners;
|
|
35
|
+
|
|
36
|
+
- (NSArray<NSString*> *)supportedEvents {
|
|
37
|
+
return @[@"ReactNativeBlobUtilState", @"ReactNativeBlobUtilServerPush", @"ReactNativeBlobUtilProgress", @"ReactNativeBlobUtilProgress-upload", @"ReactNativeBlobUtilExpire", @"ReactNativeBlobUtilMessage", @"ReactNativeBlobUtilFilesystem", @"log", @"warn", @"error", @"data", @"end", @"reportProgress", @"reportUploadProgress"];
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// Will be called when this module's first listener is added.
|
|
41
|
+
-(void)startObserving {
|
|
42
|
+
hasListeners = YES;
|
|
43
|
+
// Set up any upstream listeners or background tasks as necessary
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
// Will be called when this module's last listener is removed, or on dealloc.
|
|
47
|
+
-(void)stopObserving {
|
|
48
|
+
hasListeners = NO;
|
|
49
|
+
// Remove upstream listeners, stop unnecessary background tasks
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
- (void)emitEvent:(NSString *)name body:(NSString *) body
|
|
53
|
+
{
|
|
54
|
+
if (hasListeners) {// Only send events if anyone is listening
|
|
55
|
+
[self sendEventWithName:name body:body];
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
- (void)emitEventDict:(NSString *)name body:(NSDictionary *) body
|
|
59
|
+
{
|
|
60
|
+
NSError *error;
|
|
61
|
+
NSData *jsonData = [NSJSONSerialization dataWithJSONObject:body
|
|
62
|
+
options:NSJSONWritingPrettyPrinted
|
|
63
|
+
error:&error];
|
|
64
|
+
|
|
65
|
+
if (error) {
|
|
66
|
+
NSLog(@"Got an error: %@", error);
|
|
67
|
+
} else {
|
|
68
|
+
NSString *jsonString = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding];
|
|
69
|
+
[self emitEvent:name body:jsonString];
|
|
70
|
+
}
|
|
71
|
+
}
|
|
34
72
|
|
|
35
73
|
- (dispatch_queue_t) methodQueue {
|
|
36
74
|
if(commonTaskQueue == nil)
|
|
@@ -38,15 +76,6 @@ dispatch_queue_t fsQueue;
|
|
|
38
76
|
return commonTaskQueue;
|
|
39
77
|
}
|
|
40
78
|
|
|
41
|
-
+ (RCTEventDispatcher *)getRCTEventDispatcher
|
|
42
|
-
{
|
|
43
|
-
RCTRootView * rootView = (RCTRootView*) [[UIApplication sharedApplication] keyWindow].rootViewController.view;
|
|
44
|
-
#if RCT_NEW_ARCH_ENABLED
|
|
45
|
-
return (RCTEventDispatcher *)[rootView.moduleRegistry moduleForName:"EventDispatcher"];
|
|
46
|
-
#else
|
|
47
|
-
return rootView.bridge.eventDispatcher;
|
|
48
|
-
#endif
|
|
49
|
-
}
|
|
50
79
|
|
|
51
80
|
+ (BOOL)requiresMainQueueSetup {
|
|
52
81
|
return NO;
|
|
@@ -66,10 +95,6 @@ RCT_EXPORT_MODULE();
|
|
|
66
95
|
if(![[NSFileManager defaultManager] fileExistsAtPath: [ReactNativeBlobUtilFS getTempPath] isDirectory:&isDir]) {
|
|
67
96
|
[[NSFileManager defaultManager] createDirectoryAtPath:[ReactNativeBlobUtilFS getTempPath] withIntermediateDirectories:YES attributes:nil error:NULL];
|
|
68
97
|
}
|
|
69
|
-
dispatch_async(dispatch_get_main_queue(), ^{
|
|
70
|
-
eventDispatcherRef = [ReactNativeBlobUtil getRCTEventDispatcher];
|
|
71
|
-
[ReactNativeBlobUtilNetwork emitExpiredTasks: eventDispatcherRef];
|
|
72
|
-
});
|
|
73
98
|
|
|
74
99
|
return self;
|
|
75
100
|
}
|
|
@@ -95,7 +120,7 @@ RCT_EXPORT_MODULE();
|
|
|
95
120
|
@"SDCardDir": @"",
|
|
96
121
|
@"SDCardApplicationDir": @"",
|
|
97
122
|
@"DCIMDir": @"",
|
|
98
|
-
// Android only legacy constants
|
|
123
|
+
// Android only legacy constants
|
|
99
124
|
@"LegacyDCIMDir": @"",
|
|
100
125
|
@"LegacyPictureDir": @"",
|
|
101
126
|
@"LegacyMusicDir": @"",
|
|
@@ -134,7 +159,7 @@ RCT_EXPORT_METHOD(fetchBlobForm:(NSDictionary *)options
|
|
|
134
159
|
{
|
|
135
160
|
[[ReactNativeBlobUtilNetwork sharedInstance] sendRequest:options
|
|
136
161
|
contentLength:bodyLength
|
|
137
|
-
|
|
162
|
+
baseModule:self
|
|
138
163
|
taskId:taskId
|
|
139
164
|
withRequest:req
|
|
140
165
|
callback:callback];
|
|
@@ -171,7 +196,7 @@ RCT_EXPORT_METHOD(fetchBlob:(NSDictionary *)options
|
|
|
171
196
|
{
|
|
172
197
|
[[ReactNativeBlobUtilNetwork sharedInstance] sendRequest:options
|
|
173
198
|
contentLength:bodyLength
|
|
174
|
-
|
|
199
|
+
baseModule:self
|
|
175
200
|
taskId:taskId
|
|
176
201
|
withRequest:req
|
|
177
202
|
callback:callback];
|
|
@@ -365,7 +390,7 @@ RCT_EXPORT_METHOD(writeStream:(NSString *)path
|
|
|
365
390
|
appendData:(BOOL)append
|
|
366
391
|
callback:(RCTResponseSenderBlock)callback)
|
|
367
392
|
{
|
|
368
|
-
ReactNativeBlobUtilFS * fileStream = [[ReactNativeBlobUtilFS alloc]
|
|
393
|
+
ReactNativeBlobUtilFS * fileStream = [[ReactNativeBlobUtilFS alloc] init];
|
|
369
394
|
NSFileManager * fm = [NSFileManager defaultManager];
|
|
370
395
|
NSString * folder = [path stringByDeletingLastPathComponent];
|
|
371
396
|
NSError* err = nil;
|
|
@@ -695,7 +720,7 @@ RCT_EXPORT_METHOD(readStream:(NSString *)path encoding:(NSString *)encoding buff
|
|
|
695
720
|
}
|
|
696
721
|
|
|
697
722
|
dispatch_async(fsQueue, ^{
|
|
698
|
-
[ReactNativeBlobUtilFS readStream:path encoding:encoding bufferSize:bufferSize tick:tick streamId:streamId
|
|
723
|
+
[ReactNativeBlobUtilFS readStream:path encoding:encoding bufferSize:bufferSize tick:tick streamId:streamId baseModule:self];
|
|
699
724
|
});
|
|
700
725
|
}
|
|
701
726
|
|
|
@@ -876,13 +901,6 @@ RCT_EXPORT_METHOD(df:(RCTResponseSenderBlock)callback)
|
|
|
876
901
|
return window.rootViewController;
|
|
877
902
|
}
|
|
878
903
|
|
|
879
|
-
# pragma mark - check expired network events
|
|
880
|
-
|
|
881
|
-
RCT_EXPORT_METHOD(emitExpiredEvent:(RCTResponseSenderBlock)callback)
|
|
882
|
-
{
|
|
883
|
-
[ReactNativeBlobUtilNetwork emitExpiredTasks:eventDispatcherRef];
|
|
884
|
-
}
|
|
885
|
-
|
|
886
904
|
# pragma mark - Android Only methods
|
|
887
905
|
// These methods are required because in the New Arch we have a single spec for both platforms
|
|
888
906
|
- (void)actionViewIntent:(NSString *) path
|
|
@@ -7,15 +7,16 @@
|
|
|
7
7
|
objects = {
|
|
8
8
|
|
|
9
9
|
/* Begin PBXBuildFile section */
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
10
|
+
11A307EE2A06E45800E56674 /* ReactNativeBlobUtil.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307ED2A06E45800E56674 /* ReactNativeBlobUtil.mm */; };
|
|
11
|
+
11A307F82A06E47700E56674 /* ReactNativeBlobUtilNetwork.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307EF2A06E47300E56674 /* ReactNativeBlobUtilNetwork.mm */; };
|
|
12
|
+
11A307F92A06E47700E56674 /* ReactNativeBlobUtilReqBuilder.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307F02A06E47400E56674 /* ReactNativeBlobUtilReqBuilder.mm */; };
|
|
13
|
+
11A307FA2A06E47700E56674 /* ReactNativeBlobUtilFS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307F12A06E47400E56674 /* ReactNativeBlobUtilFS.mm */; };
|
|
14
|
+
11A307FB2A06E47700E56674 /* ReactNativeBlobUtilFileTransformer.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307F32A06E47400E56674 /* ReactNativeBlobUtilFileTransformer.mm */; };
|
|
15
|
+
11A307FC2A06E47700E56674 /* ReactNativeBlobUtilConst.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307F42A06E47500E56674 /* ReactNativeBlobUtilConst.mm */; };
|
|
16
|
+
11A307FD2A06E47700E56674 /* ReactNativeBlobUtilProgress.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307F52A06E47500E56674 /* ReactNativeBlobUtilProgress.mm */; };
|
|
17
|
+
11A307FE2A06E47700E56674 /* ReactNativeBlobUtilRequest.mm in Sources */ = {isa = PBXBuildFile; fileRef = 11A307F62A06E47500E56674 /* ReactNativeBlobUtilRequest.mm */; };
|
|
18
|
+
11A308002A06E92D00E56674 /* React.podspec in Frameworks */ = {isa = PBXBuildFile; fileRef = 11A307FF2A06E92D00E56674 /* React.podspec */; };
|
|
16
19
|
A166D1AA1CE0647A00273590 /* ReactNativeBlobUtil.h in Sources */ = {isa = PBXBuildFile; fileRef = A15C30111CD25C330074CB35 /* ReactNativeBlobUtil.h */; };
|
|
17
|
-
A19B48251D98102400E6868A /* ReactNativeBlobUtilProgress.m in Sources */ = {isa = PBXBuildFile; fileRef = A19B48241D98102400E6868A /* ReactNativeBlobUtilProgress.m */; };
|
|
18
|
-
A1AAE2991D300E4D0051D11C /* ReactNativeBlobUtilReqBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = A1AAE2981D300E4D0051D11C /* ReactNativeBlobUtilReqBuilder.m */; };
|
|
19
20
|
/* End PBXBuildFile section */
|
|
20
21
|
|
|
21
22
|
/* Begin PBXCopyFilesBuildPhase section */
|
|
@@ -31,23 +32,28 @@
|
|
|
31
32
|
/* End PBXCopyFilesBuildPhase section */
|
|
32
33
|
|
|
33
34
|
/* Begin PBXFileReference section */
|
|
35
|
+
11A307ED2A06E45800E56674 /* ReactNativeBlobUtil.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = ReactNativeBlobUtil.mm; path = ReactNativeBlobUtil/ReactNativeBlobUtil.mm; sourceTree = "<group>"; };
|
|
36
|
+
11A307EF2A06E47300E56674 /* ReactNativeBlobUtilNetwork.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ReactNativeBlobUtilNetwork.mm; sourceTree = "<group>"; };
|
|
37
|
+
11A307F02A06E47400E56674 /* ReactNativeBlobUtilReqBuilder.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ReactNativeBlobUtilReqBuilder.mm; sourceTree = "<group>"; };
|
|
38
|
+
11A307F12A06E47400E56674 /* ReactNativeBlobUtilFS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ReactNativeBlobUtilFS.mm; sourceTree = "<group>"; };
|
|
39
|
+
11A307F22A06E47400E56674 /* ReactNativeBlobUtil */ = {isa = PBXFileReference; lastKnownFileType = folder; path = ReactNativeBlobUtil; sourceTree = "<group>"; };
|
|
40
|
+
11A307F32A06E47400E56674 /* ReactNativeBlobUtilFileTransformer.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ReactNativeBlobUtilFileTransformer.mm; sourceTree = "<group>"; };
|
|
41
|
+
11A307F42A06E47500E56674 /* ReactNativeBlobUtilConst.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ReactNativeBlobUtilConst.mm; sourceTree = "<group>"; };
|
|
42
|
+
11A307F52A06E47500E56674 /* ReactNativeBlobUtilProgress.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ReactNativeBlobUtilProgress.mm; sourceTree = "<group>"; };
|
|
43
|
+
11A307F62A06E47500E56674 /* ReactNativeBlobUtilRequest.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ReactNativeBlobUtilRequest.mm; sourceTree = "<group>"; };
|
|
44
|
+
11A307FF2A06E92D00E56674 /* React.podspec */ = {isa = PBXFileReference; lastKnownFileType = text; name = React.podspec; path = "../node_modules/react-native/React.podspec"; sourceTree = "<group>"; };
|
|
45
|
+
1BDA30C5220621C99F823CB9 /* Pods-ReactNativeBlobUtil.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ReactNativeBlobUtil.release.xcconfig"; path = "Target Support Files/Pods-ReactNativeBlobUtil/Pods-ReactNativeBlobUtil.release.xcconfig"; sourceTree = "<group>"; };
|
|
46
|
+
636B49C8101263AC402FD024 /* Pods_ReactNativeBlobUtil.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_ReactNativeBlobUtil.framework; sourceTree = BUILT_PRODUCTS_DIR; };
|
|
34
47
|
8C4801A4200CF71700FED7ED /* ReactNativeBlobUtilRequest.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ReactNativeBlobUtilRequest.h; sourceTree = "<group>"; };
|
|
35
|
-
8C4801A5200CF71700FED7ED /* ReactNativeBlobUtilRequest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ReactNativeBlobUtilRequest.m; sourceTree = "<group>"; };
|
|
36
48
|
9FD8D3C126F1709A00009F35 /* ReactNativeBlobUtilFileTransformer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ReactNativeBlobUtilFileTransformer.h; sourceTree = "<group>"; };
|
|
37
|
-
9FD8D3C226F1736000009F35 /* ReactNativeBlobUtilFileTransformer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ReactNativeBlobUtilFileTransformer.m; sourceTree = "<group>"; };
|
|
38
|
-
A158F4261D052E49006FFD38 /* ReactNativeBlobUtilFS.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ReactNativeBlobUtilFS.m; sourceTree = "<group>"; };
|
|
39
49
|
A158F4281D052E57006FFD38 /* ReactNativeBlobUtilFS.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ReactNativeBlobUtilFS.h; sourceTree = "<group>"; };
|
|
40
50
|
A158F4291D0534A9006FFD38 /* ReactNativeBlobUtilConst.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ReactNativeBlobUtilConst.h; sourceTree = "<group>"; };
|
|
41
|
-
A158F42C1D0535BB006FFD38 /* ReactNativeBlobUtilConst.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ReactNativeBlobUtilConst.m; sourceTree = "<group>"; };
|
|
42
51
|
A158F42E1D0539CE006FFD38 /* ReactNativeBlobUtilNetwork.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ReactNativeBlobUtilNetwork.h; sourceTree = "<group>"; };
|
|
43
|
-
A158F42F1D0539DB006FFD38 /* ReactNativeBlobUtilNetwork.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ReactNativeBlobUtilNetwork.m; sourceTree = "<group>"; };
|
|
44
52
|
A15C300E1CD25C330074CB35 /* libReactNativeBlobUtil.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libReactNativeBlobUtil.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
|
45
53
|
A15C30111CD25C330074CB35 /* ReactNativeBlobUtil.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = ReactNativeBlobUtil.h; path = ReactNativeBlobUtil/ReactNativeBlobUtil.h; sourceTree = "<group>"; };
|
|
46
|
-
A15C30131CD25C330074CB35 /* ReactNativeBlobUtil.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = ReactNativeBlobUtil.m; path = ReactNativeBlobUtil/ReactNativeBlobUtil.m; sourceTree = "<group>"; };
|
|
47
54
|
A19B48231D98100800E6868A /* ReactNativeBlobUtilProgress.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ReactNativeBlobUtilProgress.h; sourceTree = "<group>"; };
|
|
48
|
-
A19B48241D98102400E6868A /* ReactNativeBlobUtilProgress.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ReactNativeBlobUtilProgress.m; sourceTree = "<group>"; };
|
|
49
55
|
A1AAE2971D300E3E0051D11C /* ReactNativeBlobUtilReqBuilder.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ReactNativeBlobUtilReqBuilder.h; sourceTree = "<group>"; };
|
|
50
|
-
|
|
56
|
+
E83F89B1EFF498D9833537A4 /* Pods-ReactNativeBlobUtil.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ReactNativeBlobUtil.debug.xcconfig"; path = "Target Support Files/Pods-ReactNativeBlobUtil/Pods-ReactNativeBlobUtil.debug.xcconfig"; sourceTree = "<group>"; };
|
|
51
57
|
/* End PBXFileReference section */
|
|
52
58
|
|
|
53
59
|
/* Begin PBXFrameworksBuildPhase section */
|
|
@@ -55,12 +61,22 @@
|
|
|
55
61
|
isa = PBXFrameworksBuildPhase;
|
|
56
62
|
buildActionMask = 2147483647;
|
|
57
63
|
files = (
|
|
64
|
+
11A308002A06E92D00E56674 /* React.podspec in Frameworks */,
|
|
58
65
|
);
|
|
59
66
|
runOnlyForDeploymentPostprocessing = 0;
|
|
60
67
|
};
|
|
61
68
|
/* End PBXFrameworksBuildPhase section */
|
|
62
69
|
|
|
63
70
|
/* Begin PBXGroup section */
|
|
71
|
+
193768812AF9A9C46358234E /* Frameworks */ = {
|
|
72
|
+
isa = PBXGroup;
|
|
73
|
+
children = (
|
|
74
|
+
11A307FF2A06E92D00E56674 /* React.podspec */,
|
|
75
|
+
636B49C8101263AC402FD024 /* Pods_ReactNativeBlobUtil.framework */,
|
|
76
|
+
);
|
|
77
|
+
name = Frameworks;
|
|
78
|
+
sourceTree = "<group>";
|
|
79
|
+
};
|
|
64
80
|
8BD9ABDFAF76406291A798F2 /* Libraries */ = {
|
|
65
81
|
isa = PBXGroup;
|
|
66
82
|
children = (
|
|
@@ -71,24 +87,27 @@
|
|
|
71
87
|
A15C30051CD25C330074CB35 = {
|
|
72
88
|
isa = PBXGroup;
|
|
73
89
|
children = (
|
|
74
|
-
|
|
90
|
+
11A307F22A06E47400E56674 /* ReactNativeBlobUtil */,
|
|
91
|
+
11A307F42A06E47500E56674 /* ReactNativeBlobUtilConst.mm */,
|
|
92
|
+
11A307F32A06E47400E56674 /* ReactNativeBlobUtilFileTransformer.mm */,
|
|
93
|
+
11A307F12A06E47400E56674 /* ReactNativeBlobUtilFS.mm */,
|
|
94
|
+
11A307EF2A06E47300E56674 /* ReactNativeBlobUtilNetwork.mm */,
|
|
95
|
+
11A307F52A06E47500E56674 /* ReactNativeBlobUtilProgress.mm */,
|
|
96
|
+
11A307F02A06E47400E56674 /* ReactNativeBlobUtilReqBuilder.mm */,
|
|
97
|
+
11A307F62A06E47500E56674 /* ReactNativeBlobUtilRequest.mm */,
|
|
98
|
+
11A307ED2A06E45800E56674 /* ReactNativeBlobUtil.mm */,
|
|
75
99
|
9FD8D3C126F1709A00009F35 /* ReactNativeBlobUtilFileTransformer.h */,
|
|
76
|
-
A19B48241D98102400E6868A /* ReactNativeBlobUtilProgress.m */,
|
|
77
100
|
A19B48231D98100800E6868A /* ReactNativeBlobUtilProgress.h */,
|
|
78
|
-
A1AAE2981D300E4D0051D11C /* ReactNativeBlobUtilReqBuilder.m */,
|
|
79
101
|
A1AAE2971D300E3E0051D11C /* ReactNativeBlobUtilReqBuilder.h */,
|
|
80
102
|
A158F42E1D0539CE006FFD38 /* ReactNativeBlobUtilNetwork.h */,
|
|
81
|
-
A158F42F1D0539DB006FFD38 /* ReactNativeBlobUtilNetwork.m */,
|
|
82
103
|
8C4801A4200CF71700FED7ED /* ReactNativeBlobUtilRequest.h */,
|
|
83
|
-
8C4801A5200CF71700FED7ED /* ReactNativeBlobUtilRequest.m */,
|
|
84
|
-
A158F42C1D0535BB006FFD38 /* ReactNativeBlobUtilConst.m */,
|
|
85
104
|
A158F4291D0534A9006FFD38 /* ReactNativeBlobUtilConst.h */,
|
|
86
105
|
A158F4281D052E57006FFD38 /* ReactNativeBlobUtilFS.h */,
|
|
87
|
-
A158F4261D052E49006FFD38 /* ReactNativeBlobUtilFS.m */,
|
|
88
106
|
A15C30111CD25C330074CB35 /* ReactNativeBlobUtil.h */,
|
|
89
|
-
A15C30131CD25C330074CB35 /* ReactNativeBlobUtil.m */,
|
|
90
107
|
A15C300F1CD25C330074CB35 /* Products */,
|
|
91
108
|
8BD9ABDFAF76406291A798F2 /* Libraries */,
|
|
109
|
+
BE4E5761992F01F75082D147 /* Pods */,
|
|
110
|
+
193768812AF9A9C46358234E /* Frameworks */,
|
|
92
111
|
);
|
|
93
112
|
sourceTree = "<group>";
|
|
94
113
|
};
|
|
@@ -100,6 +119,15 @@
|
|
|
100
119
|
name = Products;
|
|
101
120
|
sourceTree = "<group>";
|
|
102
121
|
};
|
|
122
|
+
BE4E5761992F01F75082D147 /* Pods */ = {
|
|
123
|
+
isa = PBXGroup;
|
|
124
|
+
children = (
|
|
125
|
+
E83F89B1EFF498D9833537A4 /* Pods-ReactNativeBlobUtil.debug.xcconfig */,
|
|
126
|
+
1BDA30C5220621C99F823CB9 /* Pods-ReactNativeBlobUtil.release.xcconfig */,
|
|
127
|
+
);
|
|
128
|
+
path = Pods;
|
|
129
|
+
sourceTree = "<group>";
|
|
130
|
+
};
|
|
103
131
|
/* End PBXGroup section */
|
|
104
132
|
|
|
105
133
|
/* Begin PBXNativeTarget section */
|
|
@@ -107,6 +135,7 @@
|
|
|
107
135
|
isa = PBXNativeTarget;
|
|
108
136
|
buildConfigurationList = A15C30171CD25C330074CB35 /* Build configuration list for PBXNativeTarget "ReactNativeBlobUtil" */;
|
|
109
137
|
buildPhases = (
|
|
138
|
+
D6BB6591D040E628F7A16E89 /* [CP] Check Pods Manifest.lock */,
|
|
110
139
|
A15C300A1CD25C330074CB35 /* Sources */,
|
|
111
140
|
A15C300B1CD25C330074CB35 /* Frameworks */,
|
|
112
141
|
A15C300C1CD25C330074CB35 /* CopyFiles */,
|
|
@@ -126,7 +155,7 @@
|
|
|
126
155
|
A15C30061CD25C330074CB35 /* Project object */ = {
|
|
127
156
|
isa = PBXProject;
|
|
128
157
|
attributes = {
|
|
129
|
-
LastUpgradeCheck =
|
|
158
|
+
LastUpgradeCheck = 1420;
|
|
130
159
|
ORGANIZATIONNAME = wkh237.github.io;
|
|
131
160
|
TargetAttributes = {
|
|
132
161
|
A15C300D1CD25C330074CB35 = {
|
|
@@ -136,10 +165,11 @@
|
|
|
136
165
|
};
|
|
137
166
|
buildConfigurationList = A15C30091CD25C330074CB35 /* Build configuration list for PBXProject "ReactNativeBlobUtil" */;
|
|
138
167
|
compatibilityVersion = "Xcode 3.2";
|
|
139
|
-
developmentRegion =
|
|
168
|
+
developmentRegion = en;
|
|
140
169
|
hasScannedForEncodings = 0;
|
|
141
170
|
knownRegions = (
|
|
142
171
|
en,
|
|
172
|
+
Base,
|
|
143
173
|
);
|
|
144
174
|
mainGroup = A15C30051CD25C330074CB35;
|
|
145
175
|
productRefGroup = A15C300F1CD25C330074CB35 /* Products */;
|
|
@@ -151,20 +181,45 @@
|
|
|
151
181
|
};
|
|
152
182
|
/* End PBXProject section */
|
|
153
183
|
|
|
184
|
+
/* Begin PBXShellScriptBuildPhase section */
|
|
185
|
+
D6BB6591D040E628F7A16E89 /* [CP] Check Pods Manifest.lock */ = {
|
|
186
|
+
isa = PBXShellScriptBuildPhase;
|
|
187
|
+
buildActionMask = 2147483647;
|
|
188
|
+
files = (
|
|
189
|
+
);
|
|
190
|
+
inputFileListPaths = (
|
|
191
|
+
);
|
|
192
|
+
inputPaths = (
|
|
193
|
+
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
|
|
194
|
+
"${PODS_ROOT}/Manifest.lock",
|
|
195
|
+
);
|
|
196
|
+
name = "[CP] Check Pods Manifest.lock";
|
|
197
|
+
outputFileListPaths = (
|
|
198
|
+
);
|
|
199
|
+
outputPaths = (
|
|
200
|
+
"$(DERIVED_FILE_DIR)/Pods-ReactNativeBlobUtil-checkManifestLockResult.txt",
|
|
201
|
+
);
|
|
202
|
+
runOnlyForDeploymentPostprocessing = 0;
|
|
203
|
+
shellPath = /bin/sh;
|
|
204
|
+
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
|
|
205
|
+
showEnvVarsInLog = 0;
|
|
206
|
+
};
|
|
207
|
+
/* End PBXShellScriptBuildPhase section */
|
|
208
|
+
|
|
154
209
|
/* Begin PBXSourcesBuildPhase section */
|
|
155
210
|
A15C300A1CD25C330074CB35 /* Sources */ = {
|
|
156
211
|
isa = PBXSourcesBuildPhase;
|
|
157
212
|
buildActionMask = 2147483647;
|
|
158
213
|
files = (
|
|
214
|
+
11A307F92A06E47700E56674 /* ReactNativeBlobUtilReqBuilder.mm in Sources */,
|
|
159
215
|
A166D1AA1CE0647A00273590 /* ReactNativeBlobUtil.h in Sources */,
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
A15C30141CD25C330074CB35 /* ReactNativeBlobUtil.m in Sources */,
|
|
216
|
+
11A307F82A06E47700E56674 /* ReactNativeBlobUtilNetwork.mm in Sources */,
|
|
217
|
+
11A307FB2A06E47700E56674 /* ReactNativeBlobUtilFileTransformer.mm in Sources */,
|
|
218
|
+
11A307FE2A06E47700E56674 /* ReactNativeBlobUtilRequest.mm in Sources */,
|
|
219
|
+
11A307FC2A06E47700E56674 /* ReactNativeBlobUtilConst.mm in Sources */,
|
|
220
|
+
11A307EE2A06E45800E56674 /* ReactNativeBlobUtil.mm in Sources */,
|
|
221
|
+
11A307FD2A06E47700E56674 /* ReactNativeBlobUtilProgress.mm in Sources */,
|
|
222
|
+
11A307FA2A06E47700E56674 /* ReactNativeBlobUtilFS.mm in Sources */,
|
|
168
223
|
);
|
|
169
224
|
runOnlyForDeploymentPostprocessing = 0;
|
|
170
225
|
};
|
|
@@ -175,18 +230,30 @@
|
|
|
175
230
|
isa = XCBuildConfiguration;
|
|
176
231
|
buildSettings = {
|
|
177
232
|
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
233
|
+
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
|
|
178
234
|
CLANG_ANALYZER_NONNULL = YES;
|
|
179
235
|
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
|
180
236
|
CLANG_CXX_LIBRARY = "libc++";
|
|
181
237
|
CLANG_ENABLE_MODULES = YES;
|
|
182
238
|
CLANG_ENABLE_OBJC_ARC = YES;
|
|
239
|
+
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
|
183
240
|
CLANG_WARN_BOOL_CONVERSION = YES;
|
|
241
|
+
CLANG_WARN_COMMA = YES;
|
|
184
242
|
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
|
243
|
+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
|
185
244
|
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
|
186
245
|
CLANG_WARN_EMPTY_BODY = YES;
|
|
187
246
|
CLANG_WARN_ENUM_CONVERSION = YES;
|
|
247
|
+
CLANG_WARN_INFINITE_RECURSION = YES;
|
|
188
248
|
CLANG_WARN_INT_CONVERSION = YES;
|
|
249
|
+
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
|
250
|
+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
|
251
|
+
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
|
189
252
|
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
|
253
|
+
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
|
254
|
+
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
|
255
|
+
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
|
256
|
+
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
|
190
257
|
CLANG_WARN_UNREACHABLE_CODE = YES;
|
|
191
258
|
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
|
192
259
|
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
|
@@ -208,7 +275,7 @@
|
|
|
208
275
|
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
|
209
276
|
GCC_WARN_UNUSED_FUNCTION = YES;
|
|
210
277
|
GCC_WARN_UNUSED_VARIABLE = YES;
|
|
211
|
-
IPHONEOS_DEPLOYMENT_TARGET =
|
|
278
|
+
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
|
|
212
279
|
MTL_ENABLE_DEBUG_INFO = YES;
|
|
213
280
|
ONLY_ACTIVE_ARCH = YES;
|
|
214
281
|
SDKROOT = iphoneos;
|
|
@@ -219,18 +286,30 @@
|
|
|
219
286
|
isa = XCBuildConfiguration;
|
|
220
287
|
buildSettings = {
|
|
221
288
|
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
289
|
+
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
|
|
222
290
|
CLANG_ANALYZER_NONNULL = YES;
|
|
223
291
|
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
|
224
292
|
CLANG_CXX_LIBRARY = "libc++";
|
|
225
293
|
CLANG_ENABLE_MODULES = YES;
|
|
226
294
|
CLANG_ENABLE_OBJC_ARC = YES;
|
|
295
|
+
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
|
227
296
|
CLANG_WARN_BOOL_CONVERSION = YES;
|
|
297
|
+
CLANG_WARN_COMMA = YES;
|
|
228
298
|
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
|
299
|
+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
|
229
300
|
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
|
230
301
|
CLANG_WARN_EMPTY_BODY = YES;
|
|
231
302
|
CLANG_WARN_ENUM_CONVERSION = YES;
|
|
303
|
+
CLANG_WARN_INFINITE_RECURSION = YES;
|
|
232
304
|
CLANG_WARN_INT_CONVERSION = YES;
|
|
305
|
+
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
|
306
|
+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
|
307
|
+
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
|
233
308
|
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
|
309
|
+
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
|
310
|
+
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
|
311
|
+
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
|
312
|
+
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
|
234
313
|
CLANG_WARN_UNREACHABLE_CODE = YES;
|
|
235
314
|
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
|
236
315
|
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
|
@@ -246,7 +325,7 @@
|
|
|
246
325
|
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
|
247
326
|
GCC_WARN_UNUSED_FUNCTION = YES;
|
|
248
327
|
GCC_WARN_UNUSED_VARIABLE = YES;
|
|
249
|
-
IPHONEOS_DEPLOYMENT_TARGET =
|
|
328
|
+
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
|
|
250
329
|
MTL_ENABLE_DEBUG_INFO = NO;
|
|
251
330
|
SDKROOT = iphoneos;
|
|
252
331
|
VALIDATE_PRODUCT = YES;
|
|
@@ -255,6 +334,7 @@
|
|
|
255
334
|
};
|
|
256
335
|
A15C30181CD25C330074CB35 /* Debug */ = {
|
|
257
336
|
isa = XCBuildConfiguration;
|
|
337
|
+
baseConfigurationReference = E83F89B1EFF498D9833537A4 /* Pods-ReactNativeBlobUtil.debug.xcconfig */;
|
|
258
338
|
buildSettings = {
|
|
259
339
|
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
260
340
|
GCC_INPUT_FILETYPE = automatic;
|
|
@@ -276,6 +356,7 @@
|
|
|
276
356
|
};
|
|
277
357
|
A15C30191CD25C330074CB35 /* Release */ = {
|
|
278
358
|
isa = XCBuildConfiguration;
|
|
359
|
+
baseConfigurationReference = 1BDA30C5220621C99F823CB9 /* Pods-ReactNativeBlobUtil.release.xcconfig */;
|
|
279
360
|
buildSettings = {
|
|
280
361
|
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
281
362
|
GCC_INPUT_FILETYPE = automatic;
|
|
@@ -22,6 +22,7 @@ extern NSString *const EVENT_PROGRESS;
|
|
|
22
22
|
extern NSString *const EVENT_SERVER_PUSH;
|
|
23
23
|
extern NSString *const EVENT_PROGRESS_UPLOAD;
|
|
24
24
|
extern NSString *const EVENT_STATE_CHANGE;
|
|
25
|
+
extern NSString *const EVENT_FILESYSTEM;
|
|
25
26
|
|
|
26
27
|
extern NSString *const FILE_PREFIX;
|
|
27
28
|
extern NSString *const ASSET_PREFIX;
|
|
@@ -27,6 +27,7 @@ NSString *const EVENT_SERVER_PUSH = @"ReactNativeBlobUtilServerPush";
|
|
|
27
27
|
NSString *const EVENT_PROGRESS = @"ReactNativeBlobUtilProgress";
|
|
28
28
|
NSString *const EVENT_PROGRESS_UPLOAD = @"ReactNativeBlobUtilProgress-upload";
|
|
29
29
|
NSString *const EVENT_EXPIRE = @"ReactNativeBlobUtilExpire";
|
|
30
|
+
NSString *const EVENT_FILESYSTEM = @"ReactNativeBlobUtilFilesystem";
|
|
30
31
|
|
|
31
32
|
NSString *const MSG_EVENT = @"ReactNativeBlobUtilMessage";
|
|
32
33
|
NSString *const MSG_EVENT_LOG = @"log";
|
|
@@ -24,7 +24,6 @@
|
|
|
24
24
|
NSOutputStream * outStream;
|
|
25
25
|
NSInputStream * inStream;
|
|
26
26
|
RCTResponseSenderBlock callback;
|
|
27
|
-
RCTEventDispatcher * eventDispatcher;
|
|
28
27
|
Boolean isOpen;
|
|
29
28
|
NSString * encoding;
|
|
30
29
|
int bufferSize;
|
|
@@ -37,7 +36,6 @@
|
|
|
37
36
|
@property (nonatomic) NSOutputStream * _Nullable outStream;
|
|
38
37
|
@property (nonatomic) NSInputStream * _Nullable inStream;
|
|
39
38
|
@property (strong, nonatomic) RCTResponseSenderBlock callback;
|
|
40
|
-
@property (nonatomic) RCTEventDispatcher * eventDispatcher;
|
|
41
39
|
@property (nonatomic) NSString * encoding;
|
|
42
40
|
@property (nonatomic) NSString * taskId;
|
|
43
41
|
@property (nonatomic) NSString * path;
|
|
@@ -85,13 +83,12 @@
|
|
|
85
83
|
rejecter:(RCTPromiseRejectBlock)reject;
|
|
86
84
|
//+ (void) writeFileFromFile:(NSString *)src toFile:(NSString *)dest append:(BOOL)append;
|
|
87
85
|
+ (void) writeAssetToPath:(ALAssetRepresentation * )rep dest:(NSString *)dest;
|
|
88
|
-
+ (void) readStream:(NSString *)uri encoding:(NSString * )encoding bufferSize:(int)bufferSize tick:(int)tick streamId:(NSString *)streamId
|
|
86
|
+
+ (void) readStream:(NSString *)uri encoding:(NSString * )encoding bufferSize:(int)bufferSize tick:(int)tick streamId:(NSString *)streamId baseModule:(ReactNativeBlobUtil *)baseModule;
|
|
89
87
|
+ (void) df:(RCTResponseSenderBlock)callback;
|
|
90
88
|
|
|
91
89
|
// constructor
|
|
92
90
|
- (id) init;
|
|
93
91
|
- (id)initWithCallback:(RCTResponseSenderBlock)callback;
|
|
94
|
-
- (id)initWithEventDispatcherRef:(RCTEventDispatcher *)eventDispatcherRef;
|
|
95
92
|
|
|
96
93
|
// file stream
|
|
97
94
|
- (void) openWithDestination;
|