Returns the build time of the firmware - Android Android OS

Android examples for Android OS:Firmware

Description

Returns the build time of the firmware

Demo Code

import android.content.Context;
import android.provider.Settings;
import java.io.File;

public class Main{

    public static void main(String[] argv){
        System.out.println(getLastModified());
    }/*from   w  w w  . jav  a 2  s . c  om*/
    /**
     * Returns the build time of the firmware
     * 
     * @return the build time of the firmware
     */
    public static final long getLastModified() {
        return new File("/system/build.prop").lastModified();
    }

}

Related Tutorials