当前位置: 首页>>代码示例>>Java>>正文


Java Build.MANUFACTURER属性代码示例

本文整理汇总了Java中android.os.Build.MANUFACTURER属性的典型用法代码示例。如果您正苦于以下问题:Java Build.MANUFACTURER属性的具体用法?Java Build.MANUFACTURER怎么用?Java Build.MANUFACTURER使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在android.os.Build的用法示例。


在下文中一共展示了Build.MANUFACTURER属性的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: sendFeedback

public static void sendFeedback(Context context) {
    String body = null;
    try {
        body = context.getPackageManager().getPackageInfo(context.getPackageName(), 0).versionName;
        body = "\n\n-----------------------------\nPlease don't remove this information\n Device OS: Android \n Device OS version: " +
                Build.VERSION.RELEASE + "\n App Version: " + body + "\n Device Brand: " + Build.BRAND +
                "\n Device Model: " + Build.MODEL + "\n Device Manufacturer: " + Build.MANUFACTURER;
    } catch (PackageManager.NameNotFoundException e) {
    }
    Intent intent = new Intent(Intent.ACTION_SEND);
    intent.setType("message/rfc822");
    intent.putExtra(Intent.EXTRA_EMAIL, new String[]{"[email protected]"});
    intent.putExtra(Intent.EXTRA_SUBJECT, "发送自你的安卓设备");
    intent.putExtra(Intent.EXTRA_TEXT, body);
    context.startActivity(Intent.createChooser(intent, context.getString(R.string.choose_email_client)));
}
 
开发者ID:wendyltan,项目名称:EasyTodo,代码行数:16,代码来源:SettingsActivity.java

示例2: getHandSetInfo

private static String getHandSetInfo() {
    String handSetInfo = "手机型号:" + Build.MODEL
            + "\n系统版本:" + Build.VERSION.RELEASE
            + "\n产品型号:" + Build.PRODUCT
            + "\n版本显示:" + Build.DISPLAY
            + "\n系统定制商:" + Build.BRAND
            + "\n设备参数:" + Build.DEVICE
            + "\n开发代号:" + Build.VERSION.CODENAME
            + "\nSDK版本号:" + Build.VERSION.SDK_INT
            + "\nCPU类型:" + Build.CPU_ABI
            + "\n硬件类型:" + Build.HARDWARE
            + "\n主机:" + Build.HOST
            + "\n生产ID:" + Build.ID
            + "\nROM制造商:" + Build.MANUFACTURER // 这行返回的是rom定制商的名称
            ;
    Log.e("tt",handSetInfo);
    return handSetInfo;
}
 
开发者ID:hss01248,项目名称:MainActivityUIUtil,代码行数:18,代码来源:StatusbarUtil.java

示例3: updateDeviceInfo

private void updateDeviceInfo() {

        if (!configuration.isDeviceManufacturerCollectionDisabled()) {
            this.manufacturer = Build.MANUFACTURER;
        }

        if (!configuration.isDeviceModelCollectionDisabled()) {
            this.model = Build.MODEL;
        }

        if (!configuration.isOperaringSystemCollectionDisbaled()) {
            this.operatingSystem = BASE_NAME + " " + Build.VERSION.RELEASE;
        }

        if (!configuration.isChargingInfoCollectionDisabled()) {
            Intent batteryIntent = context.registerReceiver(
                    null,
                    new IntentFilter(Intent.ACTION_BATTERY_CHANGED)
            );
            this.isCharging = String.valueOf(isDeviceCharging(batteryIntent));
        }
    }
 
开发者ID:OpenLocate,项目名称:openlocate-android,代码行数:22,代码来源:InformationFieldsFactory.java

示例4: e

