Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
//License from project: Apache License 

import android.os.Build;

import java.lang.reflect.Method;

public class Main {
    public static String getSystemProperties(String property) {
        try {
            Method getStringMethod = Build.class.getDeclaredMethod("getString", String.class);
            getStringMethod.setAccessible(true);
            return (String) getStringMethod.invoke(null, property);
        } catch (Exception e) {
            return null;
        }
    }
}