3

我希望我的应用用户能够投票一次。这意味着我需要他们的 UDID。

由于我不会唠叨要注册到我的应用程序,我发现有必要为该设备使用一些标识。

我听说 Apple 已弃用设备 UDID。

我怎样才能做到这一点?

4

4 回答 4

7

正如许多人所说,UDID 块并不是世界末日,因为苹果已经提供了仍然绑定到特定于设备的变量的方法。

我会阅读博客文章在 UDID 替代品的爆炸中蓬勃发展,并详细了解您的应用程序需要什么。

于 2012-06-10T09:37:24.337 回答
7

我会使用 OpenUDID 它使用起来非常简单 你会执行以下操作

#include "OpenUDID.h"
NSString* openUDID = [OpenUDID value];

从这里获取它 https://github.com/ylechelle/OpenUDID/

于 2012-06-10T09:38:48.180 回答
3

使用这个方法

+ (NSString *)newUUID
{
CFUUIDRef theUUID = CFUUIDCreate(NULL);
CFStringRef string = CFUUIDCreateString(NULL, theUUID);
CFRelease(theUUID);
return (NSString *)string;
}
于 2012-06-10T09:40:12.650 回答
0

If you have time until (probably) the WWDC keynote tomorrow, this could be interesting for you: The Wall Street Journal: Apple to Release New Tracking Tool for Apps

于 2012-06-10T21:16:32.123 回答