List of usage examples for android.content Loader startLoading
public final void startLoading()
From source file:com.github.secondsun.catfactsdemo.networking.LoaderBasedFactFetcher.java
@Override public void onResume() { Loader<Object> localLoader = activity.getLoaderManager().getLoader(LOADER_ID); if (localLoader != null && !localLoader.isStarted()) { localLoader.startLoading(); }/*from w ww . j a v a 2 s . c o m*/ if (localLoader != null) { activity.displayFacts( ((HttpCatLoader) (Loader<?>) activity.getLoaderManager().getLoader(LOADER_ID)).data); } }
From source file:com.github.secondsun.catfactsdemo.networking.LoaderBasedFactFetcher.java
@Override public void load(CatFacts activity) { final Loader<List<String>> localLoader = activity.getLoaderManager() .initLoader(LoaderBasedFactFetcher.LOADER_ID, Bundle.EMPTY, this); localLoader.startLoading(); }