Initial clean commit
This commit is contained in:
87
Example/SellyCloudSDK/Kiwi.framework/Headers/Kiwi.h
Normal file
87
Example/SellyCloudSDK/Kiwi.framework/Headers/Kiwi.h
Normal file
@@ -0,0 +1,87 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
|
||||
typedef void(^KiwiInitListener)(int result);
|
||||
|
||||
@interface Kiwi : NSObject
|
||||
|
||||
/**
|
||||
* @breif 初始化接口,不需要重复调用接口。会访问网络,不要放在UI线程中
|
||||
* @param appkey 控制台获取的appkey
|
||||
* @return 0表示成功,非0表示失败,请咨询Kiwi开发人员
|
||||
*/
|
||||
+(int) Init:(const char *)appkey;
|
||||
|
||||
/**
|
||||
* @breif 初始化接口,不需要重复调用接口。会访问网络,不要放在UI线程中
|
||||
* @param appkey 控制台获取的appkey
|
||||
* @param callback 执行结果回调
|
||||
* @return 0表示成功,非0表示失败,请咨询Kiwi开发人员
|
||||
*/
|
||||
+(int) InitWithListener:(const char *)appkey :(KiwiInitListener)callback;
|
||||
|
||||
/**
|
||||
* @breif 转化接口,将rs标识转换为本地访问。不会访问网络,不会卡顿
|
||||
* @param name 控制台配置的防护目标rs标识
|
||||
* @param ip 转换后的ip缓冲区指针
|
||||
* @param ip_len 转换后的ip缓冲区长度
|
||||
* @param port 转换后的端口缓冲区指针
|
||||
* @param port_len 转换后的端口缓冲区长度
|
||||
* @return 0表示成功,非0表示失败,请咨询Kiwi开发人员
|
||||
*/
|
||||
+(int) ServerToLocal:(const char*)name :(char*)ip :(int)ip_len :(char*)port :(int)port_len;
|
||||
|
||||
/**
|
||||
* @breif 发送日志接口
|
||||
* @param mtype 用户自定义,用于区分不同类型的日志。需要大于1000
|
||||
* @param data 日志内容
|
||||
* @return 0表示成功,非0表示失败,请咨询Kiwi开发人员
|
||||
*/
|
||||
+(int) SendLog:(int)mtype :(const char*)data;
|
||||
|
||||
/**
|
||||
* @breif 重启Kiwi本地代理服务器
|
||||
*/
|
||||
+(void) RestartAllServer;
|
||||
|
||||
/**
|
||||
* @breif 强制重启某个Kiwi本地代理服务器
|
||||
*/
|
||||
+(int) ForceRestartServer:(int)port;
|
||||
|
||||
/**
|
||||
* @breif App切换到前台回调函数
|
||||
*/
|
||||
+(int) OnNetworkOn;
|
||||
|
||||
/**
|
||||
* @breif 获取流量信息,json格式
|
||||
* @param result 用户申请的缓冲区,用于保存结果数据,结果数据为json格式
|
||||
* @param buf_len 缓冲区长度
|
||||
*/
|
||||
+(int) NetworkStat:(char*)result :(int)buf_len;
|
||||
|
||||
/**
|
||||
* @breif DnsEx,高级转化接口,支持多种参数自定义
|
||||
* @param name 控制台配置的防护目标rs标识
|
||||
* @param port 转化后的端口
|
||||
* @param force_tcp 是否强制使用tcp协议,1为强制使用,此时不受端口号的限制
|
||||
* @param sndwnd 发送窗口大小,单位字节
|
||||
* @param rcvwnd 接受窗口大小,单位字节
|
||||
* @param kc_timer_interva 转化后的端口
|
||||
* @param if_local 是否监听在本地端口,1表示127.0.0.1,0表示0.0.0.0,此时改端口可以被其他机器访问
|
||||
* @param kc_timer_interva kcp刷新定时器,单位毫秒
|
||||
*/
|
||||
+(int) DnsEx:(const char*)name :(char*)port :(int)force_tcp :(int)sndwnd :(int)rcvwnd :(int)kc_timer_interva :(int)if_local :(int)specify_port;
|
||||
|
||||
/**
|
||||
* @breif 简单dns,可替代ServerToLocal,支持自定义端口
|
||||
* @param name 控制台配置的防护目标rs标识
|
||||
* @param specify_port 自定义端口,0表示默认值,此时使用控制台上的配置(随机端口或者固定端口), 大于0的值表示自定义端口,此时将忽视控制台的配置
|
||||
|
||||
@return 返回值小于0则表示出错,大于0表示端口号
|
||||
|
||||
注意:如果指定的端口号被占用,函数不会报错,而会使用随机端口,客户端可以根据返回的端口号和指定的端口号对比,判断指定的端口是否被占用
|
||||
*/
|
||||
+(int) SimpleDns:(const char*)name :(int)specify_port;
|
||||
|
||||
@end
|
||||
BIN
Example/SellyCloudSDK/Kiwi.framework/Info.plist
Normal file
BIN
Example/SellyCloudSDK/Kiwi.framework/Info.plist
Normal file
Binary file not shown.
BIN
Example/SellyCloudSDK/Kiwi.framework/Kiwi
Normal file
BIN
Example/SellyCloudSDK/Kiwi.framework/Kiwi
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,117 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>files</key>
|
||||
<dict>
|
||||
<key>Headers/Kiwi.h</key>
|
||||
<data>
|
||||
hTshupp5Rb/oKDRBX/LeG7s+pA0=
|
||||
</data>
|
||||
<key>Info.plist</key>
|
||||
<data>
|
||||
Z29BBEAeYQxWdTwROXsgZtFqCpg=
|
||||
</data>
|
||||
</dict>
|
||||
<key>files2</key>
|
||||
<dict>
|
||||
<key>Headers/Kiwi.h</key>
|
||||
<dict>
|
||||
<key>hash</key>
|
||||
<data>
|
||||
hTshupp5Rb/oKDRBX/LeG7s+pA0=
|
||||
</data>
|
||||
<key>hash2</key>
|
||||
<data>
|
||||
yTa1CInHVGfu37Zoev3OoMcTKdAdi+NFOaOaPvGFat8=
|
||||
</data>
|
||||
</dict>
|
||||
</dict>
|
||||
<key>rules</key>
|
||||
<dict>
|
||||
<key>^.*</key>
|
||||
<true/>
|
||||
<key>^.*\.lproj/</key>
|
||||
<dict>
|
||||
<key>optional</key>
|
||||
<true/>
|
||||
<key>weight</key>
|
||||
<real>1000</real>
|
||||
</dict>
|
||||
<key>^.*\.lproj/locversion.plist$</key>
|
||||
<dict>
|
||||
<key>omit</key>
|
||||
<true/>
|
||||
<key>weight</key>
|
||||
<real>1100</real>
|
||||
</dict>
|
||||
<key>^Base\.lproj/</key>
|
||||
<dict>
|
||||
<key>weight</key>
|
||||
<real>1010</real>
|
||||
</dict>
|
||||
<key>^version.plist$</key>
|
||||
<true/>
|
||||
</dict>
|
||||
<key>rules2</key>
|
||||
<dict>
|
||||
<key>.*\.dSYM($|/)</key>
|
||||
<dict>
|
||||
<key>weight</key>
|
||||
<real>11</real>
|
||||
</dict>
|
||||
<key>^(.*/)?\.DS_Store$</key>
|
||||
<dict>
|
||||
<key>omit</key>
|
||||
<true/>
|
||||
<key>weight</key>
|
||||
<real>2000</real>
|
||||
</dict>
|
||||
<key>^.*</key>
|
||||
<true/>
|
||||
<key>^.*\.lproj/</key>
|
||||
<dict>
|
||||
<key>optional</key>
|
||||
<true/>
|
||||
<key>weight</key>
|
||||
<real>1000</real>
|
||||
</dict>
|
||||
<key>^.*\.lproj/locversion.plist$</key>
|
||||
<dict>
|
||||
<key>omit</key>
|
||||
<true/>
|
||||
<key>weight</key>
|
||||
<real>1100</real>
|
||||
</dict>
|
||||
<key>^Base\.lproj/</key>
|
||||
<dict>
|
||||
<key>weight</key>
|
||||
<real>1010</real>
|
||||
</dict>
|
||||
<key>^Info\.plist$</key>
|
||||
<dict>
|
||||
<key>omit</key>
|
||||
<true/>
|
||||
<key>weight</key>
|
||||
<real>20</real>
|
||||
</dict>
|
||||
<key>^PkgInfo$</key>
|
||||
<dict>
|
||||
<key>omit</key>
|
||||
<true/>
|
||||
<key>weight</key>
|
||||
<real>20</real>
|
||||
</dict>
|
||||
<key>^embedded\.provisionprofile$</key>
|
||||
<dict>
|
||||
<key>weight</key>
|
||||
<real>20</real>
|
||||
</dict>
|
||||
<key>^version\.plist$</key>
|
||||
<dict>
|
||||
<key>weight</key>
|
||||
<real>20</real>
|
||||
</dict>
|
||||
</dict>
|
||||
</dict>
|
||||
</plist>
|
||||
Reference in New Issue
Block a user