USDK国内接入文档


初始化 initUsdk

<p><strong>简要描述:</strong> </p> <ul> <li>初始化聚合与渠道SDK,此方法必须在SDK 所有方法之前调用</li> </ul> <p><strong>调用方式:</strong></p> <ol> <li> <p>导入SDK类</p> <pre><code class="language-c">#import "ky_usdk/USDK.h"</code></pre> </li> <li> <p>注册回调监听器</p> <pre><code class="language-c">[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(UsdkInitDidFinish:) name:nUSDKInitDidFinishNotification object:nil];</code></pre> </li> <li>调用接口 <pre><code class="language-c">[[USDK shareManager] initUsdk];</code></pre></li> </ol> <p><strong>参数:</strong> </p> <p>无</p> <p><strong>返回示例</strong></p> <pre><code>以接收NSNotification 为返回结果。 (void)UsdkInitDidFinish:(NSNotification *)notification{ if ([notification.object isEqual: cNotificationSuccess] ) { NSLog(@"初始化成功%@",notification.userInfo); //可以在此处调用登录接口。 }else { NSLog(@"初始化失败%@",notification.userInfo); } } </code></pre> <p><strong>返回参数 notification 说明</strong> </p> <table> <thead> <tr> <th style="text-align: left;">字段</th> <th style="text-align: left;">类型</th> <th style="text-align: left;">空</th> <th>注释</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">object</td> <td style="text-align: left;">String(10)</td> <td style="text-align: left;">否</td> <td>成功:cNotificationSuccess ;失败 :cNotificationFailed</td> </tr> </tbody> </table> <p><strong>备注</strong> </p>

页面列表

ITEM_HTML