本文整理匯總了Java中android.telephony.SmsManager.STATUS_ON_ICC_UNREAD屬性的典型用法代碼示例。如果您正苦於以下問題:Java SmsManager.STATUS_ON_ICC_UNREAD屬性的具體用法?Java SmsManager.STATUS_ON_ICC_UNREAD怎麽用?Java SmsManager.STATUS_ON_ICC_UNREAD使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在類android.telephony.SmsManager
的用法示例。
在下文中一共展示了SmsManager.STATUS_ON_ICC_UNREAD屬性的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: translateStatus
/**
* Translates EF_SMS status bits to a status value compatible with SMS AT
* commands. See TS 27.005 3.1.
*/
private int translateStatus(int status) {
switch (status & 0x7) {
case SmsManager.STATUS_ON_ICC_READ:
return 1;
case SmsManager.STATUS_ON_ICC_UNREAD:
return 0;
case SmsManager.STATUS_ON_ICC_SENT:
return 3;
case SmsManager.STATUS_ON_ICC_UNSENT:
return 2;
}
// Default to READ.
return 1;
}
示例2: isIncomingMessage
private boolean isIncomingMessage(Cursor cursor) {
int messageStatus = cursor.getInt(cursor
.getColumnIndexOrThrow("status"));
return (messageStatus == SmsManager.STATUS_ON_ICC_READ)
|| (messageStatus == SmsManager.STATUS_ON_ICC_UNREAD);
}
示例3: isIncomingMessage
private boolean isIncomingMessage(Cursor cursor) {
int messageStatus = cursor.getInt(
cursor.getColumnIndexOrThrow("status"));
return (messageStatus == SmsManager.STATUS_ON_ICC_READ) ||
(messageStatus == SmsManager.STATUS_ON_ICC_UNREAD);
}