Tabnine Logo
ImageLoader$SyncImageLoadingListener
Code IndexAdd Tabnine to your IDE (free)

How to use
ImageLoader$SyncImageLoadingListener
in
com.nostra13.universalimageloader.core

Best Java code snippets using com.nostra13.universalimageloader.core.ImageLoader$SyncImageLoadingListener (Showing top 4 results out of 315)

origin: wanliyang1990/WliveTV

/**
 * Loads and decodes image synchronously.<br />
 * <b>NOTE:</b> {@link #init(ImageLoaderConfiguration)} method must be called before this method call
 *
 * @param uri             Image URI (i.e. "http://site.com/image.png", "file:///mnt/sdcard/image.png")
 * @param targetImageSize Minimal size for {@link Bitmap} which will be returned. Downloaded image will be decoded
 *                        and scaled to {@link Bitmap} of the size which is <b>equal or larger</b> (usually a bit
 *                        larger) than incoming targetImageSize.
 * @param options         {@linkplain com.nostra13.universalimageloader.core.DisplayImageOptions Options} for image
 *                        decoding and scaling. If <b>null</b> - default display image options
 *                        {@linkplain ImageLoaderConfiguration.Builder#defaultDisplayImageOptions(DisplayImageOptions)
 *                        from configuration} will be used.
 * @return Result image Bitmap. Can be <b>null</b> if image loading/decoding was failed or cancelled.
 * @throws IllegalStateException if {@link #init(ImageLoaderConfiguration)} method wasn't called before
 */
public Bitmap loadImageSync(String uri, ImageSize targetImageSize, DisplayImageOptions options) {
  if (options == null) {
    options = configuration.defaultDisplayImageOptions;
  }
  options = new DisplayImageOptions.Builder().cloneFrom(options).syncLoading(true).build();
  SyncImageLoadingListener listener = new SyncImageLoadingListener();
  loadImage(uri, targetImageSize, options, listener);
  return listener.getLoadedBitmap();
}
origin: com.nostra13.universalimageloader/universal-image-loader

/**
 * Loads and decodes image synchronously.<br />
 * <b>NOTE:</b> {@link #init(ImageLoaderConfiguration)} method must be called before this method call
 *
 * @param uri             Image URI (i.e. "http://site.com/image.png", "file:///mnt/sdcard/image.png")
 * @param targetImageSize Minimal size for {@link Bitmap} which will be returned. Downloaded image will be decoded
 *                        and scaled to {@link Bitmap} of the size which is <b>equal or larger</b> (usually a bit
 *                        larger) than incoming targetImageSize.
 * @param options         {@linkplain com.nostra13.universalimageloader.core.DisplayImageOptions Options} for image
 *                        decoding and scaling. If <b>null</b> - default display image options
 *                        {@linkplain ImageLoaderConfiguration.Builder#defaultDisplayImageOptions(DisplayImageOptions)
 *                        from configuration} will be used.
 * @return Result image Bitmap. Can be <b>null</b> if image loading/decoding was failed or cancelled.
 * @throws IllegalStateException if {@link #init(ImageLoaderConfiguration)} method wasn't called before
 */
public Bitmap loadImageSync(String uri, ImageSize targetImageSize, DisplayImageOptions options) {
  if (options == null) {
    options = configuration.defaultDisplayImageOptions;
  }
  options = new DisplayImageOptions.Builder().cloneFrom(options).syncLoading(true).build();
  SyncImageLoadingListener listener = new SyncImageLoadingListener();
  loadImage(uri, targetImageSize, options, listener);
  return listener.getLoadedBitmap();
}
origin: jiangqqlmj/Android-Universal-Image-Loader-Modify

/**
 *
 * @param uri                   资源URL地址
 * @param targetImageSize       显示目标图片尺寸大小
 * @param options               图片显示配置参数
 * @return
 */
public Bitmap loadImageSync(String uri, ImageSize targetImageSize, DisplayImageOptions options) {
  if (options == null) {
    options = configuration.defaultDisplayImageOptions;
  }
  options = new DisplayImageOptions.Builder().cloneFrom(options).syncLoading(true).build();
  SyncImageLoadingListener listener = new SyncImageLoadingListener();
  loadImage(uri, targetImageSize, options, listener);
  return listener.getLoadedBitmap();
}
origin: nostra13/Android-Universal-Image-Loader

/**
 * Loads and decodes image synchronously.<br />
 * <b>NOTE:</b> {@link #init(ImageLoaderConfiguration)} method must be called before this method call
 *
 * @param uri             Image URI (i.e. "http://site.com/image.png", "file:///mnt/sdcard/image.png")
 * @param targetImageSize Minimal size for {@link Bitmap} which will be returned. Downloaded image will be decoded
 *                        and scaled to {@link Bitmap} of the size which is <b>equal or larger</b> (usually a bit
 *                        larger) than incoming targetImageSize.
 * @param options         {@linkplain com.nostra13.universalimageloader.core.DisplayImageOptions Options} for image
 *                        decoding and scaling. If <b>null</b> - default display image options
 *                        {@linkplain ImageLoaderConfiguration.Builder#defaultDisplayImageOptions(DisplayImageOptions)
 *                        from configuration} will be used.
 * @return Result image Bitmap. Can be <b>null</b> if image loading/decoding was failed or cancelled.
 * @throws IllegalStateException if {@link #init(ImageLoaderConfiguration)} method wasn't called before
 */
public Bitmap loadImageSync(String uri, ImageSize targetImageSize, DisplayImageOptions options) {
  if (options == null) {
    options = configuration.defaultDisplayImageOptions;
  }
  options = new DisplayImageOptions.Builder().cloneFrom(options).syncLoading(true).build();
  SyncImageLoadingListener listener = new SyncImageLoadingListener();
  loadImage(uri, targetImageSize, options, listener);
  return listener.getLoadedBitmap();
}
com.nostra13.universalimageloader.coreImageLoader$SyncImageLoadingListener

Javadoc

Listener which is designed for synchronous image loading.

Most used methods

  • <init>
  • getLoadedBitmap

Popular in Java

  • Making http post requests using okhttp
  • getContentResolver (Context)
  • onRequestPermissionsResult (Fragment)
  • setScale (BigDecimal)
  • FileReader (java.io)
    A specialized Reader that reads from a file in the file system. All read requests made by calling me
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
  • Runner (org.openjdk.jmh.runner)
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now