p4u*_*144 5 sms android status
我知道不应该使用SMS提供程序,但是我想知道名为"status"的字段的可能值是什么(其他一些字段也是如此,但我最感兴趣的是状态)和当我这样做时,这些值意味着什么:
Uri uriSms = Uri.parse("content://sms/inbox");
Cursor c = context.getContentResolver().query(uriSms, null,null,null,null);
//fields retrieved
0: _id
1: thread_id
2: address
3: person
4: date
5: protocol
6: read
7: status
8: type
9: reply_path_present
10: subject
11: body
12: service_center
13: locked
Run Code Online (Sandbox Code Playgroud)
我自己找到了答案.在类core/java/android/provider/Telephony.java(这里是github上的类).有一些代码行:
/**
* The TP-Status value for the message, or -1 if no status has
* been received
*/
public static final String STATUS = "status";
public static final int STATUS_NONE = -1;
public static final int STATUS_COMPLETE = 0;
public static final int STATUS_PENDING = 32;
public static final int STATUS_FAILED = 64;
Run Code Online (Sandbox Code Playgroud)
如果您对这些值感兴趣,可能还需要查看"类型"列.它可能很有用.
| 归档时间: |
|
| 查看次数: |
3021 次 |
| 最近记录: |