is API Ginger Bread - Android Android OS

Android examples for Android OS:OS Version

Description

is API Ginger Bread

Demo Code


//package com.book2s;

import android.os.Build;

public class Main {
    public static int FROYO = 8;
    public static int GINGERBREAD_MR1 = 10;

    public static final boolean isApi9_GingerBread() {
        int sdk = getSDKVersion();
        return sdk >= FROYO && sdk <= GINGERBREAD_MR1;
    }//from ww w. j  a  va  2s.c  om

    public static final int getSDKVersion() {
        return Build.VERSION.SDK_INT;
    }
}

Related Tutorials