Skip to content
This repository was archived by the owner on Jun 3, 2021. It is now read-only.

Commit 648e0f5

Browse files
committed
optional调整
1 parent 4912fd1 commit 648e0f5

File tree

10 files changed

+21
-21
lines changed

10 files changed

+21
-21
lines changed

ios/sdk/WeexSDK/Sources/Eagle/WXDataRenderHandler.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,23 +23,23 @@ NS_ASSUME_NONNULL_BEGIN
2323

2424
@protocol WXDataRenderHandler <NSObject>
2525

26-
- (void)createPage:(NSString *)pageId template:(NSString *)jsBundleString options:(NSDictionary *)options data:(id)data;
26+
- (void)createPage:(NSString *)pageId template:(NSString *)jsBundleString options:(NSDictionary * _Nullable)options data:(id)data;
2727

28-
- (void)createPage:(NSString *)pageId contents:(NSData *)contents options:(NSDictionary *)options data:(id)data;
28+
- (void)createPage:(NSString *)pageId contents:(NSData *)contents options:(NSDictionary * _Nullable)options data:(id)data;
2929

3030
- (void)callUpdateComponentData:(NSString*)pageId componentId:(NSString*)componentId jsonData:(NSString*)jsonData;
3131

3232
- (void)destroyDataRenderInstance:(NSString *)pageId;
3333

3434
- (void)refreshDataRenderInstance:(NSString *)pageId data:(NSString *)data;
3535

36-
- (void)fireEvent:(NSString *)pageId ref:(NSString *)ref event:(NSString *)event args:(NSDictionary *)args domChanges:(NSDictionary * _Nullable)domChanges;
36+
- (void)fireEvent:(NSString *)pageId ref:(NSString *)ref event:(NSString *)event args:(NSDictionary * _Nullable)args domChanges:(NSDictionary * _Nullable)domChanges;
3737

3838
- (void)registerModules:(NSDictionary *)modules;
3939

4040
- (void)registerComponents:(NSArray *)components;
4141

42-
- (void)invokeCallBack:(NSString *)pageId function:(NSString *)funcId args:(NSDictionary *)args keepAlive:(BOOL)keepAlive;
42+
- (void)invokeCallBack:(NSString *)pageId function:(NSString *)funcId args:(NSDictionary * _Nullable)args keepAlive:(BOOL)keepAlive;
4343

4444
- (void)DispatchPageLifecycle:(NSString *)pageId;
4545

ios/sdk/WeexSDK/Sources/Engine/WXSDKEngine.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN
9696
* @param completion Completion callback. JS is executed in asynchronously.
9797
*
9898
*/
99-
+ (void)registerService:(NSString *)name withScript:(NSString *)serviceScript withOptions:(NSDictionary * _Nullable)options completion:(void(^)(BOOL result))completion;
99+
+ (void)registerService:(NSString *)name withScript:(NSString *)serviceScript withOptions:(NSDictionary * _Nullable)options completion:(nullable void(^)(BOOL result))completion;
100100

101101
/**
102102
* @abstract Registers a component for a given name, options and js url
@@ -122,7 +122,7 @@ NS_ASSUME_NONNULL_BEGIN
122122
* @param completion Completion callback. JS is executed in asynchronously.
123123
*
124124
*/
125-
+ (void)registerService:(NSString *)name withScriptUrl:(NSURL *)serviceScriptUrl withOptions:(NSDictionary * _Nullable)options completion:(void(^)(BOOL result))completion;
125+
+ (void)registerService:(NSString *)name withScriptUrl:(NSURL *)serviceScriptUrl withOptions:(NSDictionary * _Nullable)options completion:(nullable void (^)(BOOL result))completion;
126126

127127
/**
128128
* @abstract Registers a component for a given name, options and js code

ios/sdk/WeexSDK/Sources/Manager/WXBridgeManager.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ extern "C" {
102102
* @param instance : instance id
103103
* @param data : external data
104104
**/
105-
- (void)refreshInstance:(NSString *)instance data:(id)data;
105+
- (void)refreshInstance:(NSString *)instance data:(id _Nullable)data;
106106

107107
/**
108108
* Unload
@@ -114,7 +114,7 @@ extern "C" {
114114
* @param instance : instance id
115115
* @param data : parameters
116116
**/
117-
- (void)updateState:(NSString *)instance data:(id)data;
117+
- (void)updateState:(NSString *)instance data:(id _Nullable)data;
118118

