博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
nullnullDefining and Launching the Query 定义和启动查询
阅读量:4682 次
发布时间:2019-06-09

本文共 2240 字,大约阅读时间需要 7 分钟。

PS:今天上午,非常郁闷,有很多简单基础的问题搞得我有些迷茫,哎,代码几天不写就忘。目前又不当COO,还是得用心记代码哦!

    To perform a query, create the , set up its query, and pass it to the loader framework. From then on, the framework manages everything. It runs the query on a background thread, returns the results to the foreground, and watches for changes to the data associated with the query. http://blog.csdn.net/sergeycao

    Pass a to the loader framework in your implementation of. The loader framework calls this method when youcreate a loader by calling . You can create a anywhere, but the preferred way is to create it in, because this defers creation until the object is actually needed.

    Notice that will only if the doesn't already exist; otherwise, it re-uses the existing. The loader framework tracks instance using theid value passed to .

    

Define and Launch the Query

    每日一道理
微笑,是春天里的一丝新绿,是秋日里的一缕阳光,是骄阳下的一片浓荫,是冬雪中的一株梅红……微笑着去面对吧,你会感到人生是那样的温馨与甜蜜!

    To create a and define its query at the same time, call the constructor. Thecontext and uri arguments are required, but the others are optional. To use the default value for an optional argument, pass innull. The runs the query against the identified by uri, just as if you had called with the same arguments.

    For example:

public Loader
onCreateLoader(int loaderID, Bundle bundle){ /* * Takes action based on the ID of the Loader that's being created */ switch (loaderID) { case URL_LOADER: /* * Return a new CursorLoader */ return new CursorLoader( this, // Context DataProviderContract.IMAGE_URI, // Provider's content URI PROJECTION, // Columns to return null, // Return all rows null, // No search arguments null); // Default search order default: // An invalid id was passed in return null; }}

文章结束给大家分享下程序员的一些笑话语录: AdobeFlash拖垮Windows拖垮IE!又拖垮Linux拖垮Ubuntu拖垮FirxEox!还拖垮BSD拖垮MacOS拖垮Safri!简直无所不拖!AdobeFlash滚出网路世界!不要以为市占有率高就可以持续出烂货产品!以后替代品多得是!

转载于:https://www.cnblogs.com/jiangu66/archive/2013/05/09/3069881.html

你可能感兴趣的文章
80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))
查看>>
三角洲调平说明
查看>>
线程和进程(Java)
查看>>
PMP CMM
查看>>
day03 bs4解析库之遍历文档树
查看>>
Linux下通过ssh访问另一台内网服务器
查看>>
antd在webpack里面的配置
查看>>
redis 适用场景、缓存选择、java实现
查看>>
国际化问题简述
查看>>
poj2975 Nim
查看>>
.NET面试题系列(十四)锁
查看>>
一个使用 Go 的思维来帮助您构建并开发 Go 应用程序的开源框架
查看>>
.Net并行编程之同步机制
查看>>
iis 站点部署后 Microsof .Net Framework异常
查看>>
解决安全扫描Insecure HTTP Methods Enabled的问题
查看>>
使用jQuery验证用户名是否存在,达到局部刷新的效果
查看>>
团队-学生成绩管理一阶段互评
查看>>
mongodb安装和使用
查看>>
C++Primer笔记-----day01
查看>>
MSSQL 各个发行版本版本号以及Compact 版本号(更新)
查看>>