The Double class wraps a value of the primitive type double in an object. An object of type Double contains a single field whose type is double. In addition, this class provides several methods for converting a double to a String and a String to a double, as well as other constants and methods useful when dealing with a double. 1. double 형 숫자를 String으로 변환 String strTemp = Double.toString(1.23456..
import android.content.Intent;import android.content.IntentFilter; Intent bat = registerReceiver(null, new IntentFilter(Intent.ACTION_BATTERY_CHANGED)); String battLevel = bat.getIntExtra("level", -1)+"%"; TextView textView = (TextView)findViewById(R.id.textView4);textView.setText( "배터리 : " + battLevel );