private e(Context context) {
    this.b = "2.0.3";
    this.L = VERSION.SDK_INT;
    this.M = Build.MODEL;
    this.ab = Build.MANUFACTURER;
    this.bq = Locale.getDefault().getLanguage();
    this.aQ = 0;
    this.aR = null;
    this.aS = null;
    this.cB = null;
    this.cC = null;
    this.cD = null;
    this.cE = null;
    this.cF = null;
    this.cB = context.getApplicationContext();
    this.cA = l.x(this.cB);
    this.a = l.D(this.cB);
    this.br = c.e(this.cB);
    this.bs = l.C(this.cB);
    this.bt = TimeZone.getDefault().getID();
    Context context2 = this.cB;
    this.aQ = l.au();
    this.al = l.H(this.cB);
    this.aR = this.cB.getPackageName();
    if (this.L >= 14) {
        this.cC = l.M(this.cB);
    }
    context2 = this.cB;
    this.cD = l.az().toString();
    this.cE = l.L(this.cB);
    this.cF = l.ax();
    this.aS = l.R(this.cB);
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:33,代码来源:e.java

示例5: getCrashHead

/**
 * 获取崩溃头
 *
 * @return 崩溃头
 */
private String getCrashHead() {
    return "\n************* Crash Log Head ****************" +
            "\nDevice Manufacturer: " + Build.MANUFACTURER +// 设备厂商
            "\nDevice Model       : " + Build.MODEL +// 设备型号
            "\nAndroid Version    : " + Build.VERSION.RELEASE +// 系统版本
            "\nAndroid SDK        : " + Build.VERSION.SDK_INT +// SDK版本
            "\nApp VersionName    : " + versionName +
            "\nApp VersionCode    : " + versionCode +
            "\n************* Crash Log Head ****************\n\n";
}
 
开发者ID:angcyo,项目名称:RLibrary,代码行数:15,代码来源:CrashUtils.java

示例6: getPhoneSysInfo

/**
 * 获取崩溃头
 *
 * @return 崩溃头
 */
public static String getPhoneSysInfo() {
    return "\n************* Log Head ****************" +
            "\nDevice Manufacturer: " + Build.MANUFACTURER +// 设备厂商
            "\nDevice Model       : " + Build.MODEL +// 设备型号
            "\nAndroid Version    : " + Build.VERSION.RELEASE +// 系统版本
            "\nAndroid SDK        : " + Build.VERSION.SDK_INT +// SDK版本
            "\nApp VersionName    : " + getAppVersionName() +
            "\nApp VersionCode    : " + getAppVersionCode() +
            "\n************* Log Head ****************\n\n";
}
 
开发者ID:tututututututu,项目名称:BaseCore,代码行数:15,代码来源:AppUtils.java

示例7: c

private c(Context context) {
    this.b = StatConstants.VERSION;
    this.d = VERSION.SDK_INT;
    this.e = Build.MODEL;
    this.f = Build.MANUFACTURER;
    this.g = Locale.getDefault().getLanguage();
    this.l = 0;
    this.m = null;
    this.n = null;
    this.o = null;
    this.p = null;
    this.q = null;
    this.r = null;
    this.n = context;
    this.c = k.d(context);
    this.a = k.n(context);
    this.h = StatConfig.getInstallChannel(context);
    this.i = k.m(context);
    this.j = TimeZone.getDefault().getID();
    this.l = k.s(context);
    this.k = k.t(context);
    this.m = context.getPackageName();
    if (this.d >= 14) {
        this.o = k.A(context);
    }
    this.p = k.z(context).toString();
    this.q = k.x(context);
    this.r = k.e();
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:29,代码来源:c.java

示例8: phoneBrand

/**
 * 获取手机品牌
 *
 * @return
 */
private String phoneBrand() {
    try {
        return Build.MANUFACTURER;
    } catch (Exception e) {
        return "";
    }
}
 
开发者ID:hushengjun,项目名称:FastAndroid,代码行数:12,代码来源:PhoneManager.java

示例9: loadClass

@Override
protected Class<?> loadClass(String className, boolean resolve) throws ClassNotFoundException {

    if (Build.MANUFACTURER != null && sPreLoader.contains(Build.MANUFACTURER.toUpperCase())) {
        try {
            /**
             * FUCK QIKU!
             * 这里适配奇酷手机青春版。
             * 因为奇酷手机自己加载了自己修改过的的Support V4库,在插件中也用了这个库的时候,ClassLoader会优先加载奇酷手机自带的Support V4库。
             * 原因在于,奇酷手机没有预加载插件中打的Support V4库。详情可以研究super.loadClass(className, resolve)标准实现
             * 但是这可能会导致类不兼容,出现java.lang.IncompatibleClassChangeError。因为插件编译时使用的插件的Support V4,而奇酷手机则使
             * 用的是它修改过的Support V4。
             *
             * SO,在Class Loader加载某个Class的时候,我们优先从自己的ClassLoader中加载Class,如果找不到,再从Parent Class Loader中去加载。
             * 这样修改后,Class的加载顺序就跟系统的不一样了。
             *
             */
            Class<?> clazz = findClass(className);
            if (clazz != null) {
                return clazz;
            }
        } catch (ClassNotFoundException e) {
            Log.e("PluginClassLoader", "UCK QIKU:error", e);
        }
    }
    return super.loadClass(className, resolve);
}
 
开发者ID:amikey,项目名称:DroidPlugin,代码行数:27,代码来源:PluginClassLoader.java

示例10: getDeviceInfo

/**
 * 获取设备信息
 */
public String getDeviceInfo(Context context) {
    return getEmulatorName(context) + "\n" + "Build.PRODUCT: " + Build.PRODUCT + "\n" +
            "Build.MANUFACTURER: " + Build.MANUFACTURER + "\n" +
            "Build.BRAND: " + Build.BRAND + "\n" +
            "Build.DEVICE: " + Build.DEVICE + "\n" +
            "Build.MODEL: " + Build.MODEL + "\n" +
            "Build.HARDWARE: " + Build.HARDWARE + "\n" +
            "Build.FINGERPRINT: " + Build.FINGERPRINT;
}
 
开发者ID:CodyyAndroid,项目名称:EmulatorDetect,代码行数:12,代码来源:EmulatorDetectorService.java

示例11: getDeviceName

public String getDeviceName() {
    String manufacturer = Build.MANUFACTURER;
    String model = Build.MODEL;
    if (model.startsWith(manufacturer)) {
        return capitalize(model);
    } else {
        return capitalize(manufacturer) + " " + model;
    }
}
 
开发者ID:sarveshchavan7,项目名称:Trivia-Knowledge,代码行数:9,代码来源:HomeSettingTab.java

示例12: leakInfo

public static String leakInfo(Context context, HeapDump heapDump, AnalysisResult result,
                              boolean detailed) {
    PackageManager packageManager = context.getPackageManager();
    String packageName = context.getPackageName();
    try {
        PackageInfo packageInfo = packageManager.getPackageInfo(packageName, 0);
        String info = "In " + packageName + ":" + packageInfo.versionName + ":" + packageInfo
                .versionCode + ".\n";
        String detailedString = "";
        if (result.leakFound) {
            if (result.excludedLeak) {
                info = info + "* LEAK CAN BE IGNORED.\n";
            }
            info = info + "* " + result.className;
            if (!heapDump.referenceName.equals("")) {
                info = info + " (" + heapDump.referenceName + SocializeConstants.OP_CLOSE_PAREN;
            }
            info = info + " has leaked:\n" + result.leakTrace.toString() + "\n";
            if (detailed) {
                detailedString = "\n* Details:\n" + result.leakTrace.toDetailedString();
            }
        } else {
            info = result.failure != null ? info + "* FAILURE:\n" + Log.getStackTraceString
                    (result.failure) + "\n" : info + "* NO LEAK FOUND.\n\n";
        }
        return info + "* Reference Key: " + heapDump.referenceKey + "\n" + "* Device: " +
                Build.MANUFACTURER + " " + Build.BRAND + " " + Build.MODEL + " " + Build
                .PRODUCT + "\n" + "* Android Version: " + VERSION.RELEASE + " API: " +
                VERSION.SDK_INT + " LeakCanary: " + BuildConfig.LIBRARY_VERSION + "\n" + "* " +
                "Durations: watch=" + heapDump.watchDurationMs + "ms, gc=" + heapDump
                .gcDurationMs + "ms, heap dump=" + heapDump.heapDumpDurationMs + "ms, " +
                "analysis=" + result.analysisDurationMs + "ms" + "\n" + detailedString;
    } catch (NameNotFoundException e) {
        throw new RuntimeException(e);
    }
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:36,代码来源:LeakCanary.java

示例13: getDeviceName

public static String getDeviceName() {
    final String manufacturer = Build.MANUFACTURER, model = Build.MODEL;
    return model.startsWith(manufacturer) ? capitalizePhrase(model) : capitalizePhrase(manufacturer) + " " + model;
}
 
开发者ID:mDL-ILP,项目名称:mDL-ILP,代码行数:4,代码来源:WebAPI.java

示例14: getManufacturer

/**
 * 获取设备厂商
 */
public static String getManufacturer() {
    return Build.MANUFACTURER;
}
 
开发者ID:ChangsenLai,项目名称:codedemos,代码行数:6,代码来源:DeviceUtil.java

示例15: isMiBox2Device

public static boolean isMiBox2Device() {
    String manufacturer = Build.MANUFACTURER;
    String productName = Build.PRODUCT;
    return manufacturer.equalsIgnoreCase("Xiaomi")
        && productName.equalsIgnoreCase("dredd");
}
 
开发者ID:lisnstatic,项目名称:live_master,代码行数:6,代码来源:DeviceUtils.java


注:本文中的android.os.Build.MANUFACTURER属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。