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

Commit

Permalink
optional调整
Browse files Browse the repository at this point in the history
  • Loading branch information
Txink committed Aug 26, 2019
1 parent 4912fd1 commit 648e0f5
Show file tree
Hide file tree
Showing 10 changed files with 21 additions and 21 deletions.
8 changes: 4 additions & 4 deletions ios/sdk/WeexSDK/Sources/Eagle/WXDataRenderHandler.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,23 @@ NS_ASSUME_NONNULL_BEGIN

@protocol WXDataRenderHandler <NSObject>

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

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

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

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

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

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

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

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

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

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

Expand Down
4 changes: 2 additions & 2 deletions ios/sdk/WeexSDK/Sources/Engine/WXSDKEngine.h
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN
* @param completion Completion callback. JS is executed in asynchronously.
*
*/
+ (void)registerService:(NSString *)name withScript:(NSString *)serviceScript withOptions:(NSDictionary * _Nullable)options completion:(void(^)(BOOL result))completion;
+ (void)registerService:(NSString *)name withScript:(NSString *)serviceScript withOptions:(NSDictionary * _Nullable)options completion:(nullable void(^)(BOOL result))completion;

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

/**
* @abstract Registers a component for a given name, options and js code
Expand Down
4 changes: 2 additions & 2 deletions ios/sdk/WeexSDK/Sources/Manager/WXBridgeManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ extern "C" {
* @param instance : instance id
* @param data : external data
**/
- (void)refreshInstance:(NSString *)instance data:(id)data;
- (void)refreshInstance:(NSString *)instance data:(id _Nullable)data;

/**
* Unload
Expand All @@ -114,7 +114,7 @@ extern "C" {
* @param instance : instance id
* @param data : parameters
**/
- (void)updateState:(NSString *)instance data:(id)data;
- (void)updateState:(NSString *)instance data:(id _Nullable)data;

/**
* Execute JSFramework Script
Expand Down
2 changes: 1 addition & 1 deletion ios/sdk/WeexSDK/Sources/Manager/WXComponentFactory.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN

@interface WXComponentConfig : WXInvocationConfig

@property (nonatomic, strong) NSDictionary *properties;
@property (nonatomic, strong) NSDictionary * _Nullable properties;

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

Expand Down
2 changes: 1 addition & 1 deletion ios/sdk/WeexSDK/Sources/Model/WXComponent.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ NS_ASSUME_NONNULL_BEGIN
*
* @return A block that takes component, callbackType and a result.
**/
@property (nonatomic, copy) void (^componentCallback)(WXComponent *component, WXComponentCallbackType callbackType, id result);
@property (nonatomic, copy) void (^componentCallback)(WXComponent *component, WXComponentCallbackType callbackType, id _Nullable result);

/**
* @abstract Called on main thread when the component has just laid out.
Expand Down
6 changes: 3 additions & 3 deletions ios/sdk/WeexSDK/Sources/Protocol/WXValidateProtocol.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ NS_ASSUME_NONNULL_BEGIN

@interface WXValidateResult : NSObject

@property(nonatomic,assign)BOOL isSuccess;
@property(nonatomic,strong)NSError* error;
@property(nonatomic,assign) BOOL isSuccess;
@property(nonatomic,strong) NSError* _Nullable error;

@end

Expand All @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN

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

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

@end

Expand Down
4 changes: 2 additions & 2 deletions ios/sdk/WeexSDK/Sources/Utility/WXVersion.m
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
#import "WXVersion.h"
#import "WXDefine.h"

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

NSString* GetWeexSDKVersion(void)
{
Expand Down
6 changes: 3 additions & 3 deletions ios/sdk/WeexSDK/Sources/WebSocket/WXWebSocketHandler.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ NS_ASSUME_NONNULL_BEGIN
- (void)didOpen;
- (void)didFailWithError:(NSError *)error;
- (void)didReceiveMessage:(id)message;
- (void)didCloseWithCode:(NSInteger)code reason:(NSString *)reason wasClean:(BOOL)wasClean;
- (void)didCloseWithCode:(NSInteger)code reason:(nullable NSString *)reason wasClean:(BOOL)wasClean;
@end

@protocol WXWebSocketHandler<NSObject>

- (void)open:(NSString *)url protocol:(NSString *)protocol identifier:(NSString *)identifier withDelegate:(id<WXWebSocketDelegate>)delegate;
- (void)open:(NSString *)url protocol:(NSString *)protocol identifier:(nullable NSString *)identifier withDelegate:(id<WXWebSocketDelegate>)delegate;
- (void)send:(NSString *)identifier data:(NSString *)data;
- (void)close:(NSString *)identifier;
- (void)close:(NSString *)identifier code:(NSInteger)code reason:(NSString *)reason;
- (void)close:(NSString *)identifier code:(NSInteger)code reason:(nullable NSString *)reason;
- (void)clear:(NSString *)identifier;
@end

Expand Down
4 changes: 2 additions & 2 deletions weex_core/Source/core/layout/layout.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@
#include <iostream>
#include <string>
#include <algorithm>
#include "style.h"
#include "flex_enum.h"
#include <WeexSDK/style.h>
#include <WeexSDK/flex_enum.h>

namespace WeexCore {

Expand Down
2 changes: 1 addition & 1 deletion weex_core/Source/core/layout/style.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#define WEEXCORE_FLEXLAYOUT_WXCOREFLEXENUMS_H


#include "flex_enum.h"
#include <WeexSDK/flex_enum.h>
#include <math.h>
#include <cmath>

Expand Down

0 comments on commit 648e0f5

Please sign in to comment.