is Android - Android Android OS

Android examples for Android OS:System Model

Description

is Android

Demo Code


//package com.java2s;

import android.os.Build;

public class Main {
    public static boolean isAndroid() {
        try {/*from   www  .ja  v  a 2  s .c  o  m*/
            Class.forName("android.os.Build");
            return Build.VERSION.SDK_INT != 0;
        } catch (ClassNotFoundException ignored) {
            return false;
        }

    }
}

Related Tutorials