如果我说“嗨”这个词,我试图这样做如果声明给我真实,但它总是给我虚假!有人可以告诉我为什么吗?!这是我的代码:
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
// TODO Auto-generated method stub
if (requestCode ==check && resultCode == RESULT_OK){
ArrayList<String> results =data.getStringArrayListExtra(RecognizerIntent.EXTRA_RESULTS);
lv.setAdapter(new ArrayAdapter <String>(this ,android.R.layout.simple_list_item_1,results));
TextView display=(TextView)findViewById (R.id.TOF);
String what_you_say = lv.getContext().toString();
if (what_you_say.contentEquals("hi") == true)
display.setText("True");
else
display.setText("false");
}