在android中edittext的初始值是什么?大家帮忙看看

String str=et.getText().toString();其中et为EditText类型

public TextView(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
** mText = "";**

mText 是个空串。
*/
@ViewDebug.CapturedViewProperty
public CharSequence getText() {
return mText;
}
getText()返回都就是mText。

public TextView(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
** mText = "";**

    final Resources res = getResources();
    final CompatibilityInfo compat = res.getCompatibilityInfo();

是个空串。

“”初始值就是什么都没有

edittext初始值是“”,判断初始值没有意义哦,
判断是否有输入一般这样 !TextUtils.isEmpty(et.getText().toString())