【正文】
int which) { // TODO Autogenerated method stub switch (which) { case 0://刪除短信 Uri uri = ( getContentResolver() .delete(uri, address=?, new String[] { telNo })。 } } ()。 body = body + ....。 break。 從數(shù)據(jù)取出最近信息的代碼如下: // 獲得數(shù)據(jù)庫中的信息 public ListMapString, Object getData() { // 定義列表 List 存放取出的數(shù)據(jù) ListMapString, Object list = new ArrayListMapString, Object()。 } } } //將短信 添加到系統(tǒng)短信數(shù)據(jù)庫 private void addSmsToDB(String telNo, String content) { ContentValues values = new ContentValues()。 //遍歷短信 if (null != bundle) { Object[] pdus = (Object[]) (pdus)。 // 創(chuàng)建 deliveredIntent 參數(shù) Intent deliveredIntent = new Intent(DELIVERED_SMS_ACTION)。//0 為發(fā)件箱信息 getContentResolver().insert(( values)。 //獲取參數(shù)值短信號碼和內(nèi)容 String telNo = ().toString()。短信發(fā)送成功后,發(fā)送的短信信息會被保存到數(shù)據(jù)庫中,同樣,當手機通過 BroadcastReceive 接收到短信時,也會將短信存入數(shù)據(jù)庫。 ER 圖如圖 2 所示。所以,一個人性化并且美觀的界面是一個優(yōu)秀的軟件必 須所擁有的,好的界面將會擁有良好的用戶體驗,才會有更多的用戶去使用。另外,我們還可以通過使用 ()方法,連接到一個 service 上(如果這個 service 還沒有運行 將啟動它)。然 而,它們可以啟動一個 activity 或serice 來響應(yīng)它們收到的信息,或者用 NotificationManager 來通知用戶。 IntentFilter 需要在 中定義。 Activity 之間通過 Intent 進行通信。 畢業(yè)設(shè)計論文 基于 android 的短信管理軟件 學(xué)生姓名: 指導(dǎo)老師: 日期: 第一章 緒論 研究背景 目前, android 操作系統(tǒng)已經(jīng)成為了手機操作系統(tǒng)的的主流,而作為一款的手機操作系統(tǒng),手機主要功能之一的短信功能是絕對不可缺少的。在 Intent 的描述結(jié)構(gòu)中,有兩個最重要的部分:動作和動作對應(yīng)的數(shù)據(jù)。通過解析各種 intent,從一個屏幕導(dǎo)航到另一個屏幕是很簡單的。通知可以用很多種方式來吸引用戶的注意力──閃動背燈、震動、播放聲音等。當連接到一個 service 之后,我們還可以 service 提供的接口與它進行通訊。 2.齊全的功能: 一個系統(tǒng)最重要的就是功能,如果沒有功能那就不是一個系統(tǒng)而只是一個空殼。 圖 2:系統(tǒng) ER 圖 Android 的短信數(shù)據(jù)庫和聯(lián)系人數(shù)據(jù)庫在 android 操作系統(tǒng)中都是設(shè)計好,可以直接使 用的,我們在編輯短信管理軟件時只要使用 Content Provider,通過 url 就可以直接調(diào)用數(shù)據(jù)庫中的表了。具體代碼如下: : public class SendMsg extends Activity { String SENT_SMS_ACTION = SENT_SMS_ACTION。 String content = ().toString()。 //界面跳轉(zhuǎn) MainActivity Intent intent = new Intent()。 PendingIntent delivePI = (, 0, deliveredIntent, 0)。 SmsMessage[] msg = new SmsMessage[]。 (date, ())。 // 從數(shù)據(jù)庫中 取出數(shù)據(jù) 并根據(jù)日期排列 Cursor smsCursor = getContentResolver().query( ( null, null, null, date desc)。 } } // 若 List 中未有聯(lián)系人的信息,則將該數(shù)據(jù)存入 List 中 if (!has) { // 定義 map 存儲一列數(shù)據(jù) MapString, Object map = new HashMapString, Object()。 (body, body)。 return list。 break。對話框界面通過 intent 從列表界面獲取聯(lián)系人號碼,通過查詢該號碼從表 sms 中獲取與該聯(lián)系人的所用現(xiàn)存信息,并以對話形式 顯示。 String sms_phoneNmuber = (index_address)。 ()。 Cursor cursor = ().query(uri, null, null, null, null)。s digitized society, will also be attached on the report.Myopia is not only a disease that makes people see things blurrily, but also leads to severeplications, such as glaua (increased pressure within the eyeball), and can causeblindness, said Zhou Yuehua, an established eye care specialist with Beijing TongrenHospital.It is very important for parents and children to know about the risk and care for their eyes.There are about 450 million myopia patients in China. Among Chinese myopia patients,30million are severe patients, according to ZhouThe prevalence of myopia among high school and college students is more than 70 percent,and the situation is continuously worsening, he Zhu, director with the China Youth Development Service Center, said long hours ofstudy, lack of exercise, especially outdoor activities, and attachment to electronic screen aresome of the top reasons behind the widespread myopia problems, and the increase ofyounger patients, although China has made great progress in improving the hardwarefacilities and lighting conditions in said he hopes the survey will alert people on the threatening situation, and also helpmedical experts to better guideline parents and children39。t conducive to raising a child. She planned to have children once she had achieved career success so she could provide a stable environment for her baby. After 10 years, Xiao felt the time was right, and she tried to conceive for about six months, but was unable to bee pregnant. I conducted prehensive physical checkups. The results suggested that Xiao39。s most popular dishes are his brainchild. Lin says his secret of success is innovation rooted in experience: He spends months every year traveling and eating worldwide, seeking new ingredients and inspirations that could improve the offerings of Blue Frog restaurants. The restaurant chain regularly launches a new seasonal menu, usually featuring eight new dishes with fresh ingredients. The bestselling seasonal dishes later replace the least popular items on the regular menu, which is usually updated in late fall and boasts a selection of about 40 dishes. Food should have no boundaries, Lin says. As long as the food tastes good and is healthy, it doesn39。 menu some culinary touches from other countries, such as China and Mexico, and customers love such innovation, he says. He started his career as an apprentice in