public static final class Telephony.Sms extends Object implements BaseColumns, Telephony.TextBasedSmsColumns
Modifier and Type | Class and Description |
---|---|
static class |
Telephony.Sms.Conversations
Contains all sent text-based SMS messages in the SMS app's.
|
static class |
Telephony.Sms.Draft
Contains all sent text based SMS messages in the SMS app's.
|
static class |
Telephony.Sms.Inbox
Contains all text based SMS messages in the SMS app's inbox.
|
static class |
Telephony.Sms.Intents
Contains info about SMS related Intents that are broadcast.
|
static class |
Telephony.Sms.Outbox
Contains all pending outgoing text based SMS messages.
|
static class |
Telephony.Sms.Sent
Contains all sent text based SMS messages in the SMS app's.
|
Modifier and Type | Field and Description |
---|---|
static Uri |
CONTENT_URI
The content:// style URL for this table
|
static String |
DEFAULT_SORT_ORDER
The default sort order for this table
|
_COUNT, _ID
ADDRESS, BODY, DATE, DATE_SENT, ERROR_CODE, LOCKED, MESSAGE_TYPE_ALL, MESSAGE_TYPE_DRAFT, MESSAGE_TYPE_FAILED, MESSAGE_TYPE_INBOX, MESSAGE_TYPE_OUTBOX, MESSAGE_TYPE_QUEUED, MESSAGE_TYPE_SENT, META_DATA, PERSON, PERSON_ID, PROTOCOL, READ, REPLY_PATH_PRESENT, SEEN, SERVICE_CENTER, STATUS, STATUS_COMPLETE, STATUS_FAILED, STATUS_NONE, STATUS_PENDING, SUBJECT, THREAD_ID, TYPE
Constructor and Description |
---|
Telephony.Sms() |
Modifier and Type | Method and Description |
---|---|
static Uri |
addMessageToUri(ContentResolver resolver,
Uri uri,
String address,
String body,
String subject,
Long date,
boolean read,
boolean deliveryReport)
Add an SMS to the given URI.
|
static Uri |
addMessageToUri(ContentResolver resolver,
Uri uri,
String address,
String body,
String subject,
Long date,
boolean read,
boolean deliveryReport,
long threadId)
Add an SMS to the given URI with thread_id specified.
|
static boolean |
isOutgoingFolder(int messageType)
Returns true iff the folder (message type) identifies an
outgoing message.
|
static boolean |
moveMessageToFolder(Context context,
Uri uri,
int folder,
int error)
Move a message to the given folder.
|
static Cursor |
query(ContentResolver cr,
String[] projection) |
static Cursor |
query(ContentResolver cr,
String[] projection,
String where,
String orderBy) |
public static final Uri CONTENT_URI
public static final String DEFAULT_SORT_ORDER
public static final Cursor query(ContentResolver cr, String[] projection)
public static final Cursor query(ContentResolver cr, String[] projection, String where, String orderBy)
public static Uri addMessageToUri(ContentResolver resolver, Uri uri, String address, String body, String subject, Long date, boolean read, boolean deliveryReport)
resolver
- the content resolver to useuri
- the URI to add the message toaddress
- the address of the senderbody
- the body of the messagesubject
- the psuedo-subject of the messagedate
- the timestamp for the messageread
- true if the message has been read, false if notdeliveryReport
- true if a delivery report was requested, false if notpublic static Uri addMessageToUri(ContentResolver resolver, Uri uri, String address, String body, String subject, Long date, boolean read, boolean deliveryReport, long threadId)
resolver
- the content resolver to useuri
- the URI to add the message toaddress
- the address of the senderbody
- the body of the messagesubject
- the psuedo-subject of the messagedate
- the timestamp for the messageread
- true if the message has been read, false if notdeliveryReport
- true if a delivery report was requested, false if notthreadId
- the thread_id of the messagepublic static boolean moveMessageToFolder(Context context, Uri uri, int folder, int error)
context
- the context to useuri
- the message to movefolder
- the folder to move topublic static boolean isOutgoingFolder(int messageType)