Android intent.setType("String value")

Android intent.setType("String value")

我已阅读 documentation of setType 但未提及参数。我在哪里可以阅读在 setType() 关键字中使用的完整可能的字符串参数。我需要有关 setType("vnd.android-dir/mms-sms") 的信息。我正在开发一些消息传递应用程序,这个 setType 对我来说工作正常。它将用户带到默认的消息传递应用程序。我想要的是在默认消息传递应用程序中打开写入消息框。我使用如下代码,但它只会将我带到收件箱。

 Intent intent = new Intent(Intent.ACTION_MAIN);
 intent.addCategory(Intent.CATEGORY_DEFAULT);
 intent.setType("vnd.android-dir/mms-sms/"+phone_number_in_string);
 startActivity(intent);

What I want is open write message box in default messaging app.

使用putExtra:

Intent intent = new Intent(Intent.ACTION_VIEW);
intent.addCategory(Intent.CATEGORY_DEFAULT);
intent.setType("vnd.android-dir/mms-sms/");
intent.putExtra("address", phone_number_in_string);
intent.putExtra("sms_body", " ");
startActivity(intent);