android获取手机唯一标识的方法
程序员文章站
2023-11-08 14:39:10
复制代码 代码如下:import android.provider.settings.secure;
private string android_id = secure...
复制代码 代码如下:
import android.provider.settings.secure;
private string android_id = secure.getstring(getcontext().getcontentresolver(),secure.android_id);
uuid deviceuuid = new uuid(androidid.hashcode(), ((long)tmdevice.hashcode() << 32) | tmserial.hashcode());
string deviceid = deviceuuid.tostring();