119119
/**
120120
* Execute JSFramework Script

ios/sdk/WeexSDK/Sources/Manager/WXComponentFactory.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN
2424

2525
@interface WXComponentConfig : WXInvocationConfig
2626

27-
@property (nonatomic, strong) NSDictionary *properties;
27+
@property (nonatomic, strong) NSDictionary * _Nullable properties;
2828

2929
- (instancetype)initWithName:(NSString *)name class:(NSString *)clazz pros:(NSDictionary * _Nullable)pros;
3030

ios/sdk/WeexSDK/Sources/Model/WXComponent.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ NS_ASSUME_NONNULL_BEGIN
182182
*
183183
* @return A block that takes component, callbackType and a result.
184184
**/
185-
@property (nonatomic, copy) void (^componentCallback)(WXComponent *component, WXComponentCallbackType callbackType, id result);
185+
@property (nonatomic, copy) void (^componentCallback)(WXComponent *component, WXComponentCallbackType callbackType, id _Nullable result);
186186

187187
/**
188188
* @abstract Called on main thread when the component has just laid out.

ios/sdk/WeexSDK/Sources/Protocol/WXValidateProtocol.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ NS_ASSUME_NONNULL_BEGIN
2424

2525
@interface WXValidateResult : NSObject
2626

27-
@property(nonatomic,assign)BOOL isSuccess;
28-
@property(nonatomic,strong)NSError* error;
27+
@property(nonatomic,assign) BOOL isSuccess;
28+
@property(nonatomic,strong) NSError* _Nullable error;
2929

3030
@end
3131

@@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN
4646

4747
-(WXModuleValidateResult *)validateWithWXSDKInstance:(WXSDKInstance *)wxsdkInstance module:(NSString*) moduel method:(NSString *)method args:(nullable NSArray *)args options:(nullable NSDictionary *)options;
4848

49-
-(WXComponentValidateResult *)validateWithWXSDKInstance:(WXSDKInstance *)wxsdkInstance component:(NSString *)componentName supercomponent:(WXComponent *)supercomponent;
49+
-(WXComponentValidateResult *)validateWithWXSDKInstance:(WXSDKInstance *)wxsdkInstance component:(NSString *)componentName supercomponent:(nullable WXComponent *)supercomponent;
5050

5151
@end
5252

ios/sdk/WeexSDK/Sources/Utility/WXVersion.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020
#import "WXVersion.h"
2121
#import "WXDefine.h"
2222

23-
static const char* WeexSDKBuildTime = "2019-08-26 07:44:34 UTC";
24-
static const unsigned long WeexSDKBuildTimestamp = 1566805474;
23+
static const char* WeexSDKBuildTime = "2019-08-26 08:28:24 UTC";
24+
static const unsigned long WeexSDKBuildTimestamp = 1566808104;
2525

2626
NSString* GetWeexSDKVersion(void)
2727
{

ios/sdk/WeexSDK/Sources/WebSocket/WXWebSocketHandler.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,15 @@ NS_ASSUME_NONNULL_BEGIN
2626
- (void)didOpen;
2727
- (void)didFailWithError:(NSError *)error;
2828
- (void)didReceiveMessage:(id)message;
29-
- (void)didCloseWithCode:(NSInteger)code reason:(NSString *)reason wasClean:(BOOL)wasClean;
29+
- (void)didCloseWithCode:(NSInteger)code reason:(nullable NSString *)reason wasClean:(BOOL)wasClean;
3030
@end
3131

3232
@protocol WXWebSocketHandler<NSObject>
3333

34-
- (void)open:(NSString *)url protocol:(NSString *)protocol identifier:(NSString *)identifier withDelegate:(id<WXWebSocketDelegate>)delegate;
34+
- (void)open:(NSString *)url protocol:(NSString *)protocol identifier:(nullable NSString *)identifier withDelegate:(id<WXWebSocketDelegate>)delegate;
3535
- (void)send:(NSString *)identifier data:(NSString *)data;
3636
- (void)close:(NSString *)identifier;
37-
- (void)close:(NSString *)identifier code:(NSInteger)code reason:(NSString *)reason;
37+
- (void)close:(NSString *)identifier code:(NSInteger)code reason:(nullable NSString *)reason;
3838
- (void)clear:(NSString *)identifier;
3939
@end
4040

weex_core/Source/core/layout/layout.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727
#include <iostream>
2828
#include <string>
2929
#include <algorithm>
30-
#include "style.h"
31-
#include "flex_enum.h"
30+
#include <WeexSDK/style.h>
31+
#include <WeexSDK/flex_enum.h>
3232

3333
namespace WeexCore {
3434

weex_core/Source/core/layout/style.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
#define WEEXCORE_FLEXLAYOUT_WXCOREFLEXENUMS_H
2323

2424

25-
#include "flex_enum.h"
25+
#include <WeexSDK/flex_enum.h>
2626
#include <math.h>
2727
#include <cmath>
2828

0 commit comments

Comments
 (0)