@SuppressLint("InlinedApi") public static Map<Integer,String> TECHNOLOGY_MAP(){
  Map<Integer,String> result=new HashMap<>();
  result.put(TelephonyManager.NETWORK_TYPE_UNKNOWN,"NA");
  result.put(TelephonyManager.NETWORK_TYPE_GPRS,"GSM");
  result.put(TelephonyManager.NETWORK_TYPE_EDGE,"EDGE");
  result.put(TelephonyManager.NETWORK_TYPE_UMTS,"UMTS");
  result.put(TelephonyManager.NETWORK_TYPE_CDMA,"CDMA");
  result.put(TelephonyManager.NETWORK_TYPE_EVDO_0,"EDVO_0");
  result.put(TelephonyManager.NETWORK_TYPE_EVDO_A,"EDVO_A");
  result.put(TelephonyManager.NETWORK_TYPE_1xRTT,"1xRTT");
  result.put(TelephonyManager.NETWORK_TYPE_HSDPA,"HSDPA");
  result.put(TelephonyManager.NETWORK_TYPE_HSUPA,"HSUPA");
  result.put(TelephonyManager.NETWORK_TYPE_HSPA,"HSPA");
  result.put(TelephonyManager.NETWORK_TYPE_IDEN,"IDEN");
  if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.GINGERBREAD) {
    result.put(TelephonyManager.NETWORK_TYPE_EVDO_B,"EDV0_B");
  }
  if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB) {
    result.put(TelephonyManager.NETWORK_TYPE_LTE,"LTE");
    result.put(TelephonyManager.NETWORK_TYPE_EHRPD,"eHRPD");
  }
  if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB_MR2) {
    result.put(TelephonyManager.NETWORK_TYPE_HSPAP,"HSPA+");
  }
  return Collections.unmodifiableMap(result);
}

@ SuppressLint ( "InlinedApi" ) public static Map < Integer , String > TECHNOLOGY_MAP ( ) { Map < Integer , String > result = new HashMap < > ( ) ; result . put ( TelephonyManager . NETWORK_TYPE_UNKNOWN , "NA" ) ; result . put ( TelephonyManager . NETWORK_TYPE_GPRS , "GSM" ) ; result . put ( TelephonyManager . NETWORK_TYPE_EDGE , "EDGE" ) ; result . put ( TelephonyManager . NETWORK_TYPE_UMTS , "UMTS" ) ; result . put ( TelephonyManager . NETWORK_TYPE_CDMA , "CDMA" ) ; result . put ( TelephonyManager . NETWORK_TYPE_EVDO_0 , "EDVO_0" ) ; result . put ( TelephonyManager . NETWORK_TYPE_EVDO_A , "EDVO_A" ) ; result . put ( TelephonyManager . NETWORK_TYPE_1xRTT , "1xRTT" ) ; result . put ( TelephonyManager . NETWORK_TYPE_HSDPA , "HSDPA" ) ; result . put ( TelephonyManager . NETWORK_TYPE_HSUPA , "HSUPA" ) ; result . put ( TelephonyManager . NETWORK_TYPE_HSPA , "HSPA" ) ; result . put ( TelephonyManager . NETWORK_TYPE_IDEN , "IDEN" ) ; if ( Build . VERSION . SDK_INT >= Build . VERSION_CODES . GINGERBREAD ) { result . put ( TelephonyManager . NETWORK_TYPE_EVDO_B , "EDV0_B" ) ; } if ( Build . VERSION . SDK_INT >= Build . VERSION_CODES . HONEYCOMB ) { result . put ( TelephonyManager . NETWORK_TYPE_LTE , "LTE" ) ; result . put ( TelephonyManager . NETWORK_TYPE_EHRPD , "eHRPD" ) ; } if ( Build . VERSION . SDK_INT >= Build . VERSION_CODES . HONEYCOMB_MR2 ) { result . put ( TelephonyManager . NETWORK_TYPE_HSPAP , "HSPA+" ) ; } return Collections . unmodifiableMap ( result ) ; }
returns human readable technology name
