react-native-gizwits-sdk-v5 1.3.1 → 1.3.3

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.
Files changed (61) hide show
  1. package/android/build.gradle +5 -1
  2. package/android/src/main/java/com/gizwits/reactnativegizwitssdkv5/RNGizSDKManagerModule.kt +18 -1
  3. package/android/src/main/java/com/gizwits/reactnativegizwitssdkv5/RNGizUserManagerModule.kt +5 -6
  4. package/package.json +1 -1
  5. package/react-native-gizwits-sdk-v5.podspec +3 -1
  6. package/android/libs/sdk-bluetooth-debug.aar +0 -0
  7. package/android/libs/sdk-bluetooth-release.aar +0 -0
  8. package/android/libs/sdk-debug.aar +0 -0
  9. package/android/libs/sdk-lan-debug.aar +0 -0
  10. package/android/libs/sdk-lan-release.aar +0 -0
  11. package/android/libs/sdk-mqtt-debug.aar +0 -0
  12. package/android/libs/sdk-mqtt-release.aar +0 -0
  13. package/android/libs/sdk-release.aar +0 -0
  14. package/ios/GizwitsiOSSDK.framework/GizwitsiOSSDK +0 -0
  15. package/ios/GizwitsiOSSDK.framework/Headers/CocoaAsyncSocket.h +0 -18
  16. package/ios/GizwitsiOSSDK.framework/Headers/DDASLLogger.h +0 -41
  17. package/ios/GizwitsiOSSDK.framework/Headers/DDAbstractDatabaseLogger.h +0 -102
  18. package/ios/GizwitsiOSSDK.framework/Headers/DDContextFilterLogFormatter.h +0 -63
  19. package/ios/GizwitsiOSSDK.framework/Headers/DDDispatchQueueLogFormatter.h +0 -128
  20. package/ios/GizwitsiOSSDK.framework/Headers/DDFileLogger.h +0 -340
  21. package/ios/GizwitsiOSSDK.framework/Headers/DDLog+LOGV.h +0 -99
  22. package/ios/GizwitsiOSSDK.framework/Headers/DDLog.h +0 -632
  23. package/ios/GizwitsiOSSDK.framework/Headers/DDMultiFormatter.h +0 -30
  24. package/ios/GizwitsiOSSDK.framework/Headers/DDTTYLogger.h +0 -171
  25. package/ios/GizwitsiOSSDK.framework/Headers/ForegroundReconnection.h +0 -23
  26. package/ios/GizwitsiOSSDK.framework/Headers/GCDTimer.h +0 -19
  27. package/ios/GizwitsiOSSDK.framework/Headers/GizwitsiOSSDK-Swift.h +0 -313
  28. package/ios/GizwitsiOSSDK.framework/Headers/GizwitsiOSSDK.h +0 -21
  29. package/ios/GizwitsiOSSDK.framework/Headers/MQTTClient.h +0 -39
  30. package/ios/GizwitsiOSSDK.framework/Headers/MQTTInMemoryPersistence.h +0 -16
  31. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSSLSecurityPolicyDecoder.h +0 -19
  32. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSSLSecurityPolicyEncoder.h +0 -18
  33. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSessionLegacy.h +0 -112
  34. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSessionSynchron.h +0 -194
  35. package/ios/GizwitsiOSSDK.framework/Headers/MQTTStrict.h +0 -33
  36. package/ios/GizwitsiOSSDK.framework/Headers/MQTTUntil.h +0 -14
  37. package/ios/GizwitsiOSSDK.framework/Headers/ReconnectTimer.h +0 -21
  38. package/ios/GizwitsiOSSDK.framework/Headers/_GCDAsyncSocket.h +0 -1226
  39. package/ios/GizwitsiOSSDK.framework/Headers/_GCDAsyncUdpSocket.h +0 -1036
  40. package/ios/GizwitsiOSSDK.framework/Headers/_GizwitsParser.h +0 -61
  41. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCFSocketDecoder.h +0 -39
  42. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCFSocketEncoder.h +0 -38
  43. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCFSocketTransport.h +0 -79
  44. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCoreDataPersistence.h +0 -21
  45. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTDecoder.h +0 -66
  46. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTLog.h +0 -123
  47. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTMessage.h +0 -233
  48. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTPersistence.h +0 -124
  49. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTProperties.h +0 -76
  50. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSSLSecurityPolicy.h +0 -158
  51. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSSLSecurityPolicyTransport.h +0 -30
  52. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSession.h +0 -886
  53. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSessionManager.h +0 -237
  54. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTTransport.h +0 -114
  55. package/ios/GizwitsiOSSDK.framework/Headers/common.h +0 -104
  56. package/ios/GizwitsiOSSDK.framework/Info.plist +0 -0
  57. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
  58. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.abi.json +0 -9
  59. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
  60. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.swiftmodule +0 -0
  61. package/ios/GizwitsiOSSDK.framework/Modules/module.modulemap +0 -11
