Android examples for Android OS:Emulator
is Android Emulator
//package com.java2s; import android.os.Build; import android.util.Log; public class Main { private static final String LOG_TAG = "DeviceUtils"; public static boolean isAndroidEmulator() { String product = Build.PRODUCT; if (product == null) return false; Log.d(LOG_TAG, "product=" + product); return product.matches(".*_?sdk_?.*"); }//w w w .jav a2 s . c om }