Commit 5a933918de3bcb4bb2435925d41feca7fb88d7d0
Merge branch 'master' of bj.gitlab.cnlive.com:ios-team/CNLiveUserSystem
# Conflicts: # Products/CNLiveUserSystemSDK.framework/CNLiveUserSystemSDK # Products/CNLiveUserSystemSDK.framework/Info.plist
Showing
4 changed files
with
0 additions
and
319 deletions
Products/CNLiveUserSystemSDK.framework/CNLiveUserSystemSDK deleted
100644 → 0
No preview for this file type
Products/CNLiveUserSystemSDK.framework/Headers/CNLiveUserSystemCenter.h deleted
100644 → 0
| 1 | -// | |
| 2 | -// CNLiveUserSystemCenter.h | |
| 3 | -// CNLiveUserSystemDemo | |
| 4 | -// | |
| 5 | -// Created by iOS on 16/9/12. | |
| 6 | -// Copyright © 2016年 zhulin. All rights reserved. | |
| 7 | -// | |
| 8 | - | |
| 9 | -#import <Foundation/Foundation.h> | |
| 10 | -#import "CNLiveUserSystemTypeDef.h" | |
| 11 | -#import <UIKit/UIKit.h> | |
| 12 | - | |
| 13 | -@interface CNLiveUserSystemCenter : NSObject | |
| 14 | - | |
| 15 | -/** | |
| 16 | - @abstract 初始化 | |
| 17 | - @param appId 注册成功获得应用ID | |
| 18 | - @param appKey 注册成功获得应用key | |
| 19 | - @param appSecret 注册成功获得应用secret | |
| 20 | - @param isTestEnvironment 测试环境开关 | |
| 21 | - @warning 必传参数 | |
| 22 | - 必须在 - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions; 方法中调用 | |
| 23 | - */ | |
| 24 | - + (void)setAppId:(NSString *)appId appKey:(NSString *)appKey appSecret:(NSString *)appSecret isTestEnvironment:(BOOL)isTestEnvironment; | |
| 25 | - | |
| 26 | -/** | |
| 27 | - @abstract 初始化 | |
| 28 | - @param appId 注册成功获得应用ID | |
| 29 | - @param appKey 注册成功获得应用key | |
| 30 | - @param appSecret 注册成功获得应用secret | |
| 31 | - @warning 必传参数 | |
| 32 | - 必须在 - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions; 方法中调用 | |
| 33 | - *此方法环境默认为正式环境,建议使用如下方法初始化. | |
| 34 | - + (void)setAppId:(NSString *)appId appKey:(NSString *)appKey appSecret:(NSString *)appSecret isTestEnvironment:(BOOL)isTestEnvironment; | |
| 35 | - | |
| 36 | - */ | |
| 37 | -+ (void)setAppId:(NSString *)appId appKey:(NSString *)appKey appSecret:(NSString *)appSecret; | |
| 38 | - | |
| 39 | -/** | |
| 40 | - @abstract 注册 | |
| 41 | - @param userName 邮箱或手机 | |
| 42 | - @param password 密码 | |
| 43 | - @param verificationCode 手机验证码(手机号注册时必填) | |
| 44 | - @param invitationCode 邀请码(非必填) | |
| 45 | - @param frmId 渠道ID(非必填) | |
| 46 | - @param success 成功回调 | |
| 47 | - @param failure 失败回调 | |
| 48 | - */ | |
| 49 | -+ (void)registerWithUserName:(NSString *)userName password:(NSString *)password verificationCode:(NSString *)verificationCode invitationCode:(NSString *)invitationCode frmId:(NSString *)frmId success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 50 | - | |
| 51 | - | |
| 52 | -/** | |
| 53 | - @abstract 第三方登录 | |
| 54 | - @param plat 第三方平台编号(如plat: 1:sina weibo 2:qq 3:weixin 4:renren 注:如qq登录,plat=@"2") | |
| 55 | - @param thirdPartyId 第三方用户ID | |
| 56 | - @param nickName 用户昵称 | |
| 57 | - @param gender 性别,m:男、f:女、n:未知(非必填) | |
| 58 | - @param location 用户所在地(非必填) | |
| 59 | - @param faceUrl 头像,约100*100(非必填) | |
| 60 | - @param frmId 渠道ID(非必填) | |
| 61 | - @param success 成功回调 | |
| 62 | - @param failure 失败回调 | |
| 63 | - */ | |
| 64 | -+ (void)thirdPartyLoginWithThirdPartyPlatType:(NSString *)plat thirdPartyId:(NSString *)thirdPartyId nickName:(NSString *)nickName gender:(NSString *)gender location:(NSString *)location faceUrl:(NSString *)faceUrl frmId:(NSString *)frmId success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 65 | - | |
| 66 | - | |
| 67 | -/** | |
| 68 | - @abstract 快捷登录 | |
| 69 | - @param userName 手机号 | |
| 70 | - @param verificationCode 验证码 | |
| 71 | - @param frmId 渠道ID(非必填) | |
| 72 | - @param success 成功回调 | |
| 73 | - @param failure 失败回调 | |
| 74 | - */ | |
| 75 | -+ (void)shortcutLoginWithUserName:(NSString *)userName verificationCode:(NSString *)verificationCode frmId:(NSString *)frmId success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 76 | - | |
| 77 | - | |
| 78 | -/** | |
| 79 | - @abstract 登录 | |
| 80 | - @param userName 手机号或邮箱 | |
| 81 | - @param password 密码 | |
| 82 | - @param frmId 渠道ID(非必填) | |
| 83 | - @param success 成功回调 | |
| 84 | - @param failure 失败回调 | |
| 85 | - */ | |
| 86 | -+ (void)loginWithUserName:(NSString *)userName password:(NSString *)password frmId:(NSString *)frmId success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 87 | - | |
| 88 | - | |
| 89 | -/** | |
| 90 | - @abstract 发送验证码 | |
| 91 | - @param mobile 手机号 | |
| 92 | - @param type 发送验证码类型(详见VerificationCodeType) | |
| 93 | - @param success 成功回调 | |
| 94 | - @param failure 失败回调 | |
| 95 | - */ | |
| 96 | -+ (void)verificationCodeType:(VerificationCodeType)type mobile:(NSString *)mobile success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 97 | - | |
| 98 | - | |
| 99 | -/** | |
| 100 | - @abstract 更新用户附加信息 | |
| 101 | - @param uid 用户ID | |
| 102 | - @param extInfo 扩展信息(格式由对方自己组织,平台只负责存储和原样读取,NSString类型) | |
| 103 | - @param success 成功回调 | |
| 104 | - @param failure 失败回调 | |
| 105 | - */ | |
| 106 | -+ (void)updateOtherInfoWithUid:(NSString *)uid extInfo:(NSString *)extInfo success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 107 | - | |
| 108 | - | |
| 109 | -/** | |
| 110 | - @abstract 修改用户单项信息 | |
| 111 | - @param type 修改类型(nickName-昵称,gender-性别,email-邮箱, location-联系方式(地址)) | |
| 112 | - @param uid 用户ID | |
| 113 | - @param info 对应的信息(注gender对应f/m/n) | |
| 114 | - @param success 成功回调 | |
| 115 | - @param failure 失败回调 | |
| 116 | - */ | |
| 117 | -+ (void)modifyUserInfoType:(UserInfoType)type uid:(NSString *)uid modifyInfo:(NSString *)info success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 118 | - | |
| 119 | - | |
| 120 | -/** | |
| 121 | - @abstract 更新手机号 | |
| 122 | - @param uid 用户ID | |
| 123 | - @param mobile 手机号 | |
| 124 | - @param verificationCode 验证码 | |
| 125 | - @param success 成功回调 | |
| 126 | - @param failure 失败回调 | |
| 127 | - */ | |
| 128 | -+ (void)updateMobileWithUid:(NSString *)uid mobile:(NSString *)mobile verificationCode:(NSString *)verificationCode success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 129 | - | |
| 130 | - | |
| 131 | -/** | |
| 132 | - @abstract 绑定第三方账号 | |
| 133 | - @param uid 用户ID | |
| 134 | - @param plat 第三方平台编号(如platform: 1:sina weibo 2:qq 3:weixin 4:renren 注:如绑定qq,thirdPartyPlat = @"2") | |
| 135 | - @param thirdPartyId 第三方用户ID | |
| 136 | - @param success 成功回调 | |
| 137 | - @param failure 失败回调 | |
| 138 | - */ | |
| 139 | -+ (void)bindingThirdPartyWithUid:(NSString *)uid thirdPartyPlatType:(NSString *)plat thirdPartyId:(NSString *)thirdPartyId success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 140 | - | |
| 141 | - | |
| 142 | -/** | |
| 143 | - @abstract 修改密码(通过手机号修改) | |
| 144 | - @param mobile 手机号 | |
| 145 | - @param verificationCode 验证码 | |
| 146 | - @param newPassword 新密码 | |
| 147 | - @param success 成功回调 | |
| 148 | - @param failure 失败回调 | |
| 149 | - */ | |
| 150 | -+ (void)changePasswordWithMobile:(NSString *)mobile verificationCode:(NSString *)verificationCode newPassword:(NSString *)newPassword success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 151 | - | |
| 152 | - | |
| 153 | -/** | |
| 154 | - @abstract 上传头像 | |
| 155 | - @param uid 用户ID | |
| 156 | - @param icon 头像 (图片质量 0.5) | |
| 157 | - @param success 成功回调 | |
| 158 | - @param failure 失败回调 | |
| 159 | - */ | |
| 160 | -+ (void)uploadIconWithUid:(NSString *)uid icon:(UIImage *)icon success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 161 | - | |
| 162 | -/** | |
| 163 | - @abstract 上传头像 新增 | |
| 164 | - @param uid 用户ID | |
| 165 | - @param compressionQuality 头像质量 0-1 Default 0.5 | |
| 166 | - @param icon 头像 | |
| 167 | - @param success 成功回调 | |
| 168 | - @param failure 失败回调 | |
| 169 | - | |
| 170 | - */ | |
| 171 | -+ (void)uploadIconWithUid:(NSString *)uid icon:(UIImage *)icon compressionQuality:(CGFloat)compressionQuality success:(void (^)(id))success failure:(void (^)(NSDictionary *))failure; | |
| 172 | - | |
| 173 | -/** | |
| 174 | - @abstract 查询用户信息 | |
| 175 | - @param uid 用户ID | |
| 176 | - @param srcUid 被查询用户ID | |
| 177 | - @param success 成功回调 | |
| 178 | - @param failure 失败回调 | |
| 179 | - */ | |
| 180 | -+ (void)queryUserInfoWithUid:(NSString *)uid srcUid:(NSString *)srcUid success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 181 | - | |
| 182 | - | |
| 183 | -/** | |
| 184 | - @abstract 查询多条用户信息 | |
| 185 | - @param uid 用户ID | |
| 186 | - @param srcUids 被查询用户IDs | |
| 187 | - @param success 成功回调 | |
| 188 | - @param failure 失败回调 | |
| 189 | - */ | |
| 190 | -+ (void)queryMoreUserInfosWithUid:(NSString *)uid srcUids:(NSArray *)srcUids success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 191 | - | |
| 192 | - | |
| 193 | -/** | |
| 194 | - @abstract 用户反馈 | |
| 195 | - @param contentId 举报内容ID | |
| 196 | - @param message 举报内容(app自己组织-不能带特殊字符&号等) | |
| 197 | - @param success 成功回调 | |
| 198 | - @param failure 失败回调 | |
| 199 | - */ | |
| 200 | -+ (void)feedbackWithContentId:(NSString *)contentId message:(NSString *)message success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 201 | - | |
| 202 | - | |
| 203 | -/** | |
| 204 | - 通过邮箱修改密码 | |
| 205 | - | |
| 206 | - @param email 邮箱 | |
| 207 | - @param newPwd 新密码 | |
| 208 | - @param success 成功回调 | |
| 209 | - @param failure 失败回调 | |
| 210 | - */ | |
| 211 | -+ (void)modifyPwdWithEmail:(NSString *)email newPwd:(NSString *)newPwd success:(void (^)(id result))success failure :(void (^)(NSDictionary *errorDic))failure; | |
| 212 | - | |
| 213 | - | |
| 214 | -/** | |
| 215 | - 通过原密码修改密码 | |
| 216 | - | |
| 217 | - @param uid 用户ID | |
| 218 | - @param pwd 原密码 | |
| 219 | - @param newPwd 新密码 | |
| 220 | - @param success 成功回调 | |
| 221 | - @param failure 失败回调 | |
| 222 | - */ | |
| 223 | -+ (void)oldPwdChangePasswordWithUid:(NSString *)uid pwd:(NSString *)pwd newPwd:(NSString *)newPwd success:(void (^)(id result))success failure :(void (^)(NSDictionary *errorDic))failure; | |
| 224 | - | |
| 225 | - | |
| 226 | -/** | |
| 227 | - 注册前校验手机验证码 | |
| 228 | - | |
| 229 | - @param mobile 手机号 | |
| 230 | - @param verificationCode 验证码 | |
| 231 | - @param success 成功回调 | |
| 232 | - @param getVersion 失败回调 | |
| 233 | - */ | |
| 234 | -+ (void)registerCheckVerificationCodeWithMobile:(NSString *)mobile verificationCode:(NSString *)verificationCode success:(void (^)(id result))success failure :(void (^)(NSDictionary *errorDic))failure; | |
| 235 | - | |
| 236 | - | |
| 237 | -/** | |
| 238 | - 快捷登录前校验手机验证码 | |
| 239 | - | |
| 240 | - @param mobile 手机号 | |
| 241 | - @param verificationCode 验证码 | |
| 242 | - @param success 成功回调 | |
| 243 | - @param failure 失败回调 | |
| 244 | - */ | |
| 245 | -+ (void)shortcutLoginCheckVerificationCodeWithMobile:(NSString *)mobile verificationCode:(NSString *)verificationCode success:(void (^)(id result))success failure :(void (^)(NSDictionary *errorDic))failure; | |
| 246 | - | |
| 247 | - | |
| 248 | -/** | |
| 249 | - 验证第三方账号是否注册,若注册则直接登录返回用户信息,若未注册返回errorCode | |
| 250 | - | |
| 251 | - @param plat 第三方平台编号(如plat: 1:sina weibo 2:qq 3:weixin 4:renren 注:如qq登录,plat=@"2") | |
| 252 | - @param thirdPartyId 第三方用户ID | |
| 253 | - @param frmId 渠道ID(非必填) | |
| 254 | - @param success 成功回调 | |
| 255 | - @param failure 失败回调 | |
| 256 | - */ | |
| 257 | -+ (void)thirdPartyCheckLoginWithThirdPartyPlatType:(NSString *)plat thirdPartyId:(NSString *)thirdPartyId frmId:(NSString *)frmId success:(void (^)(id result))success failure :(void (^)(NSDictionary *errorDic))failure; | |
| 258 | - | |
| 259 | - | |
| 260 | -/** | |
| 261 | - 第三方注册强制绑定手机号登录: 手机号+密码+验证码+三方账号 | |
| 262 | - | |
| 263 | - @param plat 第三方平台编号(如plat: 1:sina weibo 2:qq 3:weixin 4:renren 注:如qq登录,plat=@"2") | |
| 264 | - @param thirdPartyId 第三方用户ID | |
| 265 | - @param nickName 用户昵称 | |
| 266 | - @param gender 性别,m:男、f:女、n:未知(非必填) | |
| 267 | - @param location 用户所在地(非必填) | |
| 268 | - @param faceUrl 头像,约100*100(非必填) | |
| 269 | - @param mobile 手机号 | |
| 270 | - @param verificationCode 验证码 (验证码类型为快捷登录VerificationCodeTypeShortcutLogin) | |
| 271 | - @param pawd 注册密码 | |
| 272 | - @param frmId 渠道ID(非必填) | |
| 273 | - @param success 成功回调 | |
| 274 | - @param failure 失败回调 | |
| 275 | - */ | |
| 276 | -+ (void)thirdPartyBindMobileLoginWithThirdPartyPlatType:(NSString *)plat thirdPartyId:(NSString *)thirdPartyId nickName:(NSString *)nickName gender:(NSString *)gender location:(NSString *)location faceUrl:(NSString *)faceUrl mobile:(NSString *)mobile verificationCode:(NSString *)verificationCode pawd:(NSString *)pawd frmId:(NSString *)frmId success:(void (^)(id result))success failure:(void (^)(NSDictionary *errorDic))failure; | |
| 277 | - | |
| 278 | - | |
| 279 | -/** | |
| 280 | - * 获取SDK版本号 | |
| 281 | - */ | |
| 282 | -+ (NSString *)getVersion; | |
| 283 | - | |
| 284 | - | |
| 285 | - | |
| 286 | -@end |
Products/CNLiveUserSystemSDK.framework/Headers/CNLiveUserSystemTypeDef.h deleted
100644 → 0
| 1 | -// | |
| 2 | -// CNLiveUserSystemTypeDef.h | |
| 3 | -// CNLiveUserSystemDemo | |
| 4 | -// | |
| 5 | -// Created by iOS on 16/9/12. | |
| 6 | -// Copyright © 2016年 zhulin. All rights reserved. | |
| 7 | -// | |
| 8 | - | |
| 9 | -#ifndef CNLiveUserSystemTypeDef_h | |
| 10 | -#define CNLiveUserSystemTypeDef_h | |
| 11 | - | |
| 12 | -//获取验证码 | |
| 13 | -typedef NS_ENUM(NSUInteger, VerificationCodeType) { | |
| 14 | - VerificationCodeTypeShortcutLogin = 0, //快捷登录 | |
| 15 | - VerificationCodeTypeRegister, //注册或修改手机号 | |
| 16 | - VerificationCodeTypeRetrievePassword //找回或修改密码 | |
| 17 | -}; | |
| 18 | - | |
| 19 | -//修改单项用户信息类型 | |
| 20 | -typedef NS_ENUM(NSUInteger, UserInfoType) { | |
| 21 | - UserInfoTypeNickName = 0, //昵称 | |
| 22 | - UserInfoTypeGender, //性别(f/m/n) | |
| 23 | - UserInfoTypeEmail, //邮箱 | |
| 24 | - UserInfoTypeLocation, //联系方式(地址) | |
| 25 | -}; | |
| 26 | - | |
| 27 | -//校验验证码 | |
| 28 | -typedef NS_ENUM(NSInteger, CheckVerificationCodeType) { | |
| 29 | - CheckVerificationCodeTypeRegister = 0,//注册前校验验证码 | |
| 30 | - CheckVerificationCodeTypeShortcutLogin //快捷登录前校验验证码 | |
| 31 | -}; | |
| 32 | - | |
| 33 | -#endif /* CNLiveUserSystemTypeDef_h */ |
Products/CNLiveUserSystemSDK.framework/Info.plist deleted
100644 → 0
No preview for this file type