@@ -1,112 +0,0 @@
1
- //
2
- // MQTTSessionLegacy.h
3
- // MQTTClient.framework
4
- //
5
-
6
- /**
7
- Using MQTT in your Objective-C application
8
- This file contains definitions for mqttio-OBJC backward compatibility
9
-
10
- @author Christoph Krey c@ckrey.de
11
- @copyright Copyright © 2013-2017, Christoph Krey. All rights reserved.
12
-
13
- based on Copyright (c) 2011, 2013, 2lemetry LLC
14
- All rights reserved. This program and the accompanying materials
15
- are made available under the terms of the Eclipse Public License v1.0
16
- which accompanies this distribution, and is available at
17
- http://www.eclipse.org/legal/epl-v10.html
18
-
19
- @see http://mqtt.org
20
- */
21
-
22
-
23
- #import <Foundation/Foundation.h>
24
- #import "_MQTTSession.h"
25
-
26
- @interface _MQTTSession(Create)
27
-
28
- /** initialises the MQTT session
29
- *
30
- * this constructor can specifies SSL securityPolicy. the default value of securityPolicy is nil(which do nothing).
31
- *
32
- * if SSL is enabled, by default it only evaluate server's certificates using CA infrastructure, and for most case, this type of check is enough.
33
- * However, if your app using security model which require pinning SSL certificates to helps prevent man-in-the-middle attacks
34
- * and other vulnerabilities. you may need to set securityPolicy to properly value(see MQTTSSLSecurityPolicy.h for more detail).
35
- *
36
- * NOTE: about self-signed server certificates:
37
- * In CA infrastructure, you may establish a SSL/TLS connection with server which using self-signed certificates
38
- * by install the certificates into OS keychain(either programmatically or manually). however, this method has some disadvantages:
39
- * 1. every socket you app created will trust certificates you added.
40
- * 2. if user choice to remove certificates from keychain, you app need to handling certificates re-adding.
41
- *
42
- * If you only want to verify the cert for the socket you are creating and for no other sockets in your app, you need to use
43
- * MQTTSSLSecurityPolicy.
44
- * And if you use self-signed server certificates, your need to set property: MQTTSSLSecurityPolicy.allowInvalidCertificates=YES
45
- * (see MQTTSSLSecurityPolicy.h for more detail).
46
- *
47
- * @param clientId The Client Identifier identifies the Client to the Server. If nil, a random clientId is generated.
48
- * @param userName an NSString object containing the user's name (or ID) for authentication. May be nil.
49
- * @param password an NSString object containing the user's password. If userName is nil, password must be nil as well.
50
- * @param keepAliveInterval The Keep Alive is a time interval measured in seconds. The MQTTClient ensures that the interval between Control Packets being sent does not exceed the Keep Alive value. In the absence of sending any other Control Packets, the Client sends a PINGREQ Packet.
51
- * @param cleanSessionFlag specifies if the server should discard previous session information.
52
- * @param willFlag If the Will Flag is set to YES this indicates that a Will Message MUST be published by the Server when the Server detects that the Client is disconnected for any reason other than the Client flowing a DISCONNECT Packet.
53
- * @param willTopic If the Will Flag is set to YES, the Will Topic is a string, nil otherwise.
54
- * @param willMsg If the Will Flag is set to YES the Will Message must be specified, nil otherwise.
55
- * @param willQoS specifies the QoS level to be used when publishing the Will Message. If the Will Flag is set to NO, then the Will QoS MUST be set to 0. If the Will Flag is set to YES, the value of Will QoS can be 0 (0x00), 1 (0x01), or 2 (0x02).
56
- * @param willRetainFlag indicates if the server should publish the Will Messages with retainFlag. If the Will Flag is set to NO, then the Will Retain Flag MUST be set to NO . If the Will Flag is set to YES: If Will Retain is set to NO, the Server MUST publish the Will Message as a non-retained publication [MQTT-3.1.2-14]. If Will Retain is set to YES, the Server MUST publish the Will Message as a retained publication [MQTT-3.1.2-15].
57
- * @param protocolLevel specifies the protocol to be used. The value of the Protocol Level field for the version 3.1.1 of the protocol is 4. The value for the version 3.1 is 3.
58
- * @param queue The queue where the streams are scheduled.
59
- * @param securityPolicy The security policy used to evaluate server trust for secure connections.
60
- * @param certificates An identity certificate used to reply to a server requiring client certificates according to the description given for SSLSetCertificate(). You may build the certificates array yourself or use the sundry method clientCertFromP12
61
- * @return the initialised MQTTSession object
62
- *
63
- * @code
64
- #import "MQTTClient.h"
65
-
66
- NSString* certificate = [[NSBundle bundleForClass:[MQTTSession class]] pathForResource:@"certificate" ofType:@"cer"];
67
- MQTTSSLSecurityPolicy *securityPolicy = [MQTTSSLSecurityPolicy policyWithPinningMode:MQTTSSLPinningModeCertificate];
68
- securityPolicy.pinnedCertificates = @[ [NSData dataWithContentsOfFile:certificate] ];
69
- securityPolicy.allowInvalidCertificates = YES; // if your certificate is self-signed(which didn't coupled with CA infrastructure)
70
-
71
- MQTTSession *session = [[MQTTSession alloc]
72
- initWithClientId:@"example-1234"
73
- userName:@"user"
74
- password:@"secret"
75
- keepAlive:60
76
- cleanSession:YES
77
- will:YES
78
- willTopic:@"example/status"
79
- willMsg:[[@"Client off-line"] dataUsingEncoding:NSUTF8StringEncoding]
80
- willQoS:2
81
- willRetainFlag:YES
82
- protocolLevel:4
83
- queue:dispatch_queue_get_main_queue()
84
- securityPolicy:securityPolicy
85
- certificates:certificates];
86
-
87
- [session connectToHost:@"example-1234" port:1883 usingSSL:YES];
88
- @endcode
89
- */
90
- - (_MQTTSession *)initWithClientId:(NSString *)clientId
91
- userName:(NSString *)userName
92
- password:(NSString *)password
93
- keepAlive:(UInt16)keepAliveInterval
94
- connectMessage:(_MQTTMessage *)theConnectMessage
95
- cleanSession:(BOOL)cleanSessionFlag
96
- will:(BOOL)willFlag
97
- willTopic:(NSString *)willTopic
98
- willMsg:(NSData *)willMsg
99
- willQoS:(_MQTTQosLevel)willQoS
100
- willRetainFlag:(BOOL)willRetainFlag
101
- protocolLevel:(UInt8)protocolLevel
102
- queue:(dispatch_queue_t)queue
103
- securityPolicy:(_MQTTSSLSecurityPolicy *) securityPolicy
104
- certificates:(NSArray *)certificates;
105
-
106
- /** for mqttio-OBJC backward compatibility
107
- @param payload JSON payload is converted to NSData and then send. See publishData for description
108
- @param theTopic see publishData for description
109
- */
110
- - (void)publishJson:(id)payload onTopic:(NSString *)theTopic;
111
-
112
- @end
@@ -1,194 +0,0 @@
1
- //
2
- // MQTTSessionSynchron.h
3
- // MQTTClient.framework
4
- //
5
-
6
- /**
7
- Synchronous API
8
-
9
- @author Christoph Krey c@ckrey.de
10
- @copyright Copyright © 2013-2017, Christoph Krey. All rights reserved.
11
-
12
- */
13
-
14
-
15
- #import <Foundation/Foundation.h>
16
- #import "_MQTTSession.h"
17
-
18
- @interface _MQTTSession(Synchron)
19
-
20
- /** connects to the specified MQTT server synchronously
21
-
22
- @param timeout defines the maximum time to wait. Defaults to 0 for no timeout.
23
-
24
- @return true if the connection was established
25
-
26
- @code
27
- #import "MQTTClient.h"
28
-
29
- MQTTSession *session = [[MQTTSession alloc] init];
30
-
31
- [session connectAndWaitTimeout:30];
32
- @endcode
33
-
34
- */
35
- - (BOOL)connectAndWaitTimeout:(NSTimeInterval)timeout;
36
-
37
- /** subscribes to a topic at a specific QoS level synchronously
38
-
39
- @param topic the Topic Filter to subscribe to.
40
-
41
- @param qosLevel specifies the QoS Level of the subscription.
42
- qosLevel can be 0, 1, or 2.
43
- @param timeout defines the maximum time to wait
44
-
45
- @return TRUE if successfully subscribed
46
-
47
- @code
48
- #import "MQTTClient.h"
49
-
50
- MQTTSession *session = [[MQTTSession alloc] init];
51
-
52
- [session connectAndWaitTimeout:30];
53
-
54
- [session subscribeAndWaitToTopic:@"example/#" atLevel:2 timeout:10];
55
-
56
- @endcode
57
-
58
- */
59
- - (BOOL)subscribeAndWaitToTopic:(NSString *)topic
60
- atLevel:(_MQTTQosLevel)qosLevel
61
- timeout:(NSTimeInterval)timeout;
62
-
63
- /** subscribes a number of topics
64
-
65
- @param topics an NSDictionary<NSString *, NSNumber *> containing the Topic Filters to subscribe to as keys and
66
- the corresponding QoS as NSNumber values
67
- @param timeout defines the maximum time to wait
68
-
69
- @return TRUE if the subscribe was succesfull
70
-
71
- @code
72
- #import "MQTTClient.h"
73
-
74
- MQTTSession *session = [[MQTTSession alloc] init];
75
-
76
- [session connectAndWaitTimeout:30];
77
-
78
- [session subscribeAndWaitToTopics:@{
79
- @"example/#": @(0),
80
- @"example/status": @(2),
81
- @"other/#": @(1)
82
- }
83
- timeout:10];
84
-
85
- @endcode
86
- */
87
- - (BOOL)subscribeAndWaitToTopics:(NSDictionary<NSString *, NSNumber *> *)topics
88
- timeout:(NSTimeInterval)timeout;
89
-
90
- /** unsubscribes from a topic synchronously
91
-
92
- @param topic the Topic Filter to unsubscribe from.
93
- @param timeout defines the maximum time to wait
94
-
95
- @return TRUE if sucessfully unsubscribed
96
-
97
- @code
98
- #import "MQTTClient.h"
99
-
100
- MQTTSession *session = [[MQTTSession alloc] init];
101
-
102
- [session connectAndWaitTimeout:30];
103
-
104
- ...
105
-
106
- [session unsubscribeAndWaitTopic:@"example/#" timeout:10];
107
-
108
- @endcode
109
- */
110
- - (BOOL)unsubscribeAndWaitTopic:(NSString *)topic
111
- timeout:(NSTimeInterval)timeout;
112
-
113
- /** unsubscribes from a number of topics synchronously
114
-
115
- @param topics an NSArray<NSString *> of topics to unsubscribe from
116
- @param timeout defines the maximum time to wait
117
-
118
- @return TRUE if the unsubscribe was successful
119
-
120
- @code
121
- #import "MQTTClient.h"
122
-
123
- MQTTSession *session = [[MQTTSession alloc] init];
124
-
125
- [session connectAndWaitTimeout:30];
126
-
127
- ...
128
-
129
- [session unsubscribeAndWaitTopics:@[
130
- @"example/#",
131
- @"example/status",
132
- @"other/#"
133
- ]
134
- timeout:10];
135
-
136
- @endcode
137
-
138
- */
139
- - (BOOL)unsubscribeAndWaitTopics:(NSArray<NSString *> *)topics
140
- timeout:(NSTimeInterval)timeout;
141
-
142
- /** publishes synchronously data on a given topic at a specified QoS level and retain flag
143
-
144
- @param data the data to be sent. length may range from 0 to 268,435,455 - 4 - _lengthof-topic_ bytes. Defaults to length 0.
145
- @param topic the Topic to identify the data
146
- @param retainFlag if YES, data is stored on the MQTT broker until overwritten by the next publish with retainFlag = YES
147
- @param qos specifies the Quality of Service for the publish
148
- qos can be 0, 1, or 2.
149
- @param timeout defines the maximum time to wait
150
- @returns TRUE if the publish was successful
151
-
152
- @code
153
- #import "MQTTClient.h"
154
-
155
- MQTTSession *session = [[MQTTSession alloc] init];
156
-
157
- [session connectAndWaitTimeout:30];
158
-
159
- [session publishAndWaitData:[@"Sample Data" dataUsingEncoding:NSUTF8StringEncoding]
160
- topic:@"example/data"
161
- retain:YES
162
- qos:1
163
- timeout:10];
164
- @endcode
165
-
166
- */
167
- - (BOOL)publishAndWaitData:(NSData *)data
168
- onTopic:(NSString *)topic
169
- retain:(BOOL)retainFlag
170
- qos:(_MQTTQosLevel)qos
171
- timeout:(NSTimeInterval)timeout;
172
-
173
- /** closes an MQTTSession gracefully synchronously
174
- @param timeout defines the maximum time to wait
175
-
176
- If the connection was successfully established before, a DISCONNECT is sent.
177
-
178
- @code
179
- #import "MQTTClient.h"
180
-
181
- MQTTSession *session = [[MQTTSession alloc] init];
182
-
183
- [session connectAndWaitTimeout:30];
184
-
185
- ...
186
-
187
- [session closeAndWait:10];
188
-
189
- @endcode
190
-
191
- */
192
- - (void)closeAndWait:(NSTimeInterval)timeout;
193
-
194
- @end
@@ -1,33 +0,0 @@
1
- //
2
- // MQTTStrict.h
3
- // MQTTClient
4
- //
5
- // Created by Christoph Krey on 24.07.17.
6
- // Copyright © 2017 Christoph Krey. All rights reserved.
7
- //
8
-
9
- #import <Foundation/Foundation.h>
10
-
11
- /** MQTTStrict controls the behaviour of MQTTClient with regards to parameter checking
12
- * If strict is true, all parameters passed by the caller are checked before
13
- * the corresponding message is send (CONNECT, PUBLISH, SUBSCRIBE, UNSUBSCRIBE)
14
- * and an exception is thrown if any invalid values or inconsistencies are detected
15
- *
16
- * If strict is false, parameters are used as passed by the caller.
17
- * Messages will be sent "incorrectly" and
18
- * parameter checking will be done on the broker end.
19
- *
20
- */
21
- @interface MQTTStrict : NSObject
22
-
23
- /** strict returns the current strict flag
24
- * @return the strict flag
25
- */
26
- + (BOOL)strict;
27
-
28
- /** setString sets the global strict flag
29
- * @param strict the new strict flag
30
- */
31
- + (void)setStrict:(BOOL)strict;
32
-
33
- @end
@@ -1,14 +0,0 @@
1
- //
2
- // MQTTUntil.h
3
- // GizSDKV5
4
- //
5
- // Created by william Zhang on 2022/4/19.
6
- //
7
-
8
- #ifndef MQTTUntil_h
9
- #define MQTTUntil_h
10
-
11
-
12
-
13
-
14
- #endif /* MQTTUntil_h */
@@ -1,21 +0,0 @@
1
- //
2
- // ReconnectTimer.h
3
- // MQTTClient
4
- //
5
- // Created by Josip Cavar on 22/08/2017.
6
- // Copyright © 2017 Christoph Krey. All rights reserved.
7
- //
8
-
9
- #import <Foundation/Foundation.h>
10
-
11
- @interface ReconnectTimer : NSObject
12
-
13
- - (instancetype)initWithRetryInterval:(NSTimeInterval)retryInterval
14
- maxRetryInterval:(NSTimeInterval)maxRetryInterval
15
- queue:(dispatch_queue_t)queue
16
- reconnectBlock:(void (^)(void))block;
17
- - (void)schedule;
18
- - (void)stop;
19
- - (void)resetRetryInterval;
20
-
21
- @end