1 package com.android.launcher3;
2 
3 import android.text.TextUtils;
4 import android.util.Log;
5 
6 public class BuildInfo {
7     private static final boolean DBG = false;
8     private static final String TAG = "BuildInfo";
9 
isDogfoodBuild()10     public boolean isDogfoodBuild() {
11         return false;
12     }
13 
loadByName(String className)14     public static BuildInfo loadByName(String className) {
15         if (TextUtils.isEmpty(className)) return new BuildInfo();
16 
17         if (DBG) Log.d(TAG, "Loading BuildInfo: " + className);
18         try {
19             Class<?> cls = Class.forName(className);
20             return (BuildInfo) cls.newInstance();
21         } catch (ClassNotFoundException e) {
22             Log.e(TAG, "Bad BuildInfo class", e);
23         } catch (InstantiationException e) {
24             Log.e(TAG, "Bad BuildInfo class", e);
25         } catch (IllegalAccessException e) {
26             Log.e(TAG, "Bad BuildInfo class", e);
27         } catch (ClassCastException e) {
28             Log.e(TAG, "Bad BuildInfo class", e);
29         }
30         return new BuildInfo();
31     }
32 }
33