FileDocCategorySizeDatePackage
IMms.javaAPI DocAndroid 5.1 API34874Sat Mar 14 05:48:12 GMT 2015com.android.internal.telephony

IMms

public interface IMms implements android.os.IInterface
Service interface to handle MMS API requests

Fields Summary
Constructors Summary
Methods Summary
public android.net.UriaddMultimediaMessageDraft(java.lang.String callingPkg, android.net.Uri contentUri)
Add a multimedia message draft to system MMS store

param
callingPkg the package name of the calling app
param
contentUri the content Uri from which to read PDU data of the draft MMS
return
the URI of the stored draft message

public android.net.UriaddTextMessageDraft(java.lang.String callingPkg, java.lang.String address, java.lang.String text)
Add a text message draft to system SMS store

param
callingPkg the package name of the calling app
param
address the destination address of message
param
text the body of the message to send
return
the URI of the stored draft message

public booleanarchiveStoredConversation(java.lang.String callingPkg, long conversationId, boolean archived)
Archive or unarchive a stored conversation

param
callingPkg the package name of the calling app
param
conversationId the ID of the message conversation
param
archived true to archive the conversation, false otherwise
return
true if update is successful, false otherwise

public booleandeleteStoredConversation(java.lang.String callingPkg, long conversationId)
Delete a system stored SMS or MMS thread

param
callingPkg the package name of the calling app
param
conversationId the ID of the message conversation
return
true if deletion is successful, false otherwise

public booleandeleteStoredMessage(java.lang.String callingPkg, android.net.Uri messageUri)
Delete a system stored SMS or MMS message

param
callingPkg the package name of the calling app
param
messageUri the URI of the stored message
return
true if deletion is successful, false otherwise

public voiddownloadMessage(int subId, java.lang.String callingPkg, java.lang.String locationUrl, android.net.Uri contentUri, android.os.Bundle configOverrides, android.app.PendingIntent downloadedIntent)
Download an MMS message using known location and transaction id

param
subId the SIM id
param
callingPkg the package name of the calling app
param
locationUrl the location URL of the MMS message to be downloaded, usually obtained from the MMS WAP push notification
param
contentUri a contentUri to which the downloaded MMS message will be written
param
configOverrides the carrier-specific messaging configuration values to override for downloading the message. See {@link android.telephony.MessagingConfigurationManager} for the value names and types.
param
downloadedIntent if not NULL this PendingIntent is broadcast when the message is downloaded, or the download is failed

public booleangetAutoPersisting()
Get the value of the flag to automatically write sent/received SMS/MMS messages into system When this flag is on, all SMS/MMS sent/received are stored by system automatically When this flag is off, only SMS/MMS sent by non-default SMS apps are stored by system automatically

return
the current value of the auto persist flag

public android.os.BundlegetCarrierConfigValues(int subId)
Get carrier-dependent configuration values.

param
subId the SIM id

public android.net.UriimportMultimediaMessage(java.lang.String callingPkg, android.net.Uri contentUri, java.lang.String messageId, long timestampSecs, boolean seen, boolean read)
Import a multimedia message into system's MMS store

param
callingPkg the package name of the calling app
param
contentUri the content uri from which to read PDU of the message to import
param
messageId the optional message id
param
timestampSecs the message timestamp in seconds
param
seen if the message is seen
param
read if the message is read
return
the message URI, null if failed

public android.net.UriimportTextMessage(java.lang.String callingPkg, java.lang.String address, int type, java.lang.String text, long timestampMillis, boolean seen, boolean read)
Import a text message into system's SMS store

param
callingPkg the calling app's package name
param
address the destination address of the message
param
type the type of the message
param
text the message text
param
timestampMillis the message timestamp in milliseconds
param
seen if the message is seen
param
read if the message is read
return
the message URI, null if failed

public voidsendMessage(int subId, java.lang.String callingPkg, android.net.Uri contentUri, java.lang.String locationUrl, android.os.Bundle configOverrides, android.app.PendingIntent sentIntent)
Send an MMS message

param
subId the SIM id
param
callingPkg the package name of the calling app
param
contentUri the content uri from which to read MMS message encoded in standard MMS PDU format
param
locationUrl the optional location url for where this message should be sent to
param
configOverrides the carrier-specific messaging configuration values to override for sending the message. See {@link android.telephony.MessagingConfigurationManager} for the value names and types.
param
sentIntent if not NULL this PendingIntent is broadcast when the message is successfully sent, or failed

public voidsendStoredMessage(int subId, java.lang.String callingPkg, android.net.Uri messageUri, android.os.Bundle configOverrides, android.app.PendingIntent sentIntent)
Send a system stored MMS message This is used for sending a previously sent, but failed-to-send, message or for sending a text message that has been stored as a draft.

param
subId the SIM id
param
callingPkg the package name of the calling app
param
messageUri the URI of the stored message
param
configOverrides the carrier-specific messaging configuration values to override for sending the message. See {@link android.telephony.MessagingConfigurationManager} for the value names and types.
param
sentIntent if not NULL this PendingIntent is broadcast when the message is successfully sent, or failed

public voidsetAutoPersisting(java.lang.String callingPkg, boolean enabled)
Turns on/off the flag to automatically write sent/received SMS/MMS messages into system When this flag is on, all SMS/MMS sent/received are stored by system automatically When this flag is off, only SMS/MMS sent by non-default SMS apps are stored by system automatically This flag can only be changed by default SMS apps

param
callingPkg the name of the calling app package
param
enabled Whether to enable message auto persisting

public booleanupdateStoredMessageStatus(java.lang.String callingPkg, android.net.Uri messageUri, android.content.ContentValues statusValues)
Update the status properties of a system stored SMS or MMS message, e.g. the read status of a message, etc.

param
callingPkg the package name of the calling app
param
messageUri the URI of the stored message
param
statusValues a list of status properties in key-value pairs to update
return
true if deletion is successful, false otherwise