MCPcopy Create free account
hub / github.com/Card-Forge/forge / getSystemProperty

Method getSystemProperty

forge-gui-android/src/forge/app/Main.java:145–165  ·  view source on GitHub ↗
(String propName)

Source from the content-addressed store, hash-verified

143 }
144
145 public static String getSystemProperty(String propName) {
146 String line;
147 BufferedReader input = null;
148 try {
149 java.lang.Process p = Runtime.getRuntime().exec("getprop " + propName);
150 input = new BufferedReader(new InputStreamReader(p.getInputStream()), 1024);
151 line = input.readLine();
152 input.close();
153 } catch (IOException ex) {
154 return null;
155 } finally {
156 if (input != null) {
157 try {
158 input.close();
159 } catch (IOException e) {
160 e.printStackTrace();
161 }
162 }
163 }
164 return line;
165 }
166
167 @Override
168 protected void onResume() {

Callers 1

isMiUiMethod · 0.95

Calls 2

getInputStreamMethod · 0.80
closeMethod · 0.65

Tested by

no test coverage detected