package com.sheep.jiuyan.samllsheep.utils;

import android.content.Context;

import android.net.wifi.WifiManager;

import android.telephony.TelephonyManager;


/**
 * @ Created by Dlg
 * @ <p>TiTle:  DeviceUtils</p>
 * @ <p>Description:获取各种硬件信息</p>
 * @ date:  2017/10/29 11:48
 * @ QQ:    315096953
 */

public class DeviceUtils {

    private Context mContext;
    private TelephonyManager phone;
    private WifiManager wifi;

    public DeviceUtils(Context context) {
        phone = (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE);
        wifi = (WifiManager) context.getSystemService(Context.WIFI_SERVICE);
        mContext = context;
    }

    public String getIMEI() {
        try {
            return phone.getDeviceId();
        } catch (Exception e) {
            return "";
        }
    }


}
