freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

androi畢設(shè)翻譯中英文都有-文庫(kù)吧資料

2024-11-09 16:37本頁(yè)面
  

【正文】 g). While connected, you can municate with the service through an interface that the service exposes. For the music service, this interface 畢業(yè)設(shè)計(jì)(論文)文獻(xiàn)綜述 第 11 頁(yè) 共 14 頁(yè) might allow users to pause, rewind, stop, and restart the playback. Like activities and the other ponents, services run in the main thread of the application process. So that they won39。t have a visual user interface, but rather runs in the background for an indefinite period of time. For example, a service might play background music as the user attends to other matters, or it might fetch data over the work or calculate something and provide the result to activities that need it. Each service extends the Service base class. A prime example is a media player playing songs from a play list. The player application would probably have one or more activities that allow the user to choose songs and start playing them. However, the music playback itself would not be handled by an activity because users will expect the music to keep playing even after they leave the player and begin something different. To keep the music going, the media player activity could start a service to run in the background. The system would then keep the music playback service running even after the activity that started it leaves the screen. It39。s interaction with the user takes place. For example, a view might display a small image and initiate an action when the user taps that image. Android has a number of readymade views that you can use — including buttons, text fields, scroll bars, menu items, check boxes, and more. A view hierarchy is placed within an activity39。t incorporate the code of the other application or link to it. Rather, it simply starts up that piece of the other application when the need arises. For this to work, the system must be able to start an application process when any part of it is needed, and instantiate the Java objects for that part. Therefore, unlike applications on most other systems, Android applications don39。s possible to arrange for two applications to share the same user ID, in which case they will be able to see each other39。s no longer needed and system resources are required by other applications. 2. Each process has its own virtual machine (VM), so application code runs in isolation from the code of all other applications. 3. By default, each application is assigned a unique Linux user ID. Permissions are set so that the application39。s the file users download to their devices. All the code in a single .apk file is considered to be one application. In many ways, each Android application lives in its own world: 1. By default, every application runs in its own Linux process. Android starts the process when any of the application39。 畢業(yè)設(shè)計(jì)(論文)文獻(xiàn)綜述 第 9 頁(yè) 共 14 頁(yè) Application Fundamentals Android applications are written in the Java programming language. The piled Java code — along with any data and resource files required by the application — is bundled by the aapt tool into an Android package, an archive file marked by an .apk suffix. This file is the vehicle for distributing the application and installing it on mobile devices。 對(duì)于 在代碼中創(chuàng)建并注冊(cè)的 broadcast receiver來(lái)說(shuō), intent過(guò)濾器將被直接實(shí)例化IntentFilter為對(duì)象。 一個(gè)組件可以擁有任意數(shù)量的 intent過(guò)濾器,每個(gè)都聲明了一套不同的功能。換句話說(shuō),這 個(gè) activity是應(yīng)用程序的入口點(diǎn),是用戶在啟動(dòng)器中選擇運(yùn)行這個(gè)應(yīng)用程序后所見(jiàn)到的第一個(gè) activity。返里有一個(gè)對(duì)先前例子的擴(kuò)展,其中加入了針對(duì) activity的兩個(gè) intent過(guò)濾器: 畢業(yè)設(shè)計(jì)(論文)文獻(xiàn)綜述 第 8 頁(yè) 共 14 頁(yè) 示例中的第一個(gè)過(guò)濾器 ——action“”和category“”的組合 ——是常見(jiàn)的一個(gè)。組件的 intent過(guò)濾器會(huì)通知 Android它所能處 理的 intent類(lèi)型。但如果 intent沒(méi)有顯式地指定一個(gè)目標(biāo),Android就必須找到最合適的組件來(lái)響應(yīng)此 intent。 Intent過(guò)濾器 一個(gè) Intent對(duì)象可以顯式地指定一個(gè)目標(biāo)組件。未在manifest文件中進(jìn) 行聲明的 activity、 service以及 content provider將不為系統(tǒng)所見(jiàn),從而也就永不 會(huì)被運(yùn)行。 icon和 label屬性指向包含展示給用戶的此 activity的圖標(biāo)和標(biāo)簽的資源文件。 但 manifest文件最重要的任務(wù)是向 Android報(bào)告此應(yīng)用程序的各個(gè)組件。 manifest文件是一個(gè)結(jié)構(gòu)化的 XML文件,而且 對(duì)于 所有應(yīng)用程序,文件名總是。 manifest文件 當(dāng) Android啟動(dòng) 一個(gè)應(yīng)用程序組件之 前,它必須知道那個(gè)組件是存在的。 系統(tǒng)也會(huì)在組件不 再被使用的時(shí)候戒者當(dāng) Android必須為更多的活動(dòng) 組件回 收內(nèi)存時(shí)關(guān)閉它。一個(gè) activity可以通過(guò)調(diào)用finishActivity()方法來(lái)關(guān)閉另外一個(gè) activity(它用 startActivityForResult() 啟動(dòng)的)。所以 Android為關(guān)閉 activity和 service提供了一系列有序的方法。只 要會(huì)話依然持續(xù), 無(wú)論會(huì)話過(guò)程有無(wú)空閑,activity同用戶進(jìn) 行長(zhǎng)時(shí) 間會(huì)話且可能一直處于活動(dòng)狀態(tài)。所以沒(méi)有必要去顯式地關(guān)閉返些組件。 關(guān)閉組件 畢業(yè)設(shè)計(jì)(論文)文獻(xiàn)綜述 第 6 頁(yè) 共 14 頁(yè) content provider僅在響應(yīng)來(lái)自 ContentResolver的請(qǐng)求時(shí)處于活動(dòng) 狀態(tài)。 3 應(yīng)用程序可以通過(guò)傳遞一個(gè) Intent對(duì)象至 () , Context. sendOrderedBroadcast(), 以及 ()和其它類(lèi)似方法來(lái)發(fā)起一個(gè)廣播。這 個(gè) activity可以調(diào)用 bindService()來(lái)建立此連接,然后調(diào)用 service中定之的方法來(lái)控制回放。此 service會(huì)通過(guò) onBind() 方法的調(diào)用來(lái)獲取此 Intent對(duì)象(如果此 service尚未運(yùn)行, bindService()會(huì)先啟動(dòng) 它 )。 Android調(diào)用此 service的 onStart()方法并將 Intent對(duì)象傳遞給它。其結(jié)果將會(huì)被封裝在一個(gè) Intent對(duì)象中,并傳遞給發(fā)出調(diào)用的 activity的 onActivityResult() 方法。 如果它期望它所啟動(dòng) 的那個(gè) activity迒回一個(gè)結(jié)果,它會(huì)調(diào)用 startActivityForResult()而不 是 startActivity()。 An
點(diǎn)擊復(fù)制文檔內(nèi)容
公司管理相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1