Affdex iOS SDK "set the licensePath property with a valid file path" 错误
Affdex iOS SDK "set the licensePath property with a valid file path" error
使用 iOS SDK,我尝试像这样设置许可证令牌:
#ifndef YOUR_AFFDEX_LICENSE_STRING_GOES_HERE
#define YOUR_AFFDEX_LICENSE_STRING_GOES_HERE @"090b118356d7c6afc08b6b58763...snip...56ade05a27c71c80f221"
#endif
但是当我尝试运行你的 AffdexMe 演示时,它说
Detector Error. No license provided.
设置宏时,您需要使用从Affectiva 收到的SDK 许可证文件的内容。当您检查许可证文件的内容时,您会看到一个 JSON 字符串,如下所示:
{"token": "1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef", "licensor": "Affectiva Inc.", "expires": "2019-04-15", "developerId": "dev@mycompany.com", "software": "Affdex SDK"}
相应地设置宏:
#define YOUR_AFFDEX_LICENSE_STRING_GOES_HERE {\"token\": \"1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef\", \"licensor\": \"Affectiva Inc.\", \"expires\": \"2019-04-15\", \"developerId\": \"dev@mycompany.com\", \"software\": \"Affdex SDK\"}
请注意,使用反斜杠字符转义每个双引号字符很重要,这样 C 预处理器就不会混淆。
使用 iOS SDK,我尝试像这样设置许可证令牌:
#ifndef YOUR_AFFDEX_LICENSE_STRING_GOES_HERE
#define YOUR_AFFDEX_LICENSE_STRING_GOES_HERE @"090b118356d7c6afc08b6b58763...snip...56ade05a27c71c80f221"
#endif
但是当我尝试运行你的 AffdexMe 演示时,它说
Detector Error. No license provided.
设置宏时,您需要使用从Affectiva 收到的SDK 许可证文件的内容。当您检查许可证文件的内容时,您会看到一个 JSON 字符串,如下所示:
{"token": "1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef", "licensor": "Affectiva Inc.", "expires": "2019-04-15", "developerId": "dev@mycompany.com", "software": "Affdex SDK"}
相应地设置宏:
#define YOUR_AFFDEX_LICENSE_STRING_GOES_HERE {\"token\": \"1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef\", \"licensor\": \"Affectiva Inc.\", \"expires\": \"2019-04-15\", \"developerId\": \"dev@mycompany.com\", \"software\": \"Affdex SDK\"}
请注意,使用反斜杠字符转义每个双引号字符很重要,这样 C 预处理器就不会混